diff --git a/sdks/typescript/package-lock.json b/sdks/typescript/package-lock.json index 937d41b..926eefe 100644 --- a/sdks/typescript/package-lock.json +++ b/sdks/typescript/package-lock.json @@ -34,6 +34,7 @@ "eslint": "^10.4.0", "globals": "^17.6.0", "json-schema-to-zod": "^2.8.1", + "openapi-typescript": "^7.13.0", "tsup": "^8.0.1", "tsx": "^4.21.0", "typescript": "^5.3.3", @@ -78,9 +79,9 @@ } }, "node_modules/@ai-sdk/gateway": { - "version": "3.0.125", - "resolved": "https://registry.npmjs.org/@ai-sdk/gateway/-/gateway-3.0.125.tgz", - "integrity": "sha512-tocl7cUDoTpmhZqeW8XVKMMznZQwwQAEunF0VyNKmf64qt8NbMIAEiet/vRMzh7Jr9WcFeb6EZjmhLTP4Qx2Og==", + "version": "3.0.123", + "resolved": "https://registry.npmjs.org/@ai-sdk/gateway/-/gateway-3.0.123.tgz", + "integrity": "sha512-rL+3Sp9crOlfE7MwguFPS30qVp6HFcr9na0KYMb4CcQdxAIjBJec3EEdCjc94UyRVZWLmgQ6Yr605FmPlFIi0w==", "dev": true, "license": "Apache-2.0", "dependencies": { @@ -113,9 +114,9 @@ } }, "node_modules/@ai-sdk/openai": { - "version": "3.0.68", - "resolved": "https://registry.npmjs.org/@ai-sdk/openai/-/openai-3.0.68.tgz", - "integrity": "sha512-FCs/DPr4M95UyZ/ABHJmTmCEYRCka/4J0Bna0nsd78QCdGIS0X/zhn+fVzB7mZJo7464uOWYUjROx9PGNGOb0w==", + "version": "3.0.67", + "resolved": "https://registry.npmjs.org/@ai-sdk/openai/-/openai-3.0.67.tgz", + "integrity": "sha512-oAiGC9eWG7IgtdsdS74bOCnAAHarAfTJhWN9x5INwnWPekL802AvF+0I5DvLzIF1MIRmNw4N8mPSL/GUVbX9Mw==", "dev": true, "license": "Apache-2.0", "dependencies": { @@ -160,6 +161,28 @@ "zod": "^3.25.76 || ^4.1.8" } }, + "node_modules/@babel/code-frame": { + "version": "7.29.7", + "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.29.7.tgz", + "integrity": "sha512-Aup7aUOfpbAUg2ROOJN6Iw5f9DMBlzu0mIkm/malLQFN/YQgO48wCj0Kxa3sEHJvPVFg7siR+qRInwXd2qhQKw==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-validator-identifier": "^7.29.7", + "js-tokens": "^4.0.0", + "picocolors": "^1.1.1" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/code-frame/node_modules/js-tokens": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz", + "integrity": "sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==", + "dev": true, + "license": "MIT" + }, "node_modules/@babel/helper-string-parser": { "version": "7.27.1", "resolved": "https://registry.npmjs.org/@babel/helper-string-parser/-/helper-string-parser-7.27.1.tgz", @@ -171,9 +194,9 @@ } }, "node_modules/@babel/helper-validator-identifier": { - "version": "7.28.5", - "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.28.5.tgz", - "integrity": "sha512-qSs4ifwzKJSV39ucNjsvc6WVHs6b7S03sOh2OcHF9UHfVPqWWALUsNUVzhSBiItjRZoLHx7nIarVjqKVusUZ1Q==", + "version": "7.29.7", + "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.29.7.tgz", + "integrity": "sha512-qehxGkRj55h/ff8EMaJ+cYhyaKlHIxqYDn682wQD7RNp9UujOQsHog2uS0r2vzr4pW+sXf90NeeayjcNaX3fFg==", "dev": true, "license": "MIT", "engines": { @@ -955,6 +978,89 @@ "url": "https://github.com/sponsors/Boshen" } }, + "node_modules/@redocly/ajv": { + "version": "8.11.2", + "resolved": "https://registry.npmjs.org/@redocly/ajv/-/ajv-8.11.2.tgz", + "integrity": "sha512-io1JpnwtIcvojV7QKDUSIuMN/ikdOUd1ReEnUnMKGfDVridQZ31J0MmIuqwuRjWDZfmvr+Q0MqCcfHM2gTivOg==", + "dev": true, + "license": "MIT", + "dependencies": { + "fast-deep-equal": "^3.1.1", + "json-schema-traverse": "^1.0.0", + "require-from-string": "^2.0.2", + "uri-js-replace": "^1.0.1" + }, + "funding": { + "type": "github", + "url": "https://github.com/sponsors/epoberezkin" + } + }, + "node_modules/@redocly/ajv/node_modules/json-schema-traverse": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-1.0.0.tgz", + "integrity": "sha512-NM8/P9n3XjXhIZn1lLhkFaACTOURQXjWhV4BA/RnOv8xvgqtqpAX9IO4mRQxSx1Rlo4tqzeqb0sOlruaOy3dug==", + "dev": true, + "license": "MIT" + }, + "node_modules/@redocly/config": { + "version": "0.22.0", + "resolved": "https://registry.npmjs.org/@redocly/config/-/config-0.22.0.tgz", + "integrity": "sha512-gAy93Ddo01Z3bHuVdPWfCwzgfaYgMdaZPcfL7JZ7hWJoK9V0lXDbigTWkhiPFAaLWzbOJ+kbUQG1+XwIm0KRGQ==", + "dev": true, + "license": "MIT" + }, + "node_modules/@redocly/openapi-core": { + "version": "1.34.15", + "resolved": "https://registry.npmjs.org/@redocly/openapi-core/-/openapi-core-1.34.15.tgz", + "integrity": "sha512-HAwCnNyKcs5XGQqms+9t7OdAPM/5TDstmhF+0i7tdCFato2QKuYIlyWETwkXd8c5zbltr1oB+6y9NTeQLr2d6Q==", + "dev": true, + "license": "MIT", + "dependencies": { + "@redocly/ajv": "8.11.2", + "@redocly/config": "0.22.0", + "colorette": "1.4.0", + "https-proxy-agent": "7.0.6", + "js-levenshtein": "1.1.6", + "js-yaml": "4.1.1", + "minimatch": "5.1.9", + "pluralize": "8.0.0", + "yaml-ast-parser": "0.0.43" + }, + "engines": { + "node": ">=18.17.0", + "npm": ">=9.5.0" + } + }, + "node_modules/@redocly/openapi-core/node_modules/balanced-match": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.2.tgz", + "integrity": "sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==", + "dev": true, + "license": "MIT" + }, + "node_modules/@redocly/openapi-core/node_modules/brace-expansion": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-2.1.1.tgz", + "integrity": "sha512-WR1cURNjuvBLMZBMbqM0UoE+WAfdUcEV1ccD8PVBVOI+Z3ND4+SZbN8RsfT2bMuG1qwz5RFvPukSZm5fF2D5eA==", + "dev": true, + "license": "MIT", + "dependencies": { + "balanced-match": "^1.0.0" + } + }, + "node_modules/@redocly/openapi-core/node_modules/minimatch": { + "version": "5.1.9", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-5.1.9.tgz", + "integrity": "sha512-7o1wEA2RyMP7Iu7GNba9vc0RWWGACJOCZBJX2GJWip0ikV+wcOsgVuY9uE8CPiyQhkGFSlhuSkZPavN7u1c2Fw==", + "dev": true, + "license": "ISC", + "dependencies": { + "brace-expansion": "^2.0.1" + }, + "engines": { + "node": ">=10" + } + }, "node_modules/@rolldown/binding-android-arm64": { "version": "1.0.3", "resolved": "https://registry.npmjs.org/@rolldown/binding-android-arm64/-/binding-android-arm64-1.0.3.tgz", @@ -1627,9 +1733,9 @@ "license": "MIT" }, "node_modules/@types/node": { - "version": "25.9.2", - "resolved": "https://registry.npmjs.org/@types/node/-/node-25.9.2.tgz", - "integrity": "sha512-G05zqtJhcDLb8uslf5EjCxXg9G1KQxiV8OS0R26IC//Eoyitzqe8z37I7cqvnZlrlSfgocQRfSn/AHBZJJFyGw==", + "version": "25.9.1", + "resolved": "https://registry.npmjs.org/@types/node/-/node-25.9.1.tgz", + "integrity": "sha512-xfrlY7UD5rMJk3ZVJP8BNzS28J36YJg+xp+LPXV1TdWxr8uMH5A860QNxYDGQe/ylDSgjxE52Q9VnO7p75tJxg==", "dev": true, "license": "MIT", "dependencies": { @@ -2063,14 +2169,24 @@ "acorn": "^6.0.0 || ^7.0.0 || ^8.0.0" } }, + "node_modules/agent-base": { + "version": "7.1.4", + "resolved": "https://registry.npmjs.org/agent-base/-/agent-base-7.1.4.tgz", + "integrity": "sha512-MnA+YT8fwfJPgBx3m60MNqakm30XOkyIoH1y6huTQvC0PwZG7ki8NacLBcrPbNoo8vEZy7Jpuk7+jMO+CUovTQ==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 14" + } + }, "node_modules/ai": { - "version": "6.0.197", - "resolved": "https://registry.npmjs.org/ai/-/ai-6.0.197.tgz", - "integrity": "sha512-U3KsjkqwQXGHC0u0VeUDqUaNaBS/uQc7v4Vj92Cjv5lPx5DIyRBQYk4Hipy5vwD9AQKIG8uRvdaN9R+pAvrtcQ==", + "version": "6.0.195", + "resolved": "https://registry.npmjs.org/ai/-/ai-6.0.195.tgz", + "integrity": "sha512-IYZpuVz0boWbpIQYyinfWFrvQ1N0dG+EVB63it45B2YAU/MxxCnwz4zBswjYnPtHnJBedpMPNrwVbeczbl2GKg==", "dev": true, "license": "Apache-2.0", "dependencies": { - "@ai-sdk/gateway": "3.0.125", + "@ai-sdk/gateway": "3.0.123", "@ai-sdk/provider": "3.0.10", "@ai-sdk/provider-utils": "4.0.27", "@opentelemetry/api": "^1.9.0" @@ -2099,6 +2215,16 @@ "url": "https://github.com/sponsors/epoberezkin" } }, + "node_modules/ansi-colors": { + "version": "4.1.3", + "resolved": "https://registry.npmjs.org/ansi-colors/-/ansi-colors-4.1.3.tgz", + "integrity": "sha512-/6w/C21Pm1A7aZitlI5Ni/2J6FFQN8i1Cvz3kHABAAbw93v/NlvKdVOqz7CCWz/3iv/JplRSEEZ83XION15ovw==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6" + } + }, "node_modules/any-promise": { "version": "1.3.0", "resolved": "https://registry.npmjs.org/any-promise/-/any-promise-1.3.0.tgz", @@ -2106,6 +2232,13 @@ "dev": true, "license": "MIT" }, + "node_modules/argparse": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/argparse/-/argparse-2.0.1.tgz", + "integrity": "sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q==", + "dev": true, + "license": "Python-2.0" + }, "node_modules/assertion-error": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/assertion-error/-/assertion-error-2.0.1.tgz", @@ -2187,6 +2320,13 @@ "node": ">=18" } }, + "node_modules/change-case": { + "version": "5.4.4", + "resolved": "https://registry.npmjs.org/change-case/-/change-case-5.4.4.tgz", + "integrity": "sha512-HRQyTk2/YPEkt9TnUPbOpr64Uw3KOicFWPVBb+xiHvd6eBx/qPr9xqfBFDT8P2vWsvvz4jbEkfDe71W3VyNu2w==", + "dev": true, + "license": "MIT" + }, "node_modules/chokidar": { "version": "4.0.3", "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-4.0.3.tgz", @@ -2203,6 +2343,13 @@ "url": "https://paulmillr.com/funding/" } }, + "node_modules/colorette": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/colorette/-/colorette-1.4.0.tgz", + "integrity": "sha512-Y2oEozpomLn7Q3HFP7dpww7AtMJplbM9lGZP6RDfHqmbeRjiwRg4n6VM6j4KLmRke85uWEI7JqF17f3pqdRA0g==", + "dev": true, + "license": "MIT" + }, "node_modules/commander": { "version": "4.1.1", "resolved": "https://registry.npmjs.org/commander/-/commander-4.1.1.tgz", @@ -2765,6 +2912,20 @@ "dev": true, "license": "MIT" }, + "node_modules/https-proxy-agent": { + "version": "7.0.6", + "resolved": "https://registry.npmjs.org/https-proxy-agent/-/https-proxy-agent-7.0.6.tgz", + "integrity": "sha512-vK9P5/iUfdl95AI+JVyUuIcVtd4ofvtrOr3HNtM2yxC9bnMbEdp3x01OhQNnjb8IJYi38VlTE3mBXwcfvywuSw==", + "dev": true, + "license": "MIT", + "dependencies": { + "agent-base": "^7.1.2", + "debug": "4" + }, + "engines": { + "node": ">= 14" + } + }, "node_modules/ignore": { "version": "7.0.5", "resolved": "https://registry.npmjs.org/ignore/-/ignore-7.0.5.tgz", @@ -2785,6 +2946,19 @@ "node": ">=0.8.19" } }, + "node_modules/index-to-position": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/index-to-position/-/index-to-position-1.2.0.tgz", + "integrity": "sha512-Yg7+ztRkqslMAS2iFaU+Oa4KTSidr63OsFGlOrJoW981kIYO3CGCS3wA95P1mUi/IVSJkn0D479KTJpVpvFNuw==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, "node_modules/is-extglob": { "version": "2.1.1", "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz", @@ -2864,6 +3038,16 @@ "node": ">=10" } }, + "node_modules/js-levenshtein": { + "version": "1.1.6", + "resolved": "https://registry.npmjs.org/js-levenshtein/-/js-levenshtein-1.1.6.tgz", + "integrity": "sha512-X2BB11YZtrRqY4EnQcLX5Rh373zbK4alC1FW7D7MBhL2gtcC17cTnr6DmfHZeS0s2rTHjUTMMHfG7gO8SSdw+g==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, "node_modules/js-tokens": { "version": "10.0.0", "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-10.0.0.tgz", @@ -2871,6 +3055,19 @@ "dev": true, "license": "MIT" }, + "node_modules/js-yaml": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-4.1.1.tgz", + "integrity": "sha512-qQKT4zQxXl8lLwBtHMWwaTcGfFOZviOJet3Oy/xmGk2gZH677CJM9EvtfdSkgWcATZhj/55JZ0rmy3myCT5lsA==", + "dev": true, + "license": "MIT", + "dependencies": { + "argparse": "^2.0.1" + }, + "bin": { + "js-yaml": "bin/js-yaml.js" + } + }, "node_modules/json-buffer": { "version": "3.0.1", "resolved": "https://registry.npmjs.org/json-buffer/-/json-buffer-3.0.1.tgz", @@ -3388,6 +3585,40 @@ ], "license": "MIT" }, + "node_modules/openapi-typescript": { + "version": "7.13.0", + "resolved": "https://registry.npmjs.org/openapi-typescript/-/openapi-typescript-7.13.0.tgz", + "integrity": "sha512-EFP392gcqXS7ntPvbhBzbF8TyBA+baIYEm791Hy5YkjDYKTnk/Tn5OQeKm5BIZvJihpp8Zzr4hzx0Irde1LNGQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "@redocly/openapi-core": "^1.34.6", + "ansi-colors": "^4.1.3", + "change-case": "^5.4.4", + "parse-json": "^8.3.0", + "supports-color": "^10.2.2", + "yargs-parser": "^21.1.1" + }, + "bin": { + "openapi-typescript": "bin/cli.js" + }, + "peerDependencies": { + "typescript": "^5.x" + } + }, + "node_modules/openapi-typescript/node_modules/supports-color": { + "version": "10.2.2", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-10.2.2.tgz", + "integrity": "sha512-SS+jx45GF1QjgEXQx4NJZV9ImqmO2NPz5FNsIHrsDjh2YsHnawpan7SNQ1o8NuhrbHZy9AZhIoCUiCeaW/C80g==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/chalk/supports-color?sponsor=1" + } + }, "node_modules/optionator": { "version": "0.9.4", "resolved": "https://registry.npmjs.org/optionator/-/optionator-0.9.4.tgz", @@ -3466,6 +3697,24 @@ "url": "https://github.com/sponsors/sindresorhus" } }, + "node_modules/parse-json": { + "version": "8.3.0", + "resolved": "https://registry.npmjs.org/parse-json/-/parse-json-8.3.0.tgz", + "integrity": "sha512-ybiGyvspI+fAoRQbIPRddCcSTV9/LsJbf0e/S85VLowVGzRmokfneg2kwVW/KU5rOXrPSbF1qAKPMgNTqqROQQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/code-frame": "^7.26.2", + "index-to-position": "^1.1.0", + "type-fest": "^4.39.1" + }, + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, "node_modules/path-exists": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz", @@ -3663,6 +3912,16 @@ "url": "https://paulmillr.com/funding/" } }, + "node_modules/require-from-string": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/require-from-string/-/require-from-string-2.0.2.tgz", + "integrity": "sha512-Xf0nWe6RseziFMu+Ap9biiUbmplq6S9/p+7w7YXP/JBHhrUDDUhwa+vANyubuqfZWTveU//DYVGsDG7RKL/vEw==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, "node_modules/resolve-from": { "version": "5.0.0", "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-5.0.0.tgz", @@ -4583,6 +4842,19 @@ "node": ">= 0.8.0" } }, + "node_modules/type-fest": { + "version": "4.41.0", + "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-4.41.0.tgz", + "integrity": "sha512-TeTSQ6H5YHvpqVwBRcnLDCBnDOHWYu7IvGbHT6N8AOymcr9PJGjc1GTtiWZTYg0NCgYwvnYWEkVChQAr9bjfwA==", + "dev": true, + "license": "(MIT OR CC0-1.0)", + "engines": { + "node": ">=16" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, "node_modules/typescript": { "version": "5.9.3", "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.9.3.tgz", @@ -4621,6 +4893,13 @@ "punycode": "^2.1.0" } }, + "node_modules/uri-js-replace": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/uri-js-replace/-/uri-js-replace-1.0.1.tgz", + "integrity": "sha512-W+C9NWNLFOoBI2QWDp4UT9pv65r2w5Cx+3sTYFvtMdDBxkKt1syCqsUdSFAChbEe1uK5TfS04wt/nGwmaeIQ0g==", + "dev": true, + "license": "MIT" + }, "node_modules/vite": { "version": "8.0.16", "resolved": "https://registry.npmjs.org/vite/-/vite-8.0.16.tgz", @@ -4842,6 +5121,23 @@ "node": ">=0.10.0" } }, + "node_modules/yaml-ast-parser": { + "version": "0.0.43", + "resolved": "https://registry.npmjs.org/yaml-ast-parser/-/yaml-ast-parser-0.0.43.tgz", + "integrity": "sha512-2PTINUwsRqSd+s8XxKaJWQlUuEMHJQyEuh2edBbW8KNJz0SJPwUSD2zRWqezFEdN7IzAgeuYHFUCF7o8zRdZ0A==", + "dev": true, + "license": "Apache-2.0" + }, + "node_modules/yargs-parser": { + "version": "21.1.1", + "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-21.1.1.tgz", + "integrity": "sha512-tVpsJW7DdjecAiFpbIB1e3qxIQsE6NoPc5/eTdrbbIC4h0LVsWhnoa3g+m2HclBIujHzsxZ4VJVA+GUuc2/LBw==", + "dev": true, + "license": "ISC", + "engines": { + "node": ">=12" + } + }, "node_modules/yocto-queue": { "version": "1.2.2", "resolved": "https://registry.npmjs.org/yocto-queue/-/yocto-queue-1.2.2.tgz", diff --git a/sdks/typescript/package.json b/sdks/typescript/package.json index 12494c3..7575aa0 100644 --- a/sdks/typescript/package.json +++ b/sdks/typescript/package.json @@ -29,6 +29,7 @@ ], "scripts": { "generate:schemas": "tsx scripts/generate-schema.ts ../../evals/prompts/purpose/config.json", + "generate:kg-types": "openapi-typescript https://docs.learningcommons.org/api-reference/knowledge-graph-api/openapi.yaml -o src/knowledge-graph/kg-api.d.ts", "generate:schemas:check": "tsx scripts/generate-schema.ts --check ../../evals/prompts/purpose/config.json", "build": "tsup", "dev": "tsup --watch", @@ -93,9 +94,9 @@ "@ai-sdk/anthropic": "^3.0.12", "@ai-sdk/google": "^3.0.7", "@ai-sdk/openai": "^3.0.9", + "@eslint/js": "^10.0.1", "@types/node": "^25.6.0", "@types/prompts": "^2.4.9", - "@eslint/js": "^10.0.1", "@typescript-eslint/eslint-plugin": "^8.59.4", "@typescript-eslint/parser": "^8.59.4", "@vitest/coverage-v8": "^4.0.17", @@ -103,6 +104,7 @@ "eslint": "^10.4.0", "globals": "^17.6.0", "json-schema-to-zod": "^2.8.1", + "openapi-typescript": "^7.13.0", "tsup": "^8.0.1", "tsx": "^4.21.0", "typescript": "^5.3.3", diff --git a/sdks/typescript/src/errors.ts b/sdks/typescript/src/errors.ts index 9fd703d..1037867 100644 --- a/sdks/typescript/src/errors.ts +++ b/sdks/typescript/src/errors.ts @@ -160,6 +160,16 @@ export class NetworkError extends APIError { } } +/** + * Knowledge Graph error - thrown when KG API calls fail + */ +export class KnowledgeGraphError extends EvaluatorError { + constructor(message: string, public readonly statusCode?: number) { + super(message, 'KNOWLEDGE_GRAPH_ERROR'); + this.name = 'KnowledgeGraphError'; + } +} + /** * Timeout error - thrown when requests exceed timeout limits * Should be retried with caution diff --git a/sdks/typescript/src/evaluators/base.ts b/sdks/typescript/src/evaluators/base.ts index 67ccdaa..5fab3e2 100644 --- a/sdks/typescript/src/evaluators/base.ts +++ b/sdks/typescript/src/evaluators/base.ts @@ -75,6 +75,9 @@ export interface BaseEvaluatorConfig { /** Learning Commons partner key for authenticated telemetry (optional) */ partnerKey?: string; + /** Learning Commons platform API key — used for Knowledge Graph API access */ + platformApiKey?: string; + /** * Override the provider and model used by this evaluator. * When set, all LLM calls use this provider and model instead of the defaults. diff --git a/sdks/typescript/src/index.ts b/sdks/typescript/src/index.ts index 8366b64..fe3653f 100644 --- a/sdks/typescript/src/index.ts +++ b/sdks/typescript/src/index.ts @@ -17,6 +17,7 @@ export { RateLimitError, NetworkError, TimeoutError, + KnowledgeGraphError, } from './errors.js'; // Logger diff --git a/sdks/typescript/src/knowledge-graph/README.md b/sdks/typescript/src/knowledge-graph/README.md new file mode 100644 index 0000000..9158956 --- /dev/null +++ b/sdks/typescript/src/knowledge-graph/README.md @@ -0,0 +1,12 @@ +# Knowledge Graph client + +HTTP client for the [Learning Commons Knowledge Graph API](https://api.learningcommons.org/knowledge-graph/v0). + +## Regenerate types + +```bash +npm run generate:kg-types +``` + +Pulls from `https://docs.learningcommons.org/api-reference/knowledge-graph-api/openapi.yaml`. +`kg-api.d.ts` is generated — do not edit by hand. diff --git a/sdks/typescript/src/knowledge-graph/client.ts b/sdks/typescript/src/knowledge-graph/client.ts new file mode 100644 index 0000000..53d5bfe --- /dev/null +++ b/sdks/typescript/src/knowledge-graph/client.ts @@ -0,0 +1,176 @@ +import pLimit from 'p-limit'; +import { + KnowledgeGraphError, + AuthenticationError, + RateLimitError, + NetworkError, +} from '../errors.js'; +import type { AcademicStandard, LearningComponent, StandardInfo } from './types.js'; +import type { components } from './kg-api.js'; + +const KG_BASE_URL = 'https://api.learningcommons.org/knowledge-graph/v0'; +const CCSS_FRAMEWORK_UUID = 'c6496676-d7cb-11e8-824f-0242ac160002'; +const KG_TIMEOUT_MS = 30_000; + +type SpecLearningComponent = components['schemas']['LearningComponent']; + +async function kgFetch(url: string, apiKey: string): Promise { + let response: Response; + try { + response = await fetch(url, { + headers: { 'x-api-key': apiKey }, + signal: AbortSignal.timeout(KG_TIMEOUT_MS), + }); + } catch (err) { + if (err instanceof Error && err.name === 'TimeoutError') { + throw new NetworkError(`Knowledge Graph request timed out after ${KG_TIMEOUT_MS}ms`); + } + throw new NetworkError(`Knowledge Graph request failed: ${err instanceof Error ? err.message : String(err)}`); + } + + if (response.ok) { + return response.json().catch((err: unknown) => { + throw new KnowledgeGraphError( + `Knowledge Graph returned invalid JSON: ${err instanceof Error ? err.message : String(err)}`, + ); + }); + } + + const body = await response.text().catch(() => ''); + + if (response.status === 401 || response.status === 403) { + throw new AuthenticationError(`Knowledge Graph authentication failed: ${body}`, response.status); + } + if (response.status === 429) { + throw new RateLimitError(`Knowledge Graph rate limit exceeded: ${body}`); + } + throw new KnowledgeGraphError( + `Knowledge Graph request failed (${response.status}): ${body}`, + response.status, + ); +} + +/** + * HTTP client for the Learning Commons Knowledge Graph API. + * + * Handles standard and learning component lookups with concurrency limiting + * and promise caching. Rejected promises are evicted so transient errors + * (429, network blips) are retryable on the next call. + */ +export class KnowledgeGraphClient { + private readonly apiKey: string; + private readonly limit: ReturnType; + + private readonly standardInfoCache = new Map>(); + private readonly lcCache = new Map>(); + + constructor(apiKey: string, concurrency = 20) { + this.apiKey = apiKey; + this.limit = pLimit(concurrency); + } + + getStandardInfo(statementCode: string): Promise { + let p = this.standardInfoCache.get(statementCode); + if (!p) { + p = this.limit(() => this._fetchStandardInfo(statementCode)); + p = p.catch((err) => { this.standardInfoCache.delete(statementCode); throw err; }); + this.standardInfoCache.set(statementCode, p); + } + return p; + } + + getLearningComponents(caseIdentifierUUID: string): Promise { + let p = this.lcCache.get(caseIdentifierUUID); + if (!p) { + p = this.limit(() => this._fetchLearningComponents(caseIdentifierUUID)); + p = p.catch((err) => { this.lcCache.delete(caseIdentifierUUID); throw err; }); + this.lcCache.set(caseIdentifierUUID, p); + } + return p; + } + + async getStandardsByGrade(grade: string): Promise { + const url = + `${KG_BASE_URL}/academic-standards?limit=500` + + `&standardsFrameworkCaseIdentifierUUID=${CCSS_FRAMEWORK_UUID}` + + `&academicSubject=Mathematics` + + `&gradeLevel=${encodeURIComponent(grade)}` + + `&normalizedStatementType=Standard`; + + const data = (await kgFetch(url, this.apiKey)) as { + data: Array; + pagination?: { hasMore: boolean; nextCursor: string | null }; + }; + + if (data.pagination?.hasMore) { + throw new KnowledgeGraphError( + `getStandardsByGrade returned a paginated result for grade "${grade}" — ` + + `increase limit or implement cursor pagination to retrieve all standards.`, + ); + } + + return (data.data ?? []).map((item) => ({ + caseIdentifierUUID: item.caseIdentifierUUID, + statementCode: item.statementCode, + description: item.description, + statementType: item.statementType, + normalizedStatementType: item.normalizedStatementType, + gradeLevel: item.gradeLevel ?? [], + })); + } + + async getLearningComponentsByCode( + statementCode: string, + ): Promise<{ uuid: string; description?: string; components: LearningComponent[] }> { + const { uuid, description } = await this.getStandardInfo(statementCode); + const components = await this.getLearningComponents(uuid); + return { uuid, description, components }; + } + + // --------------------------------------------------------------------------- + + private async _fetchStandardInfo(statementCode: string): Promise { + const url = `${KG_BASE_URL}/academic-standards/search?jurisdiction=Multi-State&statementCode=${encodeURIComponent(statementCode)}`; + const data = (await kgFetch(url, this.apiKey)) as Array<{ caseIdentifierUUID: string; description?: string }>; + + if (!Array.isArray(data) || data.length === 0) { + throw new KnowledgeGraphError(`Standard not found: "${statementCode}"`); + } + if (data.length > 1) { + throw new KnowledgeGraphError(`Ambiguous standard code: "${statementCode}", ${data.length} results returned`); + } + return { uuid: data[0].caseIdentifierUUID, description: data[0].description }; + } + + private async _fetchLearningComponents(caseIdentifierUUID: string): Promise { + const results: LearningComponent[] = []; + let cursor: string | null = null; + + do { + const url = + `${KG_BASE_URL}/academic-standards/${encodeURIComponent(caseIdentifierUUID)}/learning-components?limit=100` + + (cursor ? `&cursor=${encodeURIComponent(cursor)}` : ''); + + const page = (await kgFetch(url, this.apiKey)) as { + data: SpecLearningComponent[]; + pagination: { hasMore: boolean; nextCursor: string | null }; + }; + + for (const item of page.data ?? []) { + if (item.description != null) { + results.push({ identifier: item.identifier, description: item.description }); + } + } + + const { hasMore, nextCursor } = page.pagination ?? {}; + if (hasMore && !nextCursor) { + throw new KnowledgeGraphError( + `Knowledge Graph pagination error: hasMore=true but nextCursor is null for UUID ${caseIdentifierUUID}`, + ); + } + cursor = hasMore ? (nextCursor ?? null) : null; + } while (cursor !== null); + + return results; + } +} diff --git a/sdks/typescript/src/knowledge-graph/index.ts b/sdks/typescript/src/knowledge-graph/index.ts new file mode 100644 index 0000000..46114f5 --- /dev/null +++ b/sdks/typescript/src/knowledge-graph/index.ts @@ -0,0 +1,2 @@ +export type { AcademicStandard, LearningComponent, StandardInfo } from './types.js'; +export { KnowledgeGraphClient } from './client.js'; diff --git a/sdks/typescript/src/knowledge-graph/kg-api.d.ts b/sdks/typescript/src/knowledge-graph/kg-api.d.ts new file mode 100644 index 0000000..68637ce --- /dev/null +++ b/sdks/typescript/src/knowledge-graph/kg-api.d.ts @@ -0,0 +1,4440 @@ +/** + * This file was auto-generated by openapi-typescript. + * Do not make direct changes to the file. + */ + +export interface paths { + "/courses": { + parameters: { + query?: never; + header?: never; + path?: never; + cookie?: never; + }; + /** + * Courses in a curriculum + * @description Fetches a list of Course objects for a specific curriculum. + * + * A Course consists of a structured sequence of instructional content and activities designed to teach specific skills, knowledge, or competencies over a defined period. It typically encompasses multiple lesson groupings, lessons, and activities and aligns with curriculum standards and intended learning objectives for a particular grade level or subject area. + * + * Use this endpoint when you need to: + * - Discover available courses within a curriculum + * - Get course metadata (name, description, grade levels, subject) + * - Find course identifiers needed for other curriculum endpoints + */ + get: operations["listCourses"]; + put?: never; + post?: never; + delete?: never; + options?: never; + head?: never; + patch?: never; + trace?: never; + }; + "/courses/{courseId}/scope-and-sequence": { + parameters: { + query?: never; + header?: never; + path?: never; + cookie?: never; + }; + /** + * Scope and sequence for a course + * @description Returns the complete hierarchical structure of a course including its lesson groupings and lessons in a scope and sequence format. + * + * The structure follows this hierarchy: + * - Course → Lesson Groupings (can be nested) → Lessons + * + * **Note:** Different curricula use different organizational structures. Lesson groupings might be called units, modules, chapters, sections, themes, etc. depending on the curriculum. The `groupName` property in each lesson grouping indicates what type it is (e.g., "unit", "section", "module"). + * + * Use this endpoint when you need to: + * - Display the complete course outline or table of contents + * - Navigate the course structure programmatically + * - Build a course curriculum map or scope and sequence view + * - Understand the full instructional progression of a course + * + * The `view` parameter controls the level of detail: + * - `summary`: Returns only essential navigation fields (identifiers, names, positions) + * - `full`: Returns complete objects with all properties for each element + */ + get: operations["getCourseScopeAndSequence"]; + put?: never; + post?: never; + delete?: never; + options?: never; + head?: never; + patch?: never; + trace?: never; + }; + "/lesson-groupings/{groupingId}": { + parameters: { + query?: never; + header?: never; + path?: never; + cookie?: never; + }; + /** + * Lesson grouping by ID + * @description Fetches detailed information about a specific lesson grouping. + * + * A lesson grouping organizes a set of related lessons within a curriculum. The naming and organizational level of lesson groupings vary across curricula - they may be called units, modules, chapters, sections, themes, etc. The `groupName` property indicates the specific type used by the curriculum. + * + * Lesson groupings can be nested (e.g., units containing sections, chapters containing modules) as indicated by the `groupLevel` property, where 0 represents the top level. + * + * Use this endpoint when you need to: + * - Get complete metadata for a specific lesson grouping + * - Retrieve organizational details (group name, level, position) + * - Access curriculum-specific labeling and structure information + * - Understand a lesson grouping's place in the course hierarchy + */ + get: operations["getLessonGroupingById"]; + put?: never; + post?: never; + delete?: never; + options?: never; + head?: never; + patch?: never; + trace?: never; + }; + "/lessons/{lessonId}": { + parameters: { + query?: never; + header?: never; + path?: never; + cookie?: never; + }; + /** + * Lesson by ID + * @description Fetches detailed information about a specific lesson. + * + * A lesson represents a focused instructional session within a larger curriculum structure, such as a lesson grouping or course, designed to achieve specific learning objectives. It typically includes activities, discussions, and assessments, and is intended to be completed within a defined timeframe, such as a class period or session. + * + * Use this endpoint when you need to: + * - Get complete metadata for a specific lesson + * - Retrieve lesson details including timing, audience, and educational use + * - Access curriculum-specific labeling information + * - Understand a lesson's place in the course structure + */ + get: operations["getLessonById"]; + put?: never; + post?: never; + delete?: never; + options?: never; + head?: never; + patch?: never; + trace?: never; + }; + "/lessons/{lessonId}/activities": { + parameters: { + query?: never; + header?: never; + path?: never; + cookie?: never; + }; + /** + * Activities in a lesson + * @description Fetches a list of activities within a specific lesson. + * + * An activity represents a discrete instructional task or exercise within a lesson, designed for students, teachers, or both. Activities are the building blocks of lessons and typically include specific tasks, exercises, discussions, or practice problems that help achieve the lesson's learning objectives. + * + * Use this endpoint when you need to: + * - Get all activities for a specific lesson + * - Navigate the instructional components of a lesson + * - Access activity metadata including timing, grouping, and submission requirements + * - Build lesson plans or instructional sequences + */ + get: operations["getLessonActivities"]; + put?: never; + post?: never; + delete?: never; + options?: never; + head?: never; + patch?: never; + trace?: never; + }; + "/lessons/{lessonId}/standards": { + parameters: { + query?: never; + header?: never; + path?: never; + cookie?: never; + }; + /** + * Standards for a lesson + * @description Fetches all academic standards aligned to a specific lesson. + * + * Returns the standards that this lesson addresses through its instructional content and activities. These alignments indicate which learning expectations the lesson is designed to help students achieve. + * + * Use this endpoint when you need to: + * - See which standards a lesson addresses + * - Build standards-aligned lesson plans + * - Track standards coverage across lessons + * - Generate standards-based reports + */ + get: operations["getLessonStandards"]; + put?: never; + post?: never; + delete?: never; + options?: never; + head?: never; + patch?: never; + trace?: never; + }; + "/activities/{activityId}/standards": { + parameters: { + query?: never; + header?: never; + path?: never; + cookie?: never; + }; + /** + * Standards for an activity + * @description Fetches all academic standards aligned to a specific activity. + * + * Returns the standards that this activity addresses. These alignments indicate which learning expectations the activity is designed to help students achieve through specific tasks and exercises. + * + * Use this endpoint when you need to: + * - See which standards an activity addresses + * - Build standards-aligned activities + * - Track standards coverage at the activity level + * - Generate detailed standards-based reports + */ + get: operations["getActivityStandards"]; + put?: never; + post?: never; + delete?: never; + options?: never; + head?: never; + patch?: never; + trace?: never; + }; + "/assessments/{assessmentId}/standards": { + parameters: { + query?: never; + header?: never; + path?: never; + cookie?: never; + }; + /** + * Standards for an assessment + * @description Fetches all academic standards aligned to a specific assessment. + * + * Returns the standards that this assessment evaluates. These alignments indicate which learning expectations the assessment is designed to measure. + * + * Use this endpoint when you need to: + * - See which standards an assessment evaluates + * - Build standards-aligned assessments + * - Track standards coverage in assessments + * - Generate assessment standards reports + */ + get: operations["getAssessmentStandards"]; + put?: never; + post?: never; + delete?: never; + options?: never; + head?: never; + patch?: never; + trace?: never; + }; + "/assessments": { + parameters: { + query?: never; + header?: never; + path?: never; + cookie?: never; + }; + /** + * Assessments in a course + * @description Fetches assessments for a course with optional filtering by lesson or lesson grouping. + * + * Assessments can be associated with different levels of the curriculum hierarchy: + * - **Course-level**: All assessments in the course + * - **Lesson grouping-level**: Assessments for a unit, section, or module (e.g., "End-of-Unit Assessment") + * - **Lesson-level**: Assessments specific to a lesson + * + * Use this endpoint when you need to: + * - Get all assessments for a course + * - Find assessments for a specific lesson grouping (unit, section, module) + * - Find assessments for a specific lesson + * - Build assessment reports or tracking systems + * + * **Note:** You cannot provide both `lessonId` and `lessonGroupingId` in the same request. + */ + get: operations["listAssessments"]; + put?: never; + post?: never; + delete?: never; + options?: never; + head?: never; + patch?: never; + trace?: never; + }; + "/curriculums/{curriculumId}/dependency-map": { + parameters: { + query?: never; + header?: never; + path?: never; + cookie?: never; + }; + /** + * Dependency map for a curriculum + * @description Returns the dependency relationships between lesson groupings within a curriculum. + * + * Dependencies represent prerequisite relationships between lesson groupings (units, sections, modules). + * A dependency from source → target means the target is a prerequisite — it should be taught before the source. + * + * Use this endpoint when you need to: + * - Visualize the dependency graph for a curriculum + * - Understand prerequisite relationships between units or sections + * - Build a dependency-aware course planner or sequencing tool + */ + get: operations["getCurriculumDependencyMap"]; + put?: never; + post?: never; + delete?: never; + options?: never; + head?: never; + patch?: never; + trace?: never; + }; + "/standards-frameworks": { + parameters: { + query?: never; + header?: never; + path?: never; + cookie?: never; + }; + /** + * Standards frameworks + * @description Fetches a list of StandardsFramework objects representing complete academic standards documents. Each standards framework represents a complete standards document published by an official body like a state department of education. + * This endpoint allows you to discover available standards frameworks and retrieve metadata about standards documents from different jurisdictions, subjects, and adoption statuses. + * + * Use this endpoint when you need to: + * - Discover available standards frameworks to query academic standards from + * - Find standards framework UUIDs needed for the GET /academic-standards endpoint + * - Browse standards frameworks by subject, jurisdiction, or adoption status + * - Get standards framework metadata (title, adoption status, modification dates) + * + * **Related topics:** + * - [Understanding StandardsFramework vs StandardsFrameworkItem](/knowledge-graph/entity-and-relationship-reference/academic-standards) + * - [Framework adoption statuses](/knowledge-graph/entity-and-relationship-reference/value-and-format-standards#adoptionstatusenum) + */ + get: operations["listFrameworks"]; + put?: never; + post?: never; + delete?: never; + options?: never; + head?: never; + patch?: never; + trace?: never; + }; + "/academic-standards/{caseIdentifierUUID}": { + parameters: { + query?: never; + header?: never; + path?: never; + cookie?: never; + }; + /** + * Academic standard by ID + * @description Fetches a single StandardsFrameworkItem by its CASE UUID identifier. + * + * A StandardsFrameworkItem represents an individual statement or structural element within a standards framework. These items can be normative statements that specify what students should know or be able to do (e.g., "Describe the impact of a transformation matrix on a graphical object"), or organizational groupings that structure the framework (e.g., domains, strands, clusters). + * + * Use this endpoint when you need to: + * - Display the full details of a specific academic standard in your application + * - Retrieve the exact statement text, grade levels, and classification for a known academic standard + * - Trace an academic standard back to its source in the CASE Network via the CASE identifiers + * + * The response includes the statement text, grade level(s), subject area, jurisdiction, and all source attribution required by the CC BY 4.0 license. + * + * **Related topics:** + * - [Understanding StandardsFrameworkItem vs StandardsFramework](/knowledge-graph/entity-and-relationship-reference/academic-standards) + * - [Standard classification types](/knowledge-graph/entity-and-relationship-reference/value-and-format-standards#normalizedstatementtypeenum) + */ + get: operations["getAcademicStandardByCaseIdentifierUUID"]; + put?: never; + post?: never; + delete?: never; + options?: never; + head?: never; + patch?: never; + trace?: never; + }; + "/academic-standards": { + parameters: { + query?: never; + header?: never; + path?: never; + cookie?: never; + }; + /** + * Academic standards in a framework + * @description Fetches a list of StandardsFrameworkItems for a specific standards framework. + * + * This endpoint retrieves academic standards from a single standards framework identified by its CASE UUID. You can further filter the results by grade level or classification type. This is useful when you need to work with academic standards from a specific state or jurisdiction. + * + * Use this endpoint when you need to: + * - Get all academic standards within a specific standards framework + * - Find academic standards for a particular grade level within a standards framework + * - Filter academic standards by subject area (e.g., only Mathematics academic standards) + * - Filter academic standards by their normalized classification (e.g., only instructional academic standards, not organizational groupings) + * - Retrieve a subset of a standards framework's academic standards for display or processing + * + * The endpoint returns paginated results. Use the `limit` and `cursor` parameters to control the number of results returned and navigate through large result sets. + * + * **Related topics:** + * - [Understanding StandardsFrameworkItem classifications](/knowledge-graph/entity-and-relationship-reference/value-and-format-standards#normalizedstatementtypeenum) + */ + get: operations["listAcademicStandards"]; + put?: never; + post?: never; + delete?: never; + options?: never; + head?: never; + patch?: never; + trace?: never; + }; + "/academic-standards/search": { + parameters: { + query?: never; + header?: never; + path?: never; + cookie?: never; + }; + /** + * Search academic standards + * @description Searches for StandardsFrameworkItems using either semantic search or exact statement code match across all standards frameworks. + * + * This endpoint supports two mutually exclusive search modes: + * + * - **Semantic search** (`query`): Full-text semantic search against the standard's description. Results are ranked by relevance and include a `score` reflecting vector similarity. + * - **Code search** (`statementCode`): Exact statement code match (e.g., "3.NF.A.1"). Case-insensitive, no partial matching. All results carry a `score` of 1.0. + * + * **Exactly one of `query` or `statementCode` must be provided.** Providing both or neither returns a 400 error. + * + * Results can be narrowed further using the optional filters and support cursor-based pagination. + * + * Use this endpoint when you need to: + * - Find academic standards relevant to a concept or learning goal (semantic search) + * - Look up an academic standard by its exact statement code + * - Find all standards frameworks that include a specific statement code + * - Filter search results by grade level, subject, or statement type + * + * **Note:** Not all academic standards have statement codes - some organizational groupings may have null codes and won't appear in code search results. + * + * **Related topics:** + * - [Understanding statement codes](/knowledge-graph/entity-and-relationship-reference/academic-standards#standardsframeworkitem) + */ + get: operations["searchAcademicStandards"]; + put?: never; + post?: never; + delete?: never; + options?: never; + head?: never; + patch?: never; + trace?: never; + }; + "/academic-standards/{caseIdentifierUUID}/children": { + parameters: { + query?: never; + header?: never; + path?: never; + cookie?: never; + }; + /** + * Children of a standard + * @description Fetches StandardsFrameworkItems that are direct children of the specified academic standard through the "hasChild" relationship. + * + * This endpoint retrieves academic standards that are hierarchically organized under the given academic standard. This allows you to navigate down the standards framework hierarchy from domains to clusters to individual academic standards, or from any parent grouping to its children. + * + * Use this endpoint when you need to: + * - Navigate down the standards framework hierarchy (e.g., from domain to academic standards) + * - Get all academic standards within a specific grouping or cluster + * - Build tree visualizations of standards framework structures + * - Explore the organizational structure of a standards document + * + * **Note:** This returns direct children only, not all descendants. To get all descendants, you'll need to traverse multiple levels. + * + * The endpoint returns paginated results. Use the `limit` and `cursor` parameters to control the number of results returned. + * + * **Related topics:** + * - [Understanding the hasChild relationship](/knowledge-graph/entity-and-relationship-reference/academic-standards#haschild) + */ + get: operations["listChildAcademicStandards"]; + put?: never; + post?: never; + delete?: never; + options?: never; + head?: never; + patch?: never; + trace?: never; + }; + "/academic-standards/{caseIdentifierUUID}/prerequisites": { + parameters: { + query?: never; + header?: never; + path?: never; + cookie?: never; + }; + /** + * Prerequisites for a standard + * @description Fetches StandardsFrameworkItems that build towards the specified academic standard through the "buildsTowards" relationship. + * + * This endpoint retrieves academic standards where proficiency supports the likelihood of success in the target academic standard. These are the foundational skills or concepts that contribute to mastery of the given academic standard. The relationship is directional but does not require strict prerequisite order - students don't need to fully master prerequisites before engaging with the target academic standard. + * + * Use this endpoint when you need to: + * - Identify foundational academic standards students should be familiar with before tackling a target academic standard + * - Trace backward through a learning progression to understand dependencies + * - Design remediation or review activities based on prerequisite skills + * - Map out a coherent learning pathway for students + * + * **Note:** Learning progression data is currently based on Student Achievement Partners' Coherence Map for Common Core State Standards for Mathematics. Coverage for other subjects and frameworks may be limited. + * + * The endpoint returns paginated results. Use the `limit` and `cursor` parameters to control the number of results returned. + * + * **Related topics:** + * - [Understanding the buildsTowards relationship](/knowledge-graph/entity-and-relationship-reference/learning-progressions#buildstowards) + */ + get: operations["listPrerequisiteAcademicStandards"]; + put?: never; + post?: never; + delete?: never; + options?: never; + head?: never; + patch?: never; + trace?: never; + }; + "/academic-standards/{caseIdentifierUUID}/builds-towards": { + parameters: { + query?: never; + header?: never; + path?: never; + cookie?: never; + }; + /** + * Standards that build towards a standard + * @description Fetches StandardsFrameworkItems that the specified academic standard builds towards through the "buildsTowards" relationship. + * + * This endpoint retrieves academic standards where proficiency in the given academic standard supports the likelihood of success. These are the next logical learning steps or more advanced concepts that students can progress to after working with the current academic standard. + * + * Use this endpoint when you need to: + * - Identify next steps in a learning progression after students master an academic standard + * - Design curriculum sequences that build on foundational skills + * - Map forward through learning pathways to understand where academic standards lead + * - Plan long-term instructional trajectories for students + * + * **Note:** Learning progression data is currently based on Student Achievement Partners' Coherence Map for Common Core State Standards for Mathematics. Coverage for other subjects and frameworks may be limited. + * + * The endpoint returns paginated results. Use the `limit` and `cursor` parameters to control the number of results returned. + * + * **Related topics:** + * - [Understanding the buildsTowards relationship](/knowledge-graph/entity-and-relationship-reference/learning-progressions#buildstowards) + */ + get: operations["listBuildsTowardsAcademicStandards"]; + put?: never; + post?: never; + delete?: never; + options?: never; + head?: never; + patch?: never; + trace?: never; + }; + "/academic-standards/{caseIdentifierUUID}/related-standards": { + parameters: { + query?: never; + header?: never; + path?: never; + cookie?: never; + }; + /** + * Related standards for a standard + * @description Fetches StandardsFrameworkItems that are related to the specified academic standard through the "relatesTo" relationship. + * + * This endpoint retrieves academic standards that share meaningful conceptual or skill-based links with the given academic standard, without implying a specific sequence or prerequisite order. These lateral connections highlight associations that can inform instructional design, identify reinforcing concepts, or reveal thematic links across academic standards. + * + * Use this endpoint when you need to: + * - Find academic standards with related content or skills for integrated instruction + * - Identify opportunities for reinforcing concepts across different academic standards + * - Design cross-curricular or thematic units that connect related academic standards + * - Discover alternative pathways or parallel concepts in curriculum planning + * + * **Note:** Learning progression data is currently based on Student Achievement Partners' Coherence Map for Common Core State Standards for Mathematics. Coverage for other subjects and frameworks may be limited. + * + * The endpoint returns paginated results. Use the `limit` and `cursor` parameters to control the number of results returned. + * + * **Related topics:** + * - [Understanding the relatesTo relationship](/knowledge-graph/entity-and-relationship-reference/learning-progressions#relatesto) + */ + get: operations["listRelatedAcademicStandards"]; + put?: never; + post?: never; + delete?: never; + options?: never; + head?: never; + patch?: never; + trace?: never; + }; + "/academic-standards/{caseIdentifierUUID}/learning-components": { + parameters: { + query?: never; + header?: never; + path?: never; + cookie?: never; + }; + /** + * Learning components for a standard + * @description Fetches a list of LearningComponents that support a specific StandardsFrameworkItem. + * + * This endpoint retrieves all learning components that are aligned to a given academic standard through the "supports" relationship. Learning components break down broad academic standards into granular, teachable skills, making them actionable for lesson planning and assessment design. + * + * Use this endpoint when you need to: + * - Find the specific skills that compose a given academic standard + * - Identify granular learning targets for instruction aligned to an academic standard + * - Map learning components to your curriculum or assessment items + * - Understand how a broad academic standard breaks down into teachable units + * + * **Note:** Learning component alignments are currently available primarily for Mathematics academic standards. Academic standards in other subjects or certain special categories (e.g., Standards for Mathematical Practice, Pre-K, advanced math) may not have LC alignments. + * + * The endpoint returns paginated results. Use the `limit` and `cursor` parameters to control the number of results returned. + * + * **Related topics:** + * - [Understanding the supports relationship](/knowledge-graph/entity-and-relationship-reference/learning-components#supports) + * - [LC alignment methodology](/knowledge-graph/entity-and-relationship-reference/learning-components#creation-of-lcs) + * - [Available LC coverage by state](/knowledge-graph/entity-and-relationship-reference/learning-components#current-lc-mappings) + */ + get: operations["listLearningComponentsByAcademicStandard"]; + put?: never; + post?: never; + delete?: never; + options?: never; + head?: never; + patch?: never; + trace?: never; + }; + "/academic-standards/{caseIdentifierUUID}/crosswalks": { + parameters: { + query?: never; + header?: never; + path?: never; + cookie?: never; + }; + /** + * Crosswalks for a standard + * @description Fetches a list of standards that align to a specific standard through shared Learning Components. + * + * This endpoint retrieves crosswalk relationships bidirectionally: + * - **State standard → CCSS**: Pass in a state standard to get matching Common Core State Standards + * - **CCSS → State standards**: Pass in a CCSS standard to get matching state standards across jurisdictions + * + * Each crosswalk includes similarity metrics based on measurable overlap of Learning Components to help understand the strength and nature of the alignment. + * + * Crosswalks provide a scalable way to extend mappings between CCSS and state-specific frameworks without independent matching logic. By leveraging the LC superset, crosswalks show where standards converge in content coverage. + * + * Use this endpoint when you need to: + * - Find CCSS standards that align to a state standard for content adaptation + * - Find state standards that align to a CCSS standard across multiple jurisdictions + * - Understand the similarity between standards + * - Map content between Common Core and state frameworks + * - Analyze the degree of overlap between standards + * + * **Note:** Crosswalks are currently available only for Mathematics standards in states where LC alignment exists. Crosswalks are evidence-based (require at least one shared LC). + * + * The endpoint returns paginated results. Use the `limit` and `cursor` parameters to control the number of results returned. + * + * **Related topics:** + * - [Standards crosswalks methodology](/knowledge-graph/entity-and-relationship-reference/standards-crosswalks) + */ + get: operations["listCrosswalkedStandards"]; + put?: never; + post?: never; + delete?: never; + options?: never; + head?: never; + patch?: never; + trace?: never; + }; + "/learning-components/{identifier}": { + parameters: { + query?: never; + header?: never; + path?: never; + cookie?: never; + }; + /** + * Learning component by ID + * @description Fetches a single LearningComponent by its unique identifier. + * + * A LearningComponent represents a single, well-defined skill or concept that students are expected to learn. Learning components are granular units of learning that break down broad state standards into teachable and measurable parts at the level of a lesson, activity, or assessment question. + * + * Use this endpoint when you need to: + * - Display the full details of a specific learning component + * - Retrieve the skill description and metadata for a known learning component + * - Access attribution information for learning components used in your application + * + * Learning components(LCs) are developed through expert-driven processes with input from experienced educators. Currently, LCs are available for mathematics standards across multiple states, with more subjects and states being added over time. + * + * **Related topics:** + * - [Understanding Learning Components](/knowledge-graph/entity-and-relationship-reference/learning-components) + * - [LC creation and alignment process](/knowledge-graph/entity-and-relationship-reference/learning-components#creation-of-lcs) + * - [Available LC mappings by state](/knowledge-graph/entity-and-relationship-reference/learning-components#current-lc-mappings) + */ + get: operations["getLearningComponentByIdentifier"]; + put?: never; + post?: never; + delete?: never; + options?: never; + head?: never; + patch?: never; + trace?: never; + }; + "/academic-standards/{caseIdentifierUUID}/lessons": { + parameters: { + query?: never; + header?: never; + path?: never; + cookie?: never; + }; + /** + * Lessons for a standard + * @description Fetches summary information for all lessons that address a specific academic standard. + * + * Returns lesson summaries (identifier, name, position) that are aligned to this standard, indicating which lessons in the curriculum help students achieve this learning expectation. + * + * Use this endpoint when you need to: + * - Find all lessons that teach a specific standard + * - Build standards-based lesson sequences + * - Track where standards are addressed across the curriculum + * - Generate standards coverage reports + */ + get: operations["getStandardLessons"]; + put?: never; + post?: never; + delete?: never; + options?: never; + head?: never; + patch?: never; + trace?: never; + }; + "/academic-standards/{caseIdentifierUUID}/activities": { + parameters: { + query?: never; + header?: never; + path?: never; + cookie?: never; + }; + /** + * Activities for a standard + * @description Fetches summary information for all activities that address a specific academic standard. + * + * Returns activity summaries (identifier, name, position) that are aligned to this standard, indicating which specific instructional tasks help students achieve this learning expectation. + * + * Use this endpoint when you need to: + * - Find all activities that teach a specific standard + * - Build standards-based activity sets + * - Track standards coverage at the activity level + * - Generate detailed standards alignment reports + */ + get: operations["getStandardActivities"]; + put?: never; + post?: never; + delete?: never; + options?: never; + head?: never; + patch?: never; + trace?: never; + }; + "/academic-standards/{caseIdentifierUUID}/assessments": { + parameters: { + query?: never; + header?: never; + path?: never; + cookie?: never; + }; + /** + * Assessments for a standard + * @description Fetches summary information for all assessments that evaluate a specific academic standard. + * + * Returns assessment summaries (identifier, name) that are aligned to this standard, indicating which assessments measure student achievement of this learning expectation. + * + * Use this endpoint when you need to: + * - Find all assessments that evaluate a specific standard + * - Build standards-based assessment systems + * - Track which standards are assessed + * - Generate assessment coverage reports + */ + get: operations["getStandardAssessments"]; + put?: never; + post?: never; + delete?: never; + options?: never; + head?: never; + patch?: never; + trace?: never; + }; + "/learning-components": { + parameters: { + query?: never; + header?: never; + path?: never; + cookie?: never; + }; + /** + * Learning components by subject + * @description Fetches a list of LearningComponents filtered by academic subject. + * + * This endpoint retrieves learning components for a specific subject area. Learning components are granular skills that break down broad standards into teachable units. Learning components are available for Mathematics and English Language Arts, with additional subjects being developed. + * + * Use this endpoint when you need to: + * - Get all learning components available for a specific subject + * - Browse the complete set of skills/concepts for curriculum planning + * - Retrieve LCs for mapping to your own content or assessments + * - Export learning component data for analysis or integration + * + * The endpoint returns paginated results. Use the `limit` and `cursor` parameters to control the number of results returned and navigate through large result sets. + * + * **Related topics:** + * - [Understanding Learning Components](/knowledge-graph/entity-and-relationship-reference/learning-components) + * - [Available LC coverage by subject and state](/knowledge-graph/entity-and-relationship-reference/learning-components#current-lc-mappings) + */ + get: operations["listLearningComponents"]; + put?: never; + post?: never; + delete?: never; + options?: never; + head?: never; + patch?: never; + trace?: never; + }; + "/learning-components/search": { + parameters: { + query?: never; + header?: never; + path?: never; + cookie?: never; + }; + /** + * Search learning components + * @description This endpoint is for free-text semantic search across learning component descriptions. To retrieve learning components for a specific standard, use [Learning components for a standard](/api-reference/learning-components/learning-components-for-a-standard) instead. + * + * Searches for LearningComponents using semantic search against learning component descriptions. + * + * Results are ranked by relevance to the query text and include a `score` reflecting vector similarity. Use the optional `academicSubject` filter to narrow results to a specific subject area. + * + * Use this endpoint when you need to: + * - Find learning components relevant to a specific skill or concept + * - Discover granular instructional targets related to a teaching goal + * - Search for LCs to map to your own content or assessments + * + * **Related topics:** + * - [Understanding Learning Components](/knowledge-graph/entity-and-relationship-reference/learning-components) + * - [Available LC coverage by subject and state](/knowledge-graph/entity-and-relationship-reference/learning-components#current-lc-mappings) + */ + get: operations["searchLearningComponents"]; + put?: never; + post?: never; + delete?: never; + options?: never; + head?: never; + patch?: never; + trace?: never; + }; +} +export type webhooks = Record; +export interface components { + schemas: { + /** @description An activity represents a discrete instructional task or exercise within a lesson, designed for students, teachers, or both. */ + Activity: { + /** @description The unique identifier of the activity */ + identifier: string; + /** @description The name of the activity */ + name?: string; + /** @description A label combining sequence number with descriptive text (e.g., "Activity 1") */ + ordinalName?: string; + /** @description The position of this activity within its parent lesson */ + position?: number; + /** @description The academic subject */ + academicSubject?: string; + /** @description Specifies the educational grades for which the activity is intended */ + gradeLevel?: string[]; + /** @description The author of the activity */ + author: string; + /** @description The service provider or service operator */ + provider: string; + /** @description The language of the content */ + inLanguage?: string; + /** @description The educational use of the activity */ + educationalUse?: string; + /** @description Specifies the intended audience for the activity */ + audience?: string[]; + /** @description A license document that applies to this content, typically indicated by URL */ + license: string; + /** @description A curriculum-specific categorization of the resource (e.g., "Warm-up", "Cool-down", "Practice") */ + curriculumLabel?: string; + /** @description LMS loading guidance for this activity */ + lmsLoadingGuidance?: string; + /** @description Whether the activity is optional to complete */ + isOptional?: boolean; + /** @description The identifier for the course used by the course provider */ + courseCode?: string; + /** @description Approximate or typical time it usually takes to work with or through the activity (ISO 8601 duration format) */ + timeRequired?: string; + /** @description Describes intended grouping structure for student participation (e.g., "individual", "pair", "small_group", "whole_class") */ + studentGroupingType?: string; + /** + * Format: date + * @description The date on which the activity was created + */ + dateCreated?: string; + /** @description A human-readable attribution statement for this activity */ + attributionStatement?: string; + }; + Course: { + /** @description The unique identifier of the course */ + identifier: string; + /** @description The name of the course */ + name?: string; + /** @description A detailed description of the course */ + description?: string; + /** @description The identifier for the course used by the course provider (e.g., CS101 or 6.001) */ + courseCode?: string; + /** @description The identifier assigned to this resource by its publisher */ + publisherIdentifier?: string | null; + academicSubject?: components["schemas"]["AcademicSubjectENUM"]; + /** @description Specifies the educational grades for which the course is intended */ + gradeLevel?: components["schemas"]["GradeLevelENUM"][]; + /** @description The author of the course */ + author: string; + /** @description The service provider or service operator */ + provider: string; + /** @description The language of the content */ + inLanguage?: string; + /** @description The educational use of the course */ + educationalUse?: string; + /** @description Specifies the intended audience for the course */ + audience?: string[]; + /** @description A license document that applies to this content, typically indicated by URL */ + license: string; + /** @description A curriculum-specific categorization of the resource */ + curriculumLabel?: string; + /** @description LMS loading guidance for this course */ + lmsLoadingGuidance?: string; + /** @description Approximate or typical time it usually takes to work with or through the course (ISO 8601 duration format) */ + timeRequired?: string | null; + /** + * Format: date + * @description The date on which the course was created + */ + dateCreated?: string; + /** @description A human-readable attribution statement for this course */ + attributionStatement?: string; + }; + /** + * @description Curriculum identifier + * @enum {string} + */ + CurriculumIdENUM: "im360"; + /** + * @description US state, territory, or multi-state designation + * @enum {string} + */ + JurisdictionENUM: "Alabama" | "Alaska" | "Arizona" | "Arkansas" | "California" | "Colorado" | "Connecticut" | "Delaware" | "Florida" | "Georgia" | "Hawaii" | "Idaho" | "Illinois" | "Indiana" | "Iowa" | "Kansas" | "Kentucky" | "Louisiana" | "Maine" | "Maryland" | "Massachusetts" | "Michigan" | "Minnesota" | "Mississippi" | "Missouri" | "Montana" | "Nebraska" | "Nevada" | "New Hampshire" | "New Jersey" | "New Mexico" | "New York" | "North Carolina" | "North Dakota" | "Ohio" | "Oklahoma" | "Oregon" | "Pennsylvania" | "Rhode Island" | "South Carolina" | "South Dakota" | "Tennessee" | "Texas" | "Utah" | "Vermont" | "Virginia" | "Washington" | "Washington, D.C." | "West Virginia" | "Wisconsin" | "Wyoming" | "Multi-State"; + /** + * @description Academic subject area + * @enum {string} + */ + AcademicSubjectENUM: "English Language Arts" | "Mathematics" | "Science" | "Social Studies" | "Other"; + /** + * @description Educational grade level + * @enum {string} + */ + GradeLevelENUM: "PK" | "K" | "1" | "2" | "3" | "4" | "5" | "6" | "7" | "8" | "9" | "10" | "11" | "12"; + /** + * @description Adoption status of a standards framework + * @enum {string} + */ + AdoptionStatusENUM: "Draft" | "Proposed" | "Adopted" | "Implemented" | "Retired"; + /** + * @description Language code in BCP 47 format + * @enum {string} + */ + LanguageENUM: "en-US" | "es-US"; + /** + * @description Normalized classification of a standards framework item + * @enum {string} + */ + NormalizedStatementTypeENUM: "Standard" | "Standard Grouping" | "Other"; + /** @description Cursor-based pagination metadata */ + Pagination: { + /** @description Maximum number of results returned per page */ + limit: number; + /** @description Cursor for fetching the next page. Null if no more results available. Pass this value as the 'cursor' parameter in the next request. */ + nextCursor?: string | null; + /** @description Indicates whether there are more results available after this page */ + hasMore: boolean; + }; + /** @description Generic cursor-based paginated response wrapper */ + PaginatedResponse: { + /** @description Array of result items */ + data: Record[]; + pagination: components["schemas"]["Pagination"]; + }; + ScopeAndSequence: components["schemas"]["ScopeAndSequenceSummary"] | components["schemas"]["ScopeAndSequenceFull"]; + /** @description Hierarchical structure of a course showing lesson groupings and lessons (summary view with minimal fields) */ + ScopeAndSequenceSummary: { + /** @description The unique identifier of the course */ + courseId: string; + /** @description The name of the course */ + courseName: string; + /** + * @description The level of detail included in the response (enum property replaced by openapi-typescript) + * @enum {string} + */ + view: "summary"; + /** @description Top-level lesson groupings (e.g., units, modules, chapters) in the course */ + lessonGroupings: components["schemas"]["LessonGroupingNode"][]; + }; + /** @description Hierarchical structure of a course showing lesson groupings and lessons (full view with all metadata) */ + ScopeAndSequenceFull: { + /** @description The unique identifier of the course */ + courseId: string; + /** @description The name of the course */ + courseName: string; + /** + * @description The level of detail included in the response (enum property replaced by openapi-typescript) + * @enum {string} + */ + view: "full"; + /** @description Top-level lesson groupings (e.g., units, modules, chapters) in the course */ + lessonGroupings: components["schemas"]["LessonGroupingNodeFull"][]; + }; + /** @description A lesson grouping node in the course hierarchy for summary view (minimal fields) */ + LessonGroupingNode: { + /** @description The unique identifier of the lesson grouping */ + identifier: string; + /** @description The name of the lesson grouping */ + name: string; + /** @description A label combining sequence number with descriptive text (e.g., "Unit 1", "Chapter 2") */ + ordinalName?: string; + /** @description The type of grouping (e.g., "unit", "section", "module", "chapter") */ + groupName: string; + /** @description The nesting level of this grouping (0 = top level, 1 = nested once, etc.) */ + groupLevel: number; + /** @description The position of this grouping within its parent */ + position: number; + /** @description Nested lesson groupings within this grouping */ + children?: components["schemas"]["LessonGroupingNode"][]; + /** @description Lessons within this grouping */ + lessons?: components["schemas"]["LessonNode"][]; + }; + /** @description A lesson grouping node in the course hierarchy for full view (all metadata fields) */ + LessonGroupingNodeFull: { + /** @description The unique identifier of the lesson grouping */ + identifier: string; + /** @description The name of the lesson grouping */ + name: string; + /** @description A label combining sequence number with descriptive text (e.g., "Unit 1", "Chapter 2") */ + ordinalName?: string; + /** @description The type of grouping (e.g., "unit", "section", "module", "chapter") */ + groupName: string; + /** @description The nesting level of this grouping (0 = top level, 1 = nested once, etc.) */ + groupLevel: number; + /** @description The position of this grouping within its parent */ + position: number; + /** @description The academic subject */ + academicSubject?: string; + /** @description Specifies the educational grades for which the grouping is intended */ + gradeLevel?: string[]; + /** @description The author of the lesson grouping */ + author?: string; + /** @description The service provider or service operator */ + provider?: string; + /** @description The language of the content */ + inLanguage?: string; + /** @description The educational use of the grouping */ + educationalUse?: string; + /** @description Specifies the intended audience for the lesson grouping */ + audience?: string[]; + /** @description A license document that applies to this content, typically indicated by URL */ + license?: string; + /** @description A curriculum-specific categorization of the resource */ + curriculumLabel?: string; + /** @description LMS loading guidance for this lesson grouping */ + lmsLoadingGuidance?: string; + /** @description Whether the lesson grouping is optional to complete */ + isOptional?: boolean; + /** @description The identifier for the course used by the course provider */ + courseCode?: string; + /** @description The identifier assigned to this resource by its publisher */ + publisherIdentifier?: string | null; + /** @description Approximate or typical time it usually takes to work with or through the lesson grouping (ISO 8601 duration format) */ + timeRequired?: string; + /** + * Format: date + * @description The date on which the lesson grouping was created + */ + dateCreated?: string; + /** @description A human-readable attribution statement for this lesson grouping */ + attributionStatement?: string; + /** @description Nested lesson groupings within this grouping */ + children?: components["schemas"]["LessonGroupingNodeFull"][]; + /** @description Lessons within this grouping */ + lessons?: components["schemas"]["LessonNodeFull"][]; + }; + /** @description A lesson node in the course hierarchy for summary view (minimal fields) */ + LessonNode: { + /** @description The unique identifier of the lesson */ + identifier: string; + /** @description The name of the lesson */ + name: string; + /** @description A label combining sequence number with descriptive text (e.g., "Lesson 1") */ + ordinalName?: string; + /** @description The position of this lesson within its parent grouping */ + position: number; + }; + /** @description A lesson node in the course hierarchy for full view (all metadata fields) */ + LessonNodeFull: { + /** @description The unique identifier of the lesson */ + identifier: string; + /** @description The name of the lesson */ + name: string; + /** @description A label combining sequence number with descriptive text (e.g., "Lesson 1") */ + ordinalName?: string; + /** @description The position of this lesson within its parent grouping */ + position: number; + /** @description The academic subject */ + academicSubject?: string; + /** @description Specifies the educational grades for which the lesson is intended */ + gradeLevel?: string[]; + /** @description The author of the lesson */ + author?: string; + /** @description The service provider or service operator */ + provider?: string; + /** @description The language of the content */ + inLanguage?: string; + /** @description The educational use of the lesson */ + educationalUse?: string; + /** @description Specifies the intended audience for the lesson */ + audience?: string[]; + /** @description A license document that applies to this content, typically indicated by URL */ + license?: string; + /** @description A curriculum-specific categorization of the resource */ + curriculumLabel?: string; + /** @description LMS loading guidance for this lesson */ + lmsLoadingGuidance?: string; + /** @description Whether the lesson is optional to complete */ + isOptional?: boolean; + /** @description The identifier for the course used by the course provider */ + courseCode?: string; + /** @description The identifier assigned to this resource by its publisher */ + publisherIdentifier?: string | null; + /** @description Approximate or typical time it usually takes to work with or through the content (ISO 8601 duration format) */ + timeRequired?: string; + /** + * Format: date + * @description The date on which the lesson was created + */ + dateCreated?: string; + /** @description A human-readable attribution statement for this lesson */ + attributionStatement?: string; + }; + /** @description A lesson grouping organizes a set of related lessons within a curriculum. The naming and organizational level may vary across curricula (e.g., unit, module, chapter, section, theme). */ + LessonGrouping: { + /** @description The unique identifier of the lesson grouping */ + identifier: string; + /** @description The name of the lesson grouping */ + name?: string; + /** @description A label combining sequence number with descriptive text (e.g., "Unit 1", "Chapter 2") */ + ordinalName?: string; + /** @description The type of grouping (e.g., "unit", "section", "module", "chapter") */ + groupName: string; + /** @description The nesting level of this grouping (0 = top level, 1 = nested once, etc.) */ + groupLevel: number; + /** @description The position of this grouping within its parent */ + position?: number; + /** @description The academic subject */ + academicSubject?: string; + /** @description Specifies the educational grades for which the grouping is intended */ + gradeLevel?: string[]; + /** @description The author of the lesson grouping */ + author: string; + /** @description The service provider or service operator */ + provider: string; + /** @description The language of the content */ + inLanguage?: string; + /** @description The educational use of the grouping */ + educationalUse?: string; + /** @description Specifies the intended audience for the lesson grouping */ + audience?: string[]; + /** @description A license document that applies to this content, typically indicated by URL */ + license: string; + /** @description A curriculum-specific categorization of the resource */ + curriculumLabel?: string; + /** @description LMS loading guidance for this lesson grouping */ + lmsLoadingGuidance?: string; + /** @description Whether the lesson grouping is optional to complete */ + isOptional?: boolean; + /** @description The identifier for the course used by the course provider */ + courseCode?: string; + /** @description The identifier assigned to this resource by its publisher */ + publisherIdentifier?: string | null; + /** @description Approximate or typical time it usually takes to work with or through the lesson grouping (ISO 8601 duration format) */ + timeRequired?: string | null; + /** + * Format: date + * @description The date on which the lesson grouping was created + */ + dateCreated?: string; + /** @description A human-readable attribution statement for this lesson grouping */ + attributionStatement?: string; + /** @description The lessons contained in this lesson grouping */ + lessons?: components["schemas"]["Lesson"][]; + }; + /** @description A lesson represents a focused instructional session within a larger curriculum structure, such as a lesson grouping or course, designed to achieve specific learning objectives. */ + Lesson: { + /** @description The unique identifier of the lesson */ + identifier: string; + /** @description The name of the lesson */ + name?: string; + /** @description A label combining sequence number with descriptive text (e.g., "Lesson 1") */ + ordinalName?: string; + /** @description The position of this lesson within its parent grouping */ + position?: number; + /** @description The academic subject */ + academicSubject?: string; + /** @description Specifies the educational grades for which the lesson is intended */ + gradeLevel?: string[]; + /** @description The author of the lesson */ + author: string; + /** @description The service provider or service operator */ + provider: string; + /** @description The language of the content */ + inLanguage?: string; + /** @description The educational use of the lesson */ + educationalUse?: string; + /** @description Specifies the intended audience for the lesson */ + audience?: string[]; + /** @description A license document that applies to this content, typically indicated by URL */ + license: string; + /** @description A curriculum-specific categorization of the resource */ + curriculumLabel?: string; + /** @description LMS loading guidance for this lesson */ + lmsLoadingGuidance?: string; + /** @description Whether the lesson is optional to complete */ + isOptional?: boolean; + /** @description The identifier for the course used by the course provider */ + courseCode?: string; + /** @description The identifier assigned to this resource by its publisher */ + publisherIdentifier?: string | null; + /** @description Approximate or typical time it usually takes to work with or through the content (ISO 8601 duration format) */ + timeRequired?: string; + /** + * Format: date + * @description The date on which the lesson was created + */ + dateCreated?: string; + /** @description A human-readable attribution statement for this lesson */ + attributionStatement?: string; + }; + /** + * @description Represents an individual statement or structural element within a standards framework. + * + * StandardsFrameworkItems are the building blocks of academic standards documents. They can be: + * - **Learning expectations**: Normative statements that define what students should know or be able to do (e.g., standards, competencies, performance indicators) + * - **Organizational elements**: Structural groupings that organize learning expectations into coherent units (e.g., domains, strands, clusters, conceptual categories) + * + * Each item preserves the original statement text and metadata from state frameworks while including normalized properties that enable cross-framework queries and comparisons. Items maintain full traceability to their source in the CASE Network through CASE identifiers. + */ + StandardsFrameworkItem: { + /** @description The unique identifier for this item in the Knowledge Graph system. This is a system-generated UUID that remains stable across data updates and can be used to reference this item in queries and relationships. */ + identifier: string; + /** + * Format: uri + * @description A URI referencing the equivalent item in the CASE Network published by 1EdTech. This identifier can be used to trace the corresponding standard in the CASE dataset. + */ + caseIdentifierURI?: string; + /** + * Format: uuid + * @description A UUID referencing the equivalent item in the CASE Network published by 1EdTech. Use this identifier to trace the standard back to its authoritative source, establish equivalence with other systems using CASE data, or cross-reference with official state documentation that includes CASE identifiers. + */ + caseIdentifierUUID: string; + /** @description A short, human-readable code that uniquely identifies this standard within its standards framework context. Typically alphanumeric (e.g., "3.NF.A.1", "A.1B", "MP1") and reflects the standards framework's internal coding scheme. This is the code educators use to reference standards in curriculum materials, lesson plans, and assessment systems. May be null for organizational groupings that don't have assigned codes. */ + statementCode?: string | null; + /** @description The full text of the standard or organizational element, describing what students should know or be able to do */ + description?: string | null; + /** @description The original classification label used by the source standards framework to categorize this item (e.g., "Domain", "Cluster", "Strand", "Benchmark", "Practice Standard"). Unlike normalizedStatementType which standardizes across standards frameworks, this field preserves the exact terminology used in the state's official standards document, which can be helpful for maintaining consistency with state-specific materials and educator expectations. */ + statementType?: string | null; + /** @description A normalized classification that describes the broad functional role of this item, standardized across all standards frameworks regardless of how individual states label their standards. This enables cross-state queries like "find all actual standards" vs "find all organizational groupings". Use this field when you need consistent categorization across multiple jurisdictions. */ + normalizedStatementType?: components["schemas"]["NormalizedStatementTypeENUM"]; + /** @description The state, territory, country, or governing education agency responsible for publishing and adopting this standard. For U.S. state standards, this is the state name (e.g., "Iowa", "California"). This field is essential for filtering standards by location and understanding which standards apply to specific student populations or geographic regions. */ + jurisdiction?: components["schemas"]["JurisdictionENUM"]; + /** @description The academic subject area for this standard */ + academicSubject?: components["schemas"]["AcademicSubjectENUM"]; + /** @description The educational grade level(s) for which this standard is intended. Values are strings to accommodate grade bands and special designations (e.g., "K", "PK", "9-12"). A standard may specify multiple individual grades or grade ranges. Use this field to filter standards appropriate for specific student grade levels. */ + gradeLevel?: components["schemas"]["GradeLevelENUM"][] | null; + /** @description The language of the content, in BCP 47 format */ + inLanguage?: components["schemas"]["LanguageENUM"]; + /** + * Format: date + * @description The date on which this element was most recently modified in the source system (CASE Network). Use this field to track when standards were last updated and identify the most current version of standards data. + */ + dateModified?: string | null; + /** @description Optional field containing additional context, commentary, clarifications, or usage guidance about this standard. May include information about prerequisite knowledge, connections to other standards, or implementation notes from the source framework. */ + notes?: string | null; + /** @description The author or creator of this content, typically the organization that published the standards framework */ + author: string; + /** @description The service provider or organization that makes this data available in the knowledge graph */ + provider: string; + /** + * Format: uri + * @description A URL to the license document that applies to this content + */ + license: string; + /** @description A textual credit that acknowledges the source and creator of this work, as required by the CC BY 4.0 license. If you display or redistribute this standard, you must include this attribution statement to comply with the license terms. */ + attributionStatement: string; + }; + /** @description A StandardsFrameworkItemSummary enriched with a relevance score from the search. */ + AcademicStandardSearchResult: components["schemas"]["StandardsFrameworkItemSummary"] & { + /** + * Format: float + * @description Relevance score between 0 and 1. Higher values indicate stronger alignment with the search criteria. For semantic search, this reflects vector similarity. For exact code match, the score is always 1.0. + */ + score: number; + }; + /** + * @description Represents a complete academic standards document published by an official body like a state department of education. + * + * StandardsFramework serves as the root entity that organizes and contextualizes all standards within a given standards framework. Each standards framework represents a complete standards document with its own jurisdiction, subject area, and adoption status. + */ + StandardsFramework: { + /** @description The unique identifier for this standards framework in the Knowledge Graph system. This is a system-generated identifier that remains stable across data updates. */ + identifier: string; + /** + * Format: uri + * @description A URI referencing the equivalent standards framework in the CASE Network published by 1EdTech. This identifier can be used to trace the corresponding standards framework in the CASE dataset. + */ + caseIdentifierURI?: string; + /** + * Format: uuid + * @description A UUID referencing the equivalent standards framework in the CASE Network published by 1EdTech. Use this identifier to query standards within this standards framework. + */ + caseIdentifierUUID: string; + /** @description The name or title of the standards framework (e.g., "Louisiana Student Standards for English Language Arts", "Iowa Core Mathematics Standards") */ + name?: string | null; + /** @description A description of the standards framework providing additional context or information about the standards document */ + description?: string | null; + /** @description The state, territory, country, or governing education agency responsible for publishing and adopting this standards framework */ + jurisdiction?: components["schemas"]["JurisdictionENUM"]; + /** @description The academic subject area covered by this standards framework */ + academicSubject?: components["schemas"]["AcademicSubjectENUM"]; + /** @description The language of the standards framework content, in BCP 47 format */ + inLanguage?: components["schemas"]["LanguageENUM"]; + /** @description The adoption status of the standards framework within the jurisdiction. Indicates whether the standards framework has been formally adopted, is in development, or has been deprecated. */ + adoptionStatus?: components["schemas"]["AdoptionStatusENUM"]; + /** + * Format: date + * @description The date on which this standards framework was most recently modified. Use this field to track when standards frameworks were last updated. + */ + dateModified?: string | null; + /** @description Optional field containing additional context, commentary, clarifications, or usage guidance about this standards framework */ + notes?: string | null; + /** @description The author or creator of this standards framework, typically the organization that published the standards document */ + author: string; + /** @description The service provider or organization that makes this data available in the knowledge graph */ + provider: string; + /** + * Format: uri + * @description A URL to the license document that applies to this content + */ + license: string; + /** @description A textual credit that acknowledges the source and creator of this work, as required by the CC BY 4.0 license. If you display or redistribute this standards framework, you must include this attribution statement to comply with the license terms. */ + attributionStatement: string; + }; + /** + * @description A lightweight representation of a StandardsFrameworkItem containing only essential identifying information. + * + * This summary format is used in relationship endpoints (learning progressions, related standards) to keep responses fast and enable efficient graph traversal. To retrieve full details for a standard, use the GET /standards/{caseIdentifierUUID} endpoint. + */ + StandardsFrameworkItemSummary: { + /** + * Format: uuid + * @description A UUID referencing the item in the CASE Network published by 1EdTech. Use this identifier to retrieve the full standard details via GET /standards/{caseIdentifierUUID}. + */ + caseIdentifierUUID: string; + /** @description A short, human-readable code that uniquely identifies this standard within its framework context (e.g., "3.NF.A.1", "5.NF.A.1"). May be null for organizational groupings. */ + statementCode?: string | null; + /** @description The full text of the standard describing what students should know or be able to do */ + description?: string | null; + /** @description The state, territory, or jurisdiction responsible for this standard (e.g., "Iowa", "California", "Multi-State") */ + jurisdiction?: components["schemas"]["JurisdictionENUM"]; + /** @description The author or creator of this content, typically the organization that published the standards framework */ + author: string; + /** @description The service provider or organization that makes this data available in the knowledge graph */ + provider: string; + /** + * Format: uri + * @description A URL to the license document that applies to this content + */ + license: string; + /** @description A textual credit that acknowledges the source and creator of this work, as required by the CC BY 4.0 license. If you display or redistribute this standard, you must include this attribution statement to comply with the license terms. */ + attributionStatement: string; + }; + /** @description A StandardsFrameworkItemSummary augmented with the educational alignment type from the source resource (lesson, activity, or assessment) to this standard. */ + StandardsFrameworkItemAlignmentSummary: components["schemas"]["StandardsFrameworkItemSummary"] & { + /** @description Educational alignment types describing how the source resource (lesson, activity, or assessment) relates to this standard. Common values: `addressing` (directly teaches the standard), `building_toward` (scaffolds toward it), `building_on` (builds on prior learning of it), `practicing` (provides practice on it). A single source-standard pair may carry multiple alignment types, in which case all are returned. */ + curriculumAlignmentType?: string[]; + }; + /** @description A lightweight representation of an Activity containing only essential identifying information for alignment endpoints. */ + ActivitySummary: { + /** @description The unique identifier of the activity */ + identifier: string; + /** @description The name of the activity */ + name: string; + /** @description A label combining sequence number with descriptive text (e.g., "Activity 1") */ + ordinalName?: string; + /** @description The author of the activity */ + author: string; + /** @description The service provider */ + provider: string; + /** @description A license document that applies to this content */ + license: string; + /** @description Attribution statement required for license compliance */ + attributionStatement: string; + /** @description Educational alignment types describing how this activity relates to the standard it was queried under. Common values: `addressing` (directly teaches the standard), `building_toward` (scaffolds toward it), `building_on` (builds on prior learning of it), `practicing` (provides practice on it). A single activity-standard pair may carry multiple alignment types, in which case all are returned. */ + curriculumAlignmentType?: string[]; + }; + /** @description An assessment evaluates a student's understanding or mastery of knowledge, skills, or competencies through structured tasks or questions. */ + Assessment: { + /** @description The unique identifier of the assessment */ + identifier: string; + /** @description The name of the assessment */ + name?: string; + /** @description The academic subject */ + academicSubject?: string; + /** @description Specifies the educational grades for which the assessment is intended */ + gradeLevel?: string[]; + /** @description The author of the assessment */ + author: string; + /** @description The service provider or service operator */ + provider: string; + /** @description The language of the content */ + inLanguage?: string; + /** @description The educational use of the assessment */ + educationalUse?: string; + /** @description Specifies the intended audience for the assessment */ + audience?: string[]; + /** @description A license document that applies to this content, typically indicated by URL */ + license: string; + /** @description A curriculum-specific categorization of the resource */ + curriculumLabel?: string; + /** @description LMS loading guidance for this assessment */ + lmsLoadingGuidance?: string; + /** @description Whether the assessment is optional to complete */ + isOptional?: boolean; + /** @description The identifier for the course used by the course provider */ + courseCode?: string; + /** @description The identifier assigned to this resource by its publisher */ + publisherIdentifier?: string | null; + /** @description Describes intended grouping structure for student participation (e.g., "individual", "pair", "small_group") */ + studentGroupingType?: string; + /** @description Approximate or typical time it usually takes to work with or through the assessment (ISO 8601 duration format) */ + timeRequired?: string | null; + /** + * Format: date + * @description The date on which the assessment was created + */ + dateCreated?: string; + /** @description A human-readable attribution statement for this assessment */ + attributionStatement?: string; + }; + /** @description A lightweight representation of an Assessment containing only essential identifying information for alignment endpoints. */ + AssessmentSummary: { + /** @description The unique identifier of the assessment */ + identifier: string; + /** @description The name of the assessment */ + name: string; + /** @description The author of the assessment */ + author: string; + /** @description The service provider */ + provider: string; + /** @description A license document that applies to this content */ + license: string; + /** @description Attribution statement required for license compliance */ + attributionStatement: string; + /** @description Educational alignment types describing how this assessment relates to the standard it was queried under. Common values: `addressing` (directly teaches the standard), `building_toward` (scaffolds toward it), `building_on` (builds on prior learning of it), `practicing` (provides practice on it). A single assessment-standard pair may carry multiple alignment types, in which case all are returned. */ + curriculumAlignmentType?: string[]; + }; + /** @description A lightweight representation of a Lesson containing only essential identifying information for alignment endpoints. */ + LessonSummary: { + /** @description The unique identifier of the lesson */ + identifier: string; + /** @description The name of the lesson */ + name: string; + /** @description A label combining sequence number with descriptive text (e.g., "Lesson 1") */ + ordinalName?: string; + /** @description The author of the lesson */ + author: string; + /** @description The service provider */ + provider: string; + /** @description A license document that applies to this content */ + license: string; + /** @description Attribution statement required for license compliance */ + attributionStatement: string; + /** @description Educational alignment types describing how this lesson relates to the standard it was queried under. Common values: `addressing` (directly teaches the standard), `building_toward` (scaffolds toward it), `building_on` (builds on prior learning of it), `practicing` (provides practice on it). A single lesson-standard pair may carry multiple alignment types, in which case all are returned. */ + curriculumAlignmentType?: string[]; + }; + /** + * @description Represents a crosswalk relationship between two standards, including similarity metrics based on shared Learning Components. + * + * Crosswalks connect mathematics standards bidirectionally based on measurable overlap of Learning Components: + * - **State → CCSS**: When querying with a state standard, this represents an aligned CCSS standard + * - **CCSS → State**: When querying with a CCSS standard, this represents an aligned state standard + * + * Each crosswalk includes quantitative measures that help understand the strength and nature of the alignment. + * + * The Jaccard similarity score measures the proportion of shared Learning Components between the two standards, with scores ranging from 0 (no overlap) to 1 (complete overlap). Higher scores indicate stronger similarity in content coverage. + */ + StandardCrosswalk: { + /** + * Format: uuid + * @description The CASE UUID of the aligned standard. Use this identifier to retrieve the full standard details via GET /academic-standards/{caseIdentifierUUID}. + */ + caseIdentifierUUID: string; + /** @description The statement code of the aligned standard (e.g., "3.NF.A.1" for CCSS, "MA.3.NF.1" for Massachusetts). May be null for organizational groupings. */ + statementCode?: string | null; + /** @description The full text of the aligned standard describing what students should know or be able to do */ + description?: string | null; + /** @description The jurisdiction of the aligned standard. For CCSS standards, this is "Multi-State". For state standards, this is the state name (e.g., "Iowa", "Massachusetts"). */ + jurisdiction?: string | null; + /** + * Format: float + * @description The Jaccard similarity score representing the proportion of shared Learning Components between the state standard and CCSS standard. Values range from greater than 0 to 1, where 1 indicates complete overlap and values closer to 0 indicate minimal overlap. Calculated as sharedLCCount / (stateLCCount + ccssLCCount - sharedLCCount). + */ + jaccard?: number; + /** @description The number of Learning Components that support the state standard */ + stateLCCount?: number; + /** @description The number of Learning Components that support the CCSS standard */ + ccssLCCount?: number; + /** @description The number of Learning Components shared by both the state standard and the CCSS standard. This is the evidence basis for the crosswalk relationship. */ + sharedLCCount?: number; + /** @description The author or creator of this content, typically the organization that published the standards framework */ + author: string; + /** @description The service provider or organization that makes this data available in the knowledge graph */ + provider: string; + /** + * Format: uri + * @description A URL to the license document that applies to this content + */ + license: string; + /** @description A textual credit that acknowledges the source and creator of this work, as required by the CC BY 4.0 license. If you display or redistribute this standard, you must include this attribution statement to comply with the license terms. */ + attributionStatement: string; + }; + /** + * @description A lightweight representation of a LearningComponent containing only essential information. + * + * This summary format is used in relationship endpoints (standards to learning components) to keep responses fast and enable efficient traversal. To retrieve full details for a learning component, use the GET /learning-components/{identifier} endpoint. + */ + LearningComponentSummary: { + /** @description The unique identifier for this learning component in the Knowledge Graph system. Use this identifier to retrieve the full learning component details via GET /learning-components/{identifier}. */ + identifier: string; + /** @description A clear, concise statement describing the specific skill or concept this learning component represents. */ + description?: string | null; + /** @description The author or creator of this learning component, typically the organization that developed the LC framework */ + author: string; + /** @description The service provider or organization that makes this data available in the knowledge graph */ + provider: string; + /** + * Format: uri + * @description A URL to the license document that applies to this content + */ + license: string; + /** @description A textual credit that acknowledges the source and creator of this work, as required by the CC BY 4.0 license. If you display or redistribute this learning component, you must include this attribution statement to comply with the license terms. */ + attributionStatement: string; + }; + /** @description A LearningComponentSummary enriched with a relevance score from the search. */ + LearningComponentSearchResult: components["schemas"]["LearningComponentSummary"] & { + /** + * Format: float + * @description Relevance score between 0 and 1 reflecting semantic similarity to the search query. Higher values indicate stronger alignment with the query text. + */ + score: number; + }; + /** + * @description Represents a single, well-defined skill or concept that students are expected to learn. + * + * Learning Components are granular, precise representations of individual skills or concepts that break down broad educational standards into teachable and measurable parts. While state standards often define learning goals at a high level (sometimes encompassing multiple ideas across weeks of instruction), LCs operate at the level where instruction happens: during a lesson, an activity, or a single question. + * + * Each LC is: + * - **Instructionally actionable**: Designed to guide daily teaching decisions and interventions + * - **Aligned to academic standards**: Connected to CASE-aligned standards through semantic relationships + * - **Interoperable**: Usable across diverse curricula, assessments, and platforms + * - **Machine-readable and human-interpretable**: Tagged with unique identifiers to support AI-driven content recommendations with transparent intent + * + * LCs are developed through collaborative, expert-driven processes with input from experienced educators. + */ + LearningComponent: { + /** @description The unique identifier for this learning component in the Knowledge Graph system. This is a system-generated identifier that remains stable across data updates and can be used to reference this LC in queries and relationships. */ + identifier: string; + /** @description A clear, concise statement describing the specific skill or concept this learning component represents. This is the instructional target that can be taught in a lesson or assessed in a question. */ + description?: string; + /** @description The academic subject area for this learning component. Learning components are available for Mathematics and English Language Arts, with additional subjects being developed. */ + academicSubject?: components["schemas"]["AcademicSubjectENUM"]; + /** @description The language of the content, in BCP 47 format */ + inLanguage?: components["schemas"]["LanguageENUM"]; + /** + * Format: date + * @description The date on which this learning component was created + */ + dateCreated?: string | null; + /** + * Format: date + * @description The date on which this learning component was most recently modified. Use this field to track when LCs were last updated. + */ + dateModified?: string | null; + /** @description Illustrative examples of the learning component in practice. Each example demonstrates how the skill or concept might appear in an instructional context. */ + examples?: string[] | null; + /** @description The author or creator of this learning component, typically the organization that developed the LC framework */ + author: string; + /** @description The service provider or organization that makes this data available in the knowledge graph */ + provider: string; + /** + * Format: uri + * @description A URL to the license document that applies to this content + */ + license: string; + /** @description A textual credit that acknowledges the source and creator of this work, as required by the CC BY 4.0 license. If you display or redistribute this learning component, you must include this attribution statement to comply with the license terms. */ + attributionStatement: string; + }; + /** @description A lesson grouping that is depended upon (a prerequisite). */ + DependencyTarget: { + /** @description The unique identifier of the target lesson grouping */ + identifier: string; + /** @description The name of the target lesson grouping */ + name?: string; + /** @description The curriculum label of the target lesson grouping (e.g., "Unit", "Section") */ + curriculumLabel?: string; + }; + /** @description A lesson grouping and the other lesson groupings it depends on (prerequisites). */ + Dependency: { + /** @description The identifier of the source lesson grouping */ + source: string; + /** @description The name of the source lesson grouping */ + sourceName?: string; + /** @description The curriculum label of the source lesson grouping (e.g., "Unit", "Section") */ + sourceCurriculumLabel?: string; + /** @description Lesson groupings that this source has a dependency on (prerequisites) */ + hasDependency: components["schemas"]["DependencyTarget"][]; + }; + /** @description Paginated dependency map for a curriculum, listing dependency relationships between lesson groupings grouped by source. */ + DependencyMapResponse: { + /** @description List of dependency relationships between lesson groupings, grouped by source */ + dependencies: components["schemas"]["Dependency"][]; + pagination: components["schemas"]["Pagination"]; + }; + /** @description Standard error response object returned for all error conditions */ + Error: { + /** @description A machine-readable error type identifier (e.g., ValidationError, NotFoundError, InternalServerError) */ + error: string; + /** @description A human-readable error message that explains what went wrong and may include actionable guidance */ + message: string; + /** @description A unique identifier for this request, useful for debugging and support */ + requestId: string; + /** @description Optional additional details about the error, such as validation failures or field-specific issues */ + details?: { + [key: string]: unknown; + }; + }; + }; + responses: never; + parameters: { + /** @description Maximum number of results to return. Default is 100. Maximum allowed is 1000. */ + LimitParam: number; + /** @description Cursor for pagination. Obtain this value from the 'nextCursor' field in the previous response. Omit for the first page. */ + CursorParam: string; + /** @description The CASE UUID identifier from the CASE Network published by 1EdTech */ + CaseIdentifierUUIDPath: string; + /** @description The unique identifier for the learning component in the Knowledge Graph system */ + LearningComponentIdentifierPath: string; + /** @description Filter by jurisdiction (state/territory) */ + JurisdictionParam: components["schemas"]["JurisdictionENUM"]; + /** @description Filter by academic subject area */ + AcademicSubjectParam: components["schemas"]["AcademicSubjectENUM"]; + /** + * @description Filter by grade level. Can be specified multiple times to include multiple grades. + * @example [ + * "9", + * "10" + * ] + */ + GradeLevelParam: components["schemas"]["GradeLevelENUM"][]; + }; + requestBodies: never; + headers: never; + pathItems: never; +} +export type $defs = Record; +export interface operations { + listCourses: { + parameters: { + query: { + /** @description The identifier for the curriculum to retrieve courses from. */ + curriculumId: components["schemas"]["CurriculumIdENUM"]; + /** @description Maximum number of results to return. Default is 100. Maximum allowed is 1000. */ + limit?: components["parameters"]["LimitParam"]; + /** @description Cursor for pagination. Obtain this value from the 'nextCursor' field in the previous response. Omit for the first page. */ + cursor?: components["parameters"]["CursorParam"]; + }; + header?: never; + path?: never; + cookie?: never; + }; + requestBody?: never; + responses: { + /** @description Successfully retrieved list of courses */ + 200: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "data": [ + * { + * "identifier": "im:b532b7df-4989-53a2-8f53-8dd829343423", + * "name": "Geometry", + * "description": "For the first several units, students practice making conjectures and observations. This begins with work on compass and straightedge constructions. Students gradually build up to writing formal proofs in narrative form engaging in a cycle of conjecture, rough draft, peer feedback, and final draft.", + * "courseCode": "im360:Geo", + * "academicSubject": "Mathematics", + * "gradeLevel": [ + * "high_school", + * "9", + * "10", + * "11", + * "12" + * ], + * "author": "Illustrative Mathematics", + * "provider": "Learning Commons", + * "inLanguage": "English", + * "educationalUse": "instruction", + * "audience": [ + * "Teacher", + * "Student", + * "Family" + * ], + * "license": "https://creativecommons.org/licenses/by-nc/4.0/", + * "dateCreated": "2020-06-25" + * }, + * { + * "identifier": "im:1459a7dd-a3cd-5540-ada3-60553e2d5987", + * "name": "Integrated Math 2", + * "description": "Students begin the course making observations about triangles. Building from these observations, students gather experimental information, develop conjectures, write informal justifications, and then progress to writing formal proofs using definitions, assertions, and theorems developed in Math 1.", + * "courseCode": "im360:Math2", + * "academicSubject": "Mathematics", + * "gradeLevel": [ + * "high_school", + * "9", + * "10", + * "11", + * "12" + * ], + * "author": "Illustrative Mathematics", + * "provider": "Learning Commons", + * "inLanguage": "English", + * "educationalUse": "instruction", + * "audience": [ + * "Teacher", + * "Student", + * "Family" + * ], + * "license": "https://creativecommons.org/licenses/by-nc/4.0/", + * "dateCreated": "2023-08-22" + * } + * ], + * "pagination": { + * "limit": 100, + * "nextCursor": "aW06MTQ1OWE3ZGQtYTNjZC01NTQwLWFkYTMtNjA1NTNlMmQ1OTg3", + * "hasMore": false + * } + * } + */ + "application/json": components["schemas"]["PaginatedResponse"] & { + data?: components["schemas"]["Course"][]; + }; + }; + }; + /** @description Bad request - Invalid query parameters */ + 400: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "ValidationError", + * "message": "Invalid query parameter value provided", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + /** @description Unprocessable Entity - Invalid curriculumId value */ + 422: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "ValidationError", + * "message": "Input should be 'im360'", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + /** @description Internal server error */ + 500: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "InternalServerError", + * "message": "An unexpected error occurred while retrieving courses", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + }; + }; + getCourseScopeAndSequence: { + parameters: { + query?: { + /** + * @description Controls the level of detail in the response. + * - `summary`: Returns only identifiers, names, and positions (lightweight) + * - `full`: Returns complete objects with all properties (heavyweight) + */ + view?: "summary" | "full"; + }; + header?: never; + path: { + /** @description The unique identifier of the course */ + courseId: string; + }; + cookie?: never; + }; + requestBody?: never; + responses: { + /** @description Successfully retrieved course scope and sequence */ + 200: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "courseId": "im:b532b7df-4989-53a2-8f53-8dd829343423", + * "courseName": "Geometry", + * "view": "summary", + * "lessonGroupings": [ + * { + * "identifier": "im:87b50a26-acbf-5798-ac94-ca1423679acd", + * "name": "Constructions and Rigid Transformations", + * "ordinalName": "Unit 1", + * "groupName": "unit", + * "groupLevel": 0, + * "position": 0, + * "lessons": null, + * "children": [ + * { + * "identifier": "im:section-a-001", + * "name": "Constructions", + * "ordinalName": "Section A", + * "groupName": "section", + * "groupLevel": 1, + * "position": 0, + * "children": null, + * "lessons": [ + * { + * "identifier": "im:lesson-001", + * "name": "Build It", + * "ordinalName": "Lesson 1", + * "position": 0 + * }, + * { + * "identifier": "im:lesson-002", + * "name": "Constructing Patterns", + * "ordinalName": "Lesson 2", + * "position": 1 + * } + * ] + * }, + * { + * "identifier": "im:section-b-001", + * "name": "Defining Rigid Transformations", + * "ordinalName": "Section B", + * "groupName": "section", + * "groupLevel": 1, + * "position": 1, + * "children": null, + * "lessons": [ + * { + * "identifier": "im:lesson-006", + * "name": "Transformation Times", + * "ordinalName": "Lesson 6", + * "position": 0 + * } + * ] + * } + * ] + * }, + * { + * "identifier": "im:9cc92808-016e-5b7b-865f-dab6764cb504", + * "name": "Congruence", + * "ordinalName": "Unit 2", + * "groupName": "unit", + * "groupLevel": 0, + * "position": 1, + * "lessons": null, + * "children": [ + * { + * "identifier": "im:section-a-002", + * "name": "Congruent Parts, Congruent Figures", + * "ordinalName": "Section A", + * "groupName": "section", + * "groupLevel": 1, + * "position": 0, + * "children": null, + * "lessons": [ + * { + * "identifier": "im:lesson-008", + * "name": "Moving Through Transformations", + * "ordinalName": "Lesson 8", + * "position": 0 + * } + * ] + * } + * ] + * } + * ] + * } + */ + "application/json": components["schemas"]["ScopeAndSequence"]; + }; + }; + /** @description Bad request - Invalid query parameters */ + 400: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "ValidationError", + * "message": "Invalid query parameter value provided", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + /** @description Course not found */ + 404: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "NotFoundError", + * "message": "Course with identifier 'im:invalid-id' not found", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + /** @description Unprocessable Entity - Invalid view parameter value */ + 422: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "ValidationError", + * "message": "Input should be 'summary' or 'full'", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + /** @description Internal server error */ + 500: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "InternalServerError", + * "message": "An unexpected error occurred while retrieving course scope and sequence", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + }; + }; + getLessonGroupingById: { + parameters: { + query?: never; + header?: never; + path: { + /** @description The unique identifier of the lesson grouping */ + groupingId: string; + }; + cookie?: never; + }; + requestBody?: never; + responses: { + /** @description Successfully retrieved lesson grouping */ + 200: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "identifier": "im:857861da-50c7-5302-b288-d0b2d4f82188", + * "name": "Complex Numbers", + * "ordinalName": "Unit 6", + * "groupName": "unit", + * "groupLevel": 0, + * "position": 5, + * "academicSubject": "Mathematics", + * "gradeLevel": [ + * "high_school", + * "9", + * "10", + * "11", + * "12" + * ], + * "author": "Illustrative Mathematics", + * "provider": "Learning Commons", + * "inLanguage": "English", + * "educationalUse": "instruction", + * "audience": [ + * "Teacher", + * "Student", + * "Family" + * ], + * "license": "https://creativecommons.org/licenses/by-nc/4.0/", + * "curriculumLabel": "Unit", + * "lmsLoadingGuidance": "unspecified", + * "isOptional": true, + * "courseCode": "im360:Math2", + * "dateCreated": "2023-08-22" + * } + */ + "application/json": components["schemas"]["LessonGrouping"]; + }; + }; + /** @description Bad request - Invalid groupingId format */ + 400: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "ValidationError", + * "message": "Invalid grouping identifier format", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + /** @description Lesson grouping not found */ + 404: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "NotFoundError", + * "message": "Lesson grouping with identifier 'im:invalid-id' not found", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + /** @description Internal server error */ + 500: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "InternalServerError", + * "message": "An unexpected error occurred while retrieving the lesson grouping", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + }; + }; + getLessonById: { + parameters: { + query?: never; + header?: never; + path: { + /** @description The unique identifier of the lesson */ + lessonId: string; + }; + cookie?: never; + }; + requestBody?: never; + responses: { + /** @description Successfully retrieved lesson */ + 200: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "identifier": "im:2ebf72dc-53f8-557b-b804-fca624be807a", + * "name": "Using Functions to Model Battery Power", + * "ordinalName": "Lesson 18", + * "position": 17, + * "academicSubject": "Mathematics", + * "gradeLevel": [ + * "high_school", + * "9", + * "10", + * "11", + * "12" + * ], + * "author": "Illustrative Mathematics", + * "provider": "Learning Commons", + * "inLanguage": "English", + * "educationalUse": "instruction", + * "audience": [ + * "Teacher", + * "Student", + * "Family" + * ], + * "license": "https://creativecommons.org/licenses/by-nc/4.0/", + * "curriculumLabel": "Lesson", + * "lmsLoadingGuidance": "unspecified", + * "isOptional": false, + * "courseCode": "im360:Alg1", + * "timeRequired": "PT45M", + * "dateCreated": "2020-06-25" + * } + */ + "application/json": components["schemas"]["Lesson"]; + }; + }; + /** @description Bad request - Invalid lessonId format */ + 400: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "ValidationError", + * "message": "Invalid lesson identifier format", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + /** @description Lesson not found */ + 404: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "NotFoundError", + * "message": "Lesson with identifier 'im:invalid-id' not found", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + /** @description Internal server error */ + 500: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "InternalServerError", + * "message": "An unexpected error occurred while retrieving the lesson", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + }; + }; + getLessonActivities: { + parameters: { + query?: { + /** @description Maximum number of results to return. Default is 100. Maximum allowed is 1000. */ + limit?: components["parameters"]["LimitParam"]; + /** @description Cursor for pagination. Obtain this value from the 'nextCursor' field in the previous response. Omit for the first page. */ + cursor?: components["parameters"]["CursorParam"]; + }; + header?: never; + path: { + /** @description The unique identifier of the lesson */ + lessonId: string; + }; + cookie?: never; + }; + requestBody?: never; + responses: { + /** @description Successfully retrieved list of activities */ + 200: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "data": [ + * { + * "identifier": "im:98928b4e-0183-5e0e-955d-230653db7332", + * "name": "Devices", + * "ordinalName": "Activity 1", + * "position": 0, + * "academicSubject": "Mathematics", + * "gradeLevel": [ + * "high_school", + * "9", + * "10", + * "11", + * "12" + * ], + * "author": "Illustrative Mathematics", + * "provider": "Learning Commons", + * "inLanguage": "English", + * "educationalUse": "instruction", + * "audience": [ + * "Teacher", + * "Student", + * "Family" + * ], + * "license": "https://creativecommons.org/licenses/by-nc/4.0/", + * "curriculumLabel": "Warm-up", + * "lmsLoadingGuidance": "unspecified", + * "isOptional": false, + * "courseCode": "im360:Alg1", + * "timeRequired": "PT5M", + * "studentGroupingType": "pair", + * "dateCreated": "2020-06-25" + * } + * ], + * "pagination": { + * "limit": 100, + * "nextCursor": null, + * "hasMore": false + * } + * } + */ + "application/json": components["schemas"]["PaginatedResponse"] & { + data?: components["schemas"]["Activity"][]; + }; + }; + }; + /** @description Bad request - Invalid query parameters */ + 400: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "ValidationError", + * "message": "Invalid query parameter value provided", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + /** @description Lesson not found */ + 404: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "NotFoundError", + * "message": "Lesson with identifier 'im:invalid-id' not found", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + /** @description Internal server error */ + 500: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "InternalServerError", + * "message": "An unexpected error occurred while retrieving activities", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + }; + }; + getLessonStandards: { + parameters: { + query?: { + /** @description Maximum number of results to return. Default is 100. Maximum allowed is 1000. */ + limit?: components["parameters"]["LimitParam"]; + /** @description Cursor for pagination. Obtain this value from the 'nextCursor' field in the previous response. Omit for the first page. */ + cursor?: components["parameters"]["CursorParam"]; + }; + header?: never; + path: { + /** @description The unique identifier of the lesson */ + lessonId: string; + }; + cookie?: never; + }; + requestBody?: never; + responses: { + /** @description Successfully retrieved list of aligned standards */ + 200: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "data": [ + * { + * "identifier": "7b0d37ef-9b49-59cb-936c-3ead359aed05", + * "caseIdentifierUUID": "6ba17134-d7cc-11e8-824f-0242ac160002", + * "author": "1EdTech", + * "provider": "Learning Commons", + * "license": "https://creativecommons.org/licenses/by/4.0/", + * "attributionStatement": "Knowledge Graph is provided by Learning Commons under the CC BY-4.0 license. Learning Commons received state standards and written permission under CC BY-4.0 from 1EdTech." + * } + * ], + * "pagination": { + * "limit": 100, + * "nextCursor": null, + * "hasMore": false + * } + * } + */ + "application/json": components["schemas"]["PaginatedResponse"] & { + data?: components["schemas"]["StandardsFrameworkItemAlignmentSummary"][]; + }; + }; + }; + /** @description Lesson not found */ + 404: { + headers: { + [name: string]: unknown; + }; + content: { + "application/json": components["schemas"]["Error"]; + }; + }; + /** @description Internal server error */ + 500: { + headers: { + [name: string]: unknown; + }; + content: { + "application/json": components["schemas"]["Error"]; + }; + }; + }; + }; + getActivityStandards: { + parameters: { + query?: { + /** @description Maximum number of results to return. Default is 100. Maximum allowed is 1000. */ + limit?: components["parameters"]["LimitParam"]; + /** @description Cursor for pagination. Obtain this value from the 'nextCursor' field in the previous response. Omit for the first page. */ + cursor?: components["parameters"]["CursorParam"]; + }; + header?: never; + path: { + /** @description The unique identifier of the activity */ + activityId: string; + }; + cookie?: never; + }; + requestBody?: never; + responses: { + /** @description Successfully retrieved list of aligned standards */ + 200: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "data": [ + * { + * "identifier": "7b0d37ef-9b49-59cb-936c-3ead359aed05", + * "caseIdentifierUUID": "6ba17134-d7cc-11e8-824f-0242ac160002", + * "author": "1EdTech", + * "provider": "Learning Commons", + * "license": "https://creativecommons.org/licenses/by/4.0/", + * "attributionStatement": "Knowledge Graph is provided by Learning Commons under the CC BY-4.0 license. Learning Commons received state standards and written permission under CC BY-4.0 from 1EdTech." + * } + * ], + * "pagination": { + * "limit": 100, + * "nextCursor": null, + * "hasMore": false + * } + * } + */ + "application/json": components["schemas"]["PaginatedResponse"] & { + data?: components["schemas"]["StandardsFrameworkItemAlignmentSummary"][]; + }; + }; + }; + /** @description Activity not found */ + 404: { + headers: { + [name: string]: unknown; + }; + content: { + "application/json": components["schemas"]["Error"]; + }; + }; + /** @description Internal server error */ + 500: { + headers: { + [name: string]: unknown; + }; + content: { + "application/json": components["schemas"]["Error"]; + }; + }; + }; + }; + getAssessmentStandards: { + parameters: { + query?: { + /** @description Maximum number of results to return. Default is 100. Maximum allowed is 1000. */ + limit?: components["parameters"]["LimitParam"]; + /** @description Cursor for pagination. Obtain this value from the 'nextCursor' field in the previous response. Omit for the first page. */ + cursor?: components["parameters"]["CursorParam"]; + }; + header?: never; + path: { + /** @description The unique identifier of the assessment */ + assessmentId: string; + }; + cookie?: never; + }; + requestBody?: never; + responses: { + /** @description Successfully retrieved list of aligned standards */ + 200: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "data": [ + * { + * "identifier": "7b0d37ef-9b49-59cb-936c-3ead359aed05", + * "caseIdentifierUUID": "6ba17134-d7cc-11e8-824f-0242ac160002", + * "author": "1EdTech", + * "provider": "Learning Commons", + * "license": "https://creativecommons.org/licenses/by/4.0/", + * "attributionStatement": "Knowledge Graph is provided by Learning Commons under the CC BY-4.0 license. Learning Commons received state standards and written permission under CC BY-4.0 from 1EdTech." + * } + * ], + * "pagination": { + * "limit": 100, + * "nextCursor": null, + * "hasMore": false + * } + * } + */ + "application/json": components["schemas"]["PaginatedResponse"] & { + data?: components["schemas"]["StandardsFrameworkItemAlignmentSummary"][]; + }; + }; + }; + /** @description Assessment not found */ + 404: { + headers: { + [name: string]: unknown; + }; + content: { + "application/json": components["schemas"]["Error"]; + }; + }; + /** @description Internal server error */ + 500: { + headers: { + [name: string]: unknown; + }; + content: { + "application/json": components["schemas"]["Error"]; + }; + }; + }; + }; + listAssessments: { + parameters: { + query: { + /** @description The unique identifier of the course */ + courseId: string; + /** @description Filter to assessments for a specific lesson (cannot be used with lessonGroupingId) */ + lessonId?: string; + /** @description Filter to assessments for a specific lesson grouping (cannot be used with lessonId) */ + lessonGroupingId?: string; + /** @description Maximum number of results to return. Default is 100. Maximum allowed is 1000. */ + limit?: components["parameters"]["LimitParam"]; + /** @description Cursor for pagination. Obtain this value from the 'nextCursor' field in the previous response. Omit for the first page. */ + cursor?: components["parameters"]["CursorParam"]; + }; + header?: never; + path?: never; + cookie?: never; + }; + requestBody?: never; + responses: { + /** @description Successfully retrieved list of assessments */ + 200: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "data": [ + * { + * "identifier": "im:d540d085-5435-5b3c-875b-9c810a18d81a", + * "name": "Practice Problems", + * "academicSubject": "Mathematics", + * "gradeLevel": [ + * "4", + * "elementary_school" + * ], + * "author": "Illustrative Mathematics", + * "provider": "Learning Commons", + * "inLanguage": "English", + * "educationalUse": "assessment", + * "audience": [ + * "Teacher", + * "Student", + * "Family" + * ], + * "license": "https://creativecommons.org/licenses/by-nc/4.0/", + * "curriculumLabel": "Practice Problems", + * "lmsLoadingGuidance": "unspecified", + * "isOptional": false, + * "courseCode": "im360:4", + * "studentGroupingType": "individual", + * "dateCreated": "2021-04-30" + * } + * ], + * "pagination": { + * "limit": 100, + * "nextCursor": null, + * "hasMore": false + * } + * } + */ + "application/json": components["schemas"]["PaginatedResponse"] & { + data?: components["schemas"]["Assessment"][]; + }; + }; + }; + /** @description Bad request - Invalid query parameters or both lessonId and lessonGroupingId provided */ + 400: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "ValidationError", + * "message": "Cannot provide both lessonId and lessonGroupingId", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + /** @description Course, lesson, or lesson grouping not found */ + 404: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "NotFoundError", + * "message": "Course with identifier 'im:invalid-id' not found", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + /** @description Unprocessable Entity - Missing required courseId parameter */ + 422: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "ValidationError", + * "message": "Field required: courseId", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + /** @description Internal server error */ + 500: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "InternalServerError", + * "message": "An unexpected error occurred while retrieving assessments", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + }; + }; + getCurriculumDependencyMap: { + parameters: { + query?: { + /** @description Maximum number of results to return. Default is 100. Maximum allowed is 1000. */ + limit?: components["parameters"]["LimitParam"]; + /** @description Cursor for pagination. Obtain this value from the 'nextCursor' field in the previous response. Omit for the first page. */ + cursor?: components["parameters"]["CursorParam"]; + }; + header?: never; + path: { + /** @description The identifier for the curriculum to retrieve dependencies for. */ + curriculumId: components["schemas"]["CurriculumIdENUM"]; + }; + cookie?: never; + }; + requestBody?: never; + responses: { + /** @description Successfully retrieved dependency map */ + 200: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "dependencies": [ + * { + * "source": "im:87b50a26-acbf-5798-ac94-ca1423679acd", + * "sourceName": "Angles, Triangles, and Prisms", + * "sourceCurriculumLabel": "Unit", + * "hasDependency": [ + * { + * "identifier": "im:a0e15ae9-dd70-5df0-93ad-9d6b99fc5ad2", + * "name": "Area and Surface Area", + * "curriculumLabel": "Unit" + * }, + * { + * "identifier": "im:c5f3b8d1-4e92-5a6c-b7d8-2f1e9a3c6b4d", + * "name": "Angles and Angle Measurement", + * "curriculumLabel": "Unit" + * } + * ] + * }, + * { + * "source": "im:d4e2f1a0-8b7c-5d3e-9f6a-1c2b4d5e8f7a", + * "sourceName": "Constructions", + * "sourceCurriculumLabel": "Section", + * "hasDependency": [ + * { + * "identifier": "im:e7f6a5b4-3c2d-5e1f-8a9b-0d1c2e3f4a5b", + * "name": "Defining Rigid Transformations", + * "curriculumLabel": "Section" + * } + * ] + * } + * ], + * "pagination": { + * "limit": 100, + * "nextCursor": "eyJpZGVudGlmaWVyIjoiaW06ZDRlMmYxYTAtOGI3Yy01ZDNlLTlmNmEtMWMyYjRkNWU4ZjdhIn0=", + * "hasMore": true + * } + * } + */ + "application/json": components["schemas"]["DependencyMapResponse"]; + }; + }; + /** @description Bad request - Invalid query parameters */ + 400: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "ValidationError", + * "message": "Invalid cursor format", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + /** @description Unprocessable Entity - Invalid curriculumId value */ + 422: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "ValidationError", + * "message": "Input should be 'im360'", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + /** @description Internal server error */ + 500: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "InternalServerError", + * "message": "An unexpected error occurred while retrieving the dependency map", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + }; + }; + listFrameworks: { + parameters: { + query?: { + /** @description Filter by jurisdiction (state/territory) */ + jurisdiction?: components["parameters"]["JurisdictionParam"]; + /** @description Filter by academic subject area */ + academicSubject?: components["parameters"]["AcademicSubjectParam"]; + /** @description Filter standards frameworks by their adoption status */ + adoptionStatus?: components["schemas"]["AdoptionStatusENUM"]; + /** @description Maximum number of results to return. Default is 100. Maximum allowed is 1000. */ + limit?: components["parameters"]["LimitParam"]; + /** @description Cursor for pagination. Obtain this value from the 'nextCursor' field in the previous response. Omit for the first page. */ + cursor?: components["parameters"]["CursorParam"]; + }; + header?: never; + path?: never; + cookie?: never; + }; + requestBody?: never; + responses: { + /** @description Successfully retrieved list of standards frameworks */ + 200: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "data": [ + * { + * "identifier": "00bcc689-c7a6-5ef4-ac09-c868f9e25a06", + * "caseIdentifierURI": "https://satchelcommons.com/ims/case/v1p0/CFDocuments/822e5a6e-bcb0-45b8-bb82-a2c88d5b4bb7", + * "caseIdentifierUUID": "822e5a6e-bcb0-45b8-bb82-a2c88d5b4bb7", + * "name": "K-12 New Hampshire Social Studies Curriculum Framework", + * "description": null, + * "jurisdiction": "New Hampshire", + * "academicSubject": "Social Studies", + * "inLanguage": "en-US", + * "adoptionStatus": "Implemented", + * "dateCreated": null, + * "dateModified": "2023-11-19", + * "notes": null, + * "author": "1EdTech", + * "provider": "Learning Commons", + * "license": "https://creativecommons.org/licenses/by/4.0/", + * "attributionStatement": "Knowledge Graph is provided by Learning Commons under the CC BY-4.0 license. Learning Commons received state standards and written permission under CC BY-4.0 from 1EdTech." + * }, + * { + * "identifier": "02575dee-30d0-50fd-b0e6-182da76f63a5", + * "caseIdentifierURI": "https://satchelcommons.com/ims/case/v1p0/CFDocuments/50a88167-d6f5-41ea-a6c1-ee1ea83b6820", + * "caseIdentifierUUID": "50a88167-d6f5-41ea-a6c1-ee1ea83b6820", + * "name": "North Carolina Standard Course of Study: Social Studies", + * "description": null, + * "jurisdiction": "North Carolina", + * "academicSubject": "Social Studies", + * "inLanguage": "en-US", + * "adoptionStatus": "Implemented", + * "dateCreated": null, + * "dateModified": "2024-04-08", + * "notes": null, + * "author": "1EdTech", + * "provider": "Learning Commons", + * "license": "https://creativecommons.org/licenses/by/4.0/", + * "attributionStatement": "Knowledge Graph is provided by Learning Commons under the CC BY-4.0 license. Learning Commons received state standards and written permission under CC BY-4.0 from 1EdTech." + * } + * ], + * "pagination": { + * "limit": 100, + * "nextCursor": "eyJpZGVudGlmaWVyIjogIjczYTJhNWY5LWRjOGUtNWE3Yi1iMzc4LTYzZGNmOWViZjFiNSJ9", + * "hasMore": true + * } + * } + */ + "application/json": components["schemas"]["PaginatedResponse"] & { + data?: components["schemas"]["StandardsFramework"][]; + }; + }; + }; + /** @description Bad request - Invalid query parameters */ + 400: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "ValidationError", + * "message": "Invalid query parameter value provided", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + /** @description Unprocessable Entity - Invalid parameter values (e.g., enum value not in allowed list) */ + 422: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "ValidationError", + * "message": "Input should be 'Draft', 'Proposed', 'Adopted', 'Implemented', or 'Retired'", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + /** @description Internal server error */ + 500: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "InternalServerError", + * "message": "An unexpected error occurred while retrieving standards frameworks", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + }; + }; + getAcademicStandardByCaseIdentifierUUID: { + parameters: { + query?: never; + header?: never; + path: { + /** @description The CASE UUID identifier from the CASE Network published by 1EdTech */ + caseIdentifierUUID: components["parameters"]["CaseIdentifierUUIDPath"]; + }; + cookie?: never; + }; + requestBody?: never; + responses: { + /** @description Successfully retrieved the standard */ + 200: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "identifier": "b15d0fc6-94b7-5bae-9e62-2c30813b4c0f", + * "caseIdentifierURI": "https://satchelcommons.com/ims/case/v1p0/CFItems/6b9ee241-d7cc-11e8-824f-0242ac160002", + * "caseIdentifierUUID": "6b9ee241-d7cc-11e8-824f-0242ac160002", + * "name": null, + * "statementCode": "6.NS.B.4", + * "description": "Find the greatest common factor of two whole numbers less than or equal to 100 and the least common multiple of two whole numbers less than or equal to 12. Use the distributive property to express a sum of two whole numbers 1—100 with a common factor as a multiple of a sum of two whole numbers with no common factor. *For example, express $36 + 8$ as $4(9 + 2)$.*", + * "statementType": "Standard", + * "normalizedStatementType": "Standard", + * "jurisdiction": "Multi-State", + * "academicSubject": "Mathematics", + * "gradeLevel": [ + * "6" + * ], + * "inLanguage": "en-US", + * "dateCreated": null, + * "dateModified": "2025-02-05", + * "notes": null, + * "author": "1EdTech", + * "provider": "Learning Commons", + * "license": "https://creativecommons.org/licenses/by/4.0/", + * "attributionStatement": "Knowledge Graph is provided by Learning Commons under the CC BY-4.0 license. Learning Commons received state standards and written permission under CC BY-4.0 from 1EdTech." + * } + */ + "application/json": components["schemas"]["StandardsFrameworkItem"]; + }; + }; + /** @description Bad request - Invalid CASE UUID format */ + 400: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "ValidationError", + * "message": "Invalid CASE UUID format. Must be a valid UUID (e.g., \"6bd8552e-6f8f-4538-bf33-d016ac080178\").. Must be a valid UUID (e.g., \"6bd8552e-6f8f-4538-bf33-d016ac080178\").", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + /** @description Academic standard not found */ + 404: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "NotFoundError", + * "message": "Academic standard with CASE UUID \"6bd8552e-6f8f-4538-bf33-d016ac080178\" not found. Verify the UUID is correct.", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + /** @description Internal server error */ + 500: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "InternalServerError", + * "message": "An unexpected error occurred while retrieving the academic standard", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + }; + }; + listAcademicStandards: { + parameters: { + query: { + /** @description The CASE UUID of the standards framework to retrieve academic standards from. This identifies which state or jurisdictional standards framework to query. You must provide this parameter to scope the academic standards query to a specific standards framework. */ + standardsFrameworkCaseIdentifierUUID: string; + /** + * @description Filter by grade level. Can be specified multiple times to include multiple grades. + * @example [ + * "9", + * "10" + * ] + */ + gradeLevel?: components["parameters"]["GradeLevelParam"]; + /** @description Filter by academic subject area */ + academicSubject?: components["parameters"]["AcademicSubjectParam"]; + /** @description Filter standards by their normalized classification. Use this to retrieve only instructional standards (exclude organizational groupings) or to separate different types of framework elements. */ + normalizedStatementType?: components["schemas"]["NormalizedStatementTypeENUM"]; + /** @description Maximum number of results to return. Default is 100. Maximum allowed is 1000. */ + limit?: components["parameters"]["LimitParam"]; + /** @description Cursor for pagination. Obtain this value from the 'nextCursor' field in the previous response. Omit for the first page. */ + cursor?: components["parameters"]["CursorParam"]; + }; + header?: never; + path?: never; + cookie?: never; + }; + requestBody?: never; + responses: { + /** @description Successfully retrieved list of standards */ + 200: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "data": [ + * { + * "identifier": "8e73cea8-f61d-5ac4-bcef-a84a331618d6", + * "caseIdentifierURI": "https://satchelcommons.com/ims/case/v1p0/CFItems/65b82d75-d7cc-11e8-824f-0242ac160002", + * "caseIdentifierUUID": "65b82d75-d7cc-11e8-824f-0242ac160002", + * "name": null, + * "statementCode": null, + * "description": "Standards for Mathematical Practice", + * "statementType": null, + * "normalizedStatementType": null, + * "jurisdiction": "Vermont", + * "academicSubject": "Mathematics", + * "gradeLevel": [ + * "K", + * "1", + * "2", + * "3", + * "4", + * "5", + * "6", + * "7", + * "8", + * "9", + * "10", + * "11", + * "12" + * ], + * "inLanguage": "en-US", + * "dateCreated": null, + * "dateModified": "2023-11-19", + * "notes": null, + * "author": "1EdTech", + * "provider": "Learning Commons", + * "license": "https://creativecommons.org/licenses/by/4.0/", + * "attributionStatement": "Knowledge Graph is provided by Learning Commons under the CC BY-4.0 license. Learning Commons received state standards and written permission under CC BY-4.0 from 1EdTech." + * } + * ], + * "pagination": { + * "limit": 1, + * "nextCursor": "eyJpZGVudGlmaWVyIjogIjhlNzNjZWE4LWY2MWQtNWFjNC1iY2VmLWE4NGEzMzE2MThkNiJ9", + * "hasMore": true + * } + * } + */ + "application/json": components["schemas"]["PaginatedResponse"] & { + data?: components["schemas"]["StandardsFrameworkItem"][]; + }; + }; + }; + /** @description Bad request - Missing required parameter or using invalid filter values */ + 400: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "ValidationError", + * "message": "Missing required parameter: standardsFrameworkCaseIdentifierUUID. Example: ?standardsFrameworkCaseIdentifierUUID=c6493f4d-d7cb-11e8-824f-0242ac160002", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + /** @description Unprocessable Entity - Invalid parameter values (e.g., enum value not in allowed list) */ + 422: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "ValidationError", + * "message": "Input should be 'Standard', 'Standard Grouping', or 'Other'", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + /** @description Internal server error */ + 500: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "InternalServerError", + * "message": "An unexpected error occurred while retrieving academic standards", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + }; + }; + searchAcademicStandards: { + parameters: { + query?: { + /** @description Free-text query for semantic search against academic standard descriptions. Results are ranked by relevance score. Mutually exclusive with `statementCode`. */ + query?: string; + /** @description The exact statement code to search for. Case-insensitive exact match only (e.g., "3.NF.A.1" matches "3.nf.a.1"). Mutually exclusive with `query`. */ + statementCode?: string; + /** + * @description Filter by grade level. Can be specified multiple times to include multiple grades. + * @example [ + * "9", + * "10" + * ] + */ + gradeLevel?: components["parameters"]["GradeLevelParam"]; + /** @description Filter results by academic subject area. */ + academicSubject?: components["schemas"]["AcademicSubjectENUM"]; + /** @description Filter results by normalized statement type. Use this to retrieve only instructional standards (exclude organizational groupings) or to separate different types of framework elements. */ + normalizedStatementType?: components["schemas"]["NormalizedStatementTypeENUM"]; + /** @description Filter by jurisdiction (state/territory). Defaults to Multi-State. */ + jurisdiction?: components["schemas"]["JurisdictionENUM"]; + /** @description Maximum number of results to return. Default is 5. Maximum allowed is 50. */ + limit?: number; + }; + header?: never; + path?: never; + cookie?: never; + }; + requestBody?: never; + responses: { + /** @description Successfully retrieved search results */ + 200: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example [ + * { + * "caseIdentifierUUID": "fa29b90a-2795-4bf5-b6bc-3ac4a695e9e2", + * "statementCode": "6.NS.B.4", + * "description": "Find the greatest common factor of two whole numbers less than or equal to 100 and the least common multiple of two whole numbers less than or equal to 12.", + * "jurisdiction": "Washington, D.C.", + * "author": "1EdTech", + * "provider": "Learning Commons", + * "license": "https://creativecommons.org/licenses/by/4.0/", + * "attributionStatement": "Knowledge Graph is provided by Learning Commons under the CC BY-4.0 license.", + * "score": 0.92 + * }, + * { + * "caseIdentifierUUID": "61b03523-d7cc-11e8-824f-0242ac160002", + * "statementCode": "6.NS.B.4", + * "description": "Find the greatest common factor of two whole numbers less than or equal to 100 and the least common multiple of two whole numbers less than or equal to 12.", + * "jurisdiction": "Maryland", + * "author": "1EdTech", + * "provider": "Learning Commons", + * "license": "https://creativecommons.org/licenses/by/4.0/", + * "attributionStatement": "Knowledge Graph is provided by Learning Commons under the CC BY-4.0 license.", + * "score": 0.87 + * } + * ] + */ + "application/json": components["schemas"]["AcademicStandardSearchResult"][]; + }; + }; + /** @description Bad request - exactly one of query or statementCode must be provided */ + 400: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "ValidationError", + * "message": "Exactly one of query or statementCode must be provided. Example: ?query=greatest+common+factor or ?statementCode=3.NF.A.1", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + /** @description Unprocessable Entity - Invalid parameter values (e.g., enum value not in allowed list) */ + 422: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "ValidationError", + * "message": "Input should be 'Alabama', 'Alaska', ..., or 'Multi-State'", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + /** @description Internal server error */ + 500: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "InternalServerError", + * "message": "An unexpected error occurred while searching for academic standards", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + }; + }; + listChildAcademicStandards: { + parameters: { + query?: { + /** @description Maximum number of results to return. Default is 100. Maximum allowed is 1000. */ + limit?: components["parameters"]["LimitParam"]; + /** @description Cursor for pagination. Obtain this value from the 'nextCursor' field in the previous response. Omit for the first page. */ + cursor?: components["parameters"]["CursorParam"]; + }; + header?: never; + path: { + /** @description The CASE UUID identifier from the CASE Network published by 1EdTech */ + caseIdentifierUUID: components["parameters"]["CaseIdentifierUUIDPath"]; + }; + cookie?: never; + }; + requestBody?: never; + responses: { + /** @description Successfully retrieved list of child standards */ + 200: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "data": [ + * { + * "identifier": "3a650f7a-3b10-55d0-9d07-c2bdf8e08175", + * "caseIdentifierURI": "https://satchelcommons.com/ims/case/v1p0/CFItems/6b9c2b26-d7cc-11e8-824f-0242ac160002", + * "caseIdentifierUUID": "6b9c2b26-d7cc-11e8-824f-0242ac160002", + * "name": null, + * "statementCode": "6.RP.A.1", + * "description": "Understand the concept of a ratio and use ratio language to describe a ratio relationship between two quantities. *For example, \"The ratio of wings to beaks in the bird house at the zoo was 2:1, because for every 2 wings there was 1 beak.\" \"For every vote candidate A received, candidate C received nearly three votes.\"*", + * "statementType": "Standard", + * "normalizedStatementType": "Standard", + * "jurisdiction": "Multi-State", + * "academicSubject": "Mathematics", + * "gradeLevel": [ + * "6" + * ], + * "inLanguage": "en-US", + * "dateCreated": null, + * "dateModified": "2025-02-05", + * "notes": null, + * "author": "1EdTech", + * "provider": "Learning Commons", + * "license": "https://creativecommons.org/licenses/by/4.0/", + * "attributionStatement": "Knowledge Graph is provided by Learning Commons under the CC BY-4.0 license. Learning Commons received state standards and written permission under CC BY-4.0 from 1EdTech." + * }, + * { + * "identifier": "c3126032-2984-5b67-9ed5-2f2f0821e99f", + * "caseIdentifierURI": "https://satchelcommons.com/ims/case/v1p0/CFItems/6b9d6aa3-d7cc-11e8-824f-0242ac160002", + * "caseIdentifierUUID": "6b9d6aa3-d7cc-11e8-824f-0242ac160002", + * "name": null, + * "statementCode": "6.RP.A.2", + * "description": "Understand the concept of a unit rate $\\frac{a}{b}$ associated with a ratio a:b with $b \\neq 0$, and use rate language in the context of a ratio relationship.", + * "statementType": "Standard", + * "normalizedStatementType": "Standard", + * "jurisdiction": "Multi-State", + * "academicSubject": "Mathematics", + * "gradeLevel": [ + * "6" + * ], + * "inLanguage": "en-US", + * "dateCreated": null, + * "dateModified": "2025-02-05", + * "notes": "Expectations for unit rates in this grade are limited to non-complex fractions.", + * "author": "1EdTech", + * "provider": "Learning Commons", + * "license": "https://creativecommons.org/licenses/by/4.0/", + * "attributionStatement": "Knowledge Graph is provided by Learning Commons under the CC BY-4.0 license. Learning Commons received state standards and written permission under CC BY-4.0 from 1EdTech." + * } + * ], + * "pagination": { + * "limit": 2, + * "nextCursor": "eyJpZGVudGlmaWVyIjogImMzMTI2MDMyLTI5ODQtNWI2Ny05ZWQ1LTJmMmYwODIxZTk5ZiJ9", + * "hasMore": true + * } + * } + */ + "application/json": components["schemas"]["PaginatedResponse"] & { + data?: components["schemas"]["StandardsFrameworkItemSummary"][]; + }; + }; + }; + /** @description Bad request - Invalid CASE UUID or pagination parameters */ + 400: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "ValidationError", + * "message": "Invalid pagination parameter. Limit must be between 1 and 1000 (e.g., limit=100). Cursor must be a valid base64-encoded string from a previous response.", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + /** @description Academic standard not found */ + 404: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "NotFoundError", + * "message": "Academic standard with CASE UUID \"6bd8552e-6f8f-4538-bf33-d016ac080178\" not found. Verify the UUID is correct.", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + /** @description Internal server error */ + 500: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "InternalServerError", + * "message": "An unexpected error occurred while retrieving child standards", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + }; + }; + listPrerequisiteAcademicStandards: { + parameters: { + query?: { + /** @description Maximum number of results to return. Default is 100. Maximum allowed is 1000. */ + limit?: components["parameters"]["LimitParam"]; + /** @description Cursor for pagination. Obtain this value from the 'nextCursor' field in the previous response. Omit for the first page. */ + cursor?: components["parameters"]["CursorParam"]; + }; + header?: never; + path: { + /** @description The CASE UUID identifier from the CASE Network published by 1EdTech */ + caseIdentifierUUID: components["parameters"]["CaseIdentifierUUIDPath"]; + }; + cookie?: never; + }; + requestBody?: never; + responses: { + /** @description Successfully retrieved list of prerequisite standards */ + 200: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "data": [ + * { + * "caseIdentifierUUID": "6b9ee241-d7cc-11e8-824f-0242ac160002", + * "statementCode": "5.OA.A.2", + * "description": "Write simple expressions that record calculations with numbers, and interpret numerical expressions without evaluating them. *For example, express the calculation \"add 8 and 7, then multiply by 2\" as $2 \\times (8 + 7)$. Recognize that $3 \\times (18932 + 921)$ is three times as large as 18932 + 921, without having to calculate the indicated sum or product.*", + * "author": "1EdTech", + * "provider": "Learning Commons", + * "license": "https://creativecommons.org/licenses/by/4.0/", + * "attributionStatement": "Knowledge Graph is provided by Learning Commons under the CC BY-4.0 license. Learning Commons received state standards and written permission under CC BY-4.0 from 1EdTech." + * }, + * { + * "caseIdentifierUUID": "6b9ed00e-d7cc-11e8-824f-0242ac160002", + * "statementCode": "4.OA.B.4", + * "description": "Find all factor pairs for a whole number in the range 1—100. Recognize that a whole number is a multiple of each of its factors. Determine whether a given whole number in the range 1—100 is a multiple of a given one-digit number. Determine whether a given whole number in the range 1—100 is prime or composite.", + * "author": "1EdTech", + * "provider": "Learning Commons", + * "license": "https://creativecommons.org/licenses/by/4.0/", + * "attributionStatement": "Knowledge Graph is provided by Learning Commons under the CC BY-4.0 license. Learning Commons received state standards and written permission under CC BY-4.0 from 1EdTech." + * } + * ], + * "pagination": { + * "limit": 100, + * "nextCursor": null, + * "hasMore": false + * } + * } + */ + "application/json": components["schemas"]["PaginatedResponse"] & { + data?: components["schemas"]["StandardsFrameworkItemSummary"][]; + }; + }; + }; + /** @description Bad request - Invalid CASE UUID or pagination parameters */ + 400: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "ValidationError", + * "message": "Invalid CASE UUID format. Must be a valid UUID (e.g., \"6bd8552e-6f8f-4538-bf33-d016ac080178\").", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + /** @description Academic standard not found */ + 404: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "NotFoundError", + * "message": "Academic standard with CASE UUID \"6bd8552e-6f8f-4538-bf33-d016ac080178\" not found. Verify the UUID is correct.", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + /** @description Internal server error */ + 500: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "InternalServerError", + * "message": "An unexpected error occurred while retrieving prerequisite standards", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + }; + }; + listBuildsTowardsAcademicStandards: { + parameters: { + query?: { + /** @description Maximum number of results to return. Default is 100. Maximum allowed is 1000. */ + limit?: components["parameters"]["LimitParam"]; + /** @description Cursor for pagination. Obtain this value from the 'nextCursor' field in the previous response. Omit for the first page. */ + cursor?: components["parameters"]["CursorParam"]; + }; + header?: never; + path: { + /** @description The CASE UUID identifier from the CASE Network published by 1EdTech */ + caseIdentifierUUID: components["parameters"]["CaseIdentifierUUIDPath"]; + }; + cookie?: never; + }; + requestBody?: never; + responses: { + /** @description Successfully retrieved list of standards this standard builds towards */ + 200: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "data": [ + * { + * "caseIdentifierUUID": "6b9e3b67-d7cc-11e8-824f-0242ac160002", + * "statementCode": "6.EE.A.3", + * "description": "Apply the properties of operations to generate equivalent expressions. *For example, apply the distributive property to the expression $3(2 + x)$ to produce the equivalent expression 6 + 3x; apply the distributive property to the expression 24x + 18y to produce the equivalent expression $6(4x + 3y)$; apply properties of operations to y + y + y to produce the equivalent expression 3y.*", + * "author": "1EdTech", + * "provider": "Learning Commons", + * "license": "https://creativecommons.org/licenses/by/4.0/", + * "attributionStatement": "Knowledge Graph is provided by Learning Commons under the CC BY-4.0 license. Learning Commons received state standards and written permission under CC BY-4.0 from 1EdTech." + * }, + * { + * "caseIdentifierUUID": "6b9edd45-d7cc-11e8-824f-0242ac160002", + * "statementCode": "6.EE.A.4", + * "description": "Identify when two expressions are equivalent (i.e., when the two expressions name the same number regardless of which value is substituted into them). *For example, the expressions y + y + y and 3y are equivalent because they name the same number regardless of which number y stands for.*", + * "author": "1EdTech", + * "provider": "Learning Commons", + * "license": "https://creativecommons.org/licenses/by/4.0/", + * "attributionStatement": "Knowledge Graph is provided by Learning Commons under the CC BY-4.0 license. Learning Commons received state standards and written permission under CC BY-4.0 from 1EdTech." + * } + * ], + * "pagination": { + * "limit": 100, + * "nextCursor": null, + * "hasMore": false + * } + * } + */ + "application/json": components["schemas"]["PaginatedResponse"] & { + data?: components["schemas"]["StandardsFrameworkItemSummary"][]; + }; + }; + }; + /** @description Bad request - Invalid CASE UUID or pagination parameters */ + 400: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "ValidationError", + * "message": "Invalid CASE UUID format. Must be a valid UUID (e.g., \"6bd8552e-6f8f-4538-bf33-d016ac080178\").", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + /** @description Academic standard not found */ + 404: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "NotFoundError", + * "message": "Academic standard with CASE UUID \"6bd8552e-6f8f-4538-bf33-d016ac080178\" not found. Verify the UUID is correct.", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + /** @description Internal server error */ + 500: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "InternalServerError", + * "message": "An unexpected error occurred while retrieving standards this standard builds towards", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + }; + }; + listRelatedAcademicStandards: { + parameters: { + query?: { + /** @description Maximum number of results to return. Default is 100. Maximum allowed is 1000. */ + limit?: components["parameters"]["LimitParam"]; + /** @description Cursor for pagination. Obtain this value from the 'nextCursor' field in the previous response. Omit for the first page. */ + cursor?: components["parameters"]["CursorParam"]; + }; + header?: never; + path: { + /** @description The CASE UUID identifier from the CASE Network published by 1EdTech */ + caseIdentifierUUID: components["parameters"]["CaseIdentifierUUIDPath"]; + }; + cookie?: never; + }; + requestBody?: never; + responses: { + /** @description Successfully retrieved list of related standards */ + 200: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "data": [ + * { + * "caseIdentifierUUID": "6ba0feac-d7cc-11e8-824f-0242ac160002", + * "statementCode": "5.NF.B.7", + * "description": "Apply and extend previous understandings of division to divide unit fractions" + * }, + * { + * "caseIdentifierUUID": "6ba0e123-d7cc-11e8-824f-0242ac160002", + * "statementCode": "5.NF.B.6", + * "description": "Solve real world problems involving multiplication of fractions" + * }, + * { + * "caseIdentifierUUID": "6ba0c456-d7cc-11e8-824f-0242ac160002", + * "statementCode": "5.NF.B.5", + * "description": "Interpret multiplication as scaling (resizing)" + * }, + * { + * "caseIdentifierUUID": "6ba0a789-d7cc-11e8-824f-0242ac160002", + * "statementCode": "5.NF.B.4", + * "description": "Apply and extend previous understandings of multiplication to multiply a fraction by a whole number" + * } + * ], + * "pagination": { + * "limit": 100, + * "nextCursor": "eyJpZGVudGlmaWVyIjoiNWI3ZjE4ZmUtYmQxNC01NDI3LThkMzUtNWQzNGMzYjhmMTBmIn0=", + * "hasMore": true + * } + * } + */ + "application/json": components["schemas"]["PaginatedResponse"] & { + data?: components["schemas"]["StandardsFrameworkItemSummary"][]; + }; + }; + }; + /** @description Bad request - Invalid CASE UUID or pagination parameters */ + 400: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "ValidationError", + * "message": "Invalid CASE UUID format. Must be a valid UUID (e.g., \"6bd8552e-6f8f-4538-bf33-d016ac080178\").", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + /** @description Academic standard not found */ + 404: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "NotFoundError", + * "message": "Academic standard with CASE UUID \"6bd8552e-6f8f-4538-bf33-d016ac080178\" not found. Verify the UUID is correct.", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + /** @description Internal server error */ + 500: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "InternalServerError", + * "message": "An unexpected error occurred while retrieving related standards", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + }; + }; + listLearningComponentsByAcademicStandard: { + parameters: { + query?: { + /** @description Maximum number of results to return. Default is 100. Maximum allowed is 1000. */ + limit?: components["parameters"]["LimitParam"]; + /** @description Cursor for pagination. Obtain this value from the 'nextCursor' field in the previous response. Omit for the first page. */ + cursor?: components["parameters"]["CursorParam"]; + }; + header?: never; + path: { + /** @description The CASE UUID identifier from the CASE Network published by 1EdTech */ + caseIdentifierUUID: components["parameters"]["CaseIdentifierUUIDPath"]; + }; + cookie?: never; + }; + requestBody?: never; + responses: { + /** @description Successfully retrieved list of learning components supporting this standard */ + 200: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "data": [ + * { + * "identifier": "926bf4b0-e045-536b-ac02-2089d77cbf6c", + * "description": "Find the least common multiple of two whole numbers less than or equal to 12", + * "author": "Achievement Network", + * "provider": "Learning Commons", + * "license": "https://creativecommons.org/licenses/by/4.0/", + * "attributionStatement": "Knowledge Graph is provided by Learning Commons under the CC BY-4.0 license. Learning Commons received learning components under CC BY-4.0 from Achievement Network." + * }, + * { + * "identifier": "9bf54462-5fd0-59bf-8360-cd503e45b884", + * "description": "Find the greatest common factor of two whole numbers less than or equal to 100", + * "author": "Achievement Network", + * "provider": "Learning Commons", + * "license": "https://creativecommons.org/licenses/by/4.0/", + * "attributionStatement": "Knowledge Graph is provided by Learning Commons under the CC BY-4.0 license. Learning Commons received learning components under CC BY-4.0 from Achievement Network." + * }, + * { + * "identifier": "c587f727-0135-571c-8c60-7ad46e0a28c5", + * "description": "Use the distributive property to express a sum of two whole numbers 1-100 with a common factor as a multiple of a sum of two whole numbers with no common factor", + * "author": "Achievement Network", + * "provider": "Learning Commons", + * "license": "https://creativecommons.org/licenses/by/4.0/", + * "attributionStatement": "Knowledge Graph is provided by Learning Commons under the CC BY-4.0 license. Learning Commons received learning components under CC BY-4.0 from Achievement Network." + * } + * ], + * "pagination": { + * "limit": 100, + * "nextCursor": null, + * "hasMore": false + * } + * } + */ + "application/json": components["schemas"]["PaginatedResponse"] & { + data?: components["schemas"]["LearningComponentSummary"][]; + }; + }; + }; + /** @description Bad request - Invalid CASE UUID or pagination parameters */ + 400: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "ValidationError", + * "message": "Invalid CASE UUID format. Must be a valid UUID (e.g., \"6bd8552e-6f8f-4538-bf33-d016ac080178\").", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + /** @description Academic standard not found */ + 404: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "NotFoundError", + * "message": "Academic standard with CASE UUID \"6bd8552e-6f8f-4538-bf33-d016ac080178\" not found. Verify the UUID is correct.", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + /** @description Internal server error */ + 500: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "InternalServerError", + * "message": "An unexpected error occurred while retrieving learning components", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + }; + }; + listCrosswalkedStandards: { + parameters: { + query?: { + /** @description Filter by jurisdiction (state/territory) */ + jurisdiction?: components["parameters"]["JurisdictionParam"]; + /** @description Filter crosswalks by minimum Jaccard similarity score. Only return standards with a Jaccard score greater than or equal to this value. Use this to focus on stronger alignments. */ + minJaccardScore?: number; + /** @description Maximum number of results to return. Default is 100. Maximum allowed is 1000. */ + limit?: components["parameters"]["LimitParam"]; + /** @description Cursor for pagination. Obtain this value from the 'nextCursor' field in the previous response. Omit for the first page. */ + cursor?: components["parameters"]["CursorParam"]; + }; + header?: never; + path: { + /** @description The CASE UUID identifier from the CASE Network published by 1EdTech */ + caseIdentifierUUID: components["parameters"]["CaseIdentifierUUIDPath"]; + }; + cookie?: never; + }; + requestBody?: never; + responses: { + /** @description Successfully retrieved list of crosswalked standards. If a state standard is provided, returns matching CCSS standards. If a CCSS standard is provided, returns matching state standards (optionally filtered by jurisdiction). */ + 200: { + headers: { + [name: string]: unknown; + }; + content: { + "application/json": components["schemas"]["PaginatedResponse"] & { + data?: components["schemas"]["StandardCrosswalk"][]; + }; + }; + }; + /** @description Bad request - Invalid CASE UUID or filter parameters */ + 400: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "ValidationError", + * "message": "Invalid minJaccardScore. Must be a number between 0.0 and 1.0.", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + /** @description Academic standard not found */ + 404: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "NotFoundError", + * "message": "Academic standard with CASE UUID \"6bd8552e-6f8f-4538-bf33-d016ac080178\" not found. Verify the UUID is correct.", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + /** @description Unprocessable Entity - Invalid parameter values (e.g., enum value not in allowed list) */ + 422: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "ValidationError", + * "message": "Input should be 'Alabama', 'Alaska', ..., or 'Multi-State'", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + /** @description Internal server error */ + 500: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "InternalServerError", + * "message": "An unexpected error occurred while retrieving crosswalked standards", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + }; + }; + getLearningComponentByIdentifier: { + parameters: { + query?: never; + header?: never; + path: { + /** @description The unique identifier for the learning component in the Knowledge Graph system */ + identifier: components["parameters"]["LearningComponentIdentifierPath"]; + }; + cookie?: never; + }; + requestBody?: never; + responses: { + /** @description Successfully retrieved the learning component */ + 200: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "identifier": "926bf4b0-e045-536b-ac02-2089d77cbf6c", + * "description": "Find the least common multiple of two whole numbers less than or equal to 12", + * "academicSubject": "Mathematics", + * "inLanguage": "en-US", + * "dateCreated": "2025-04-01", + * "dateModified": "2025-04-01", + * "author": "Achievement Network", + * "provider": "Learning Commons", + * "license": "https://creativecommons.org/licenses/by/4.0/", + * "attributionStatement": "Knowledge Graph is provided by Learning Commons under the CC BY-4.0 license. Learning Commons received learning components under CC BY-4.0 from Achievement Network." + * } + */ + "application/json": components["schemas"]["LearningComponent"]; + }; + }; + /** @description Bad request - Invalid identifier format */ + 400: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "ValidationError", + * "message": "Invalid identifier format. Must be a valid UUID string (e.g., \"0b4a3aca-ad10-5ad3-b890-e30d7042bd5b\").", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + /** @description Learning component not found */ + 404: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "NotFoundError", + * "message": "Learning component with identifier \"0b4a3aca-ad10-5ad3-b890-e30d7042bd5b\" not found. Verify the identifier or use GET /learning-components to browse available learning components.", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + /** @description Internal server error */ + 500: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "InternalServerError", + * "message": "An unexpected error occurred while retrieving the learning component", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + }; + }; + getStandardLessons: { + parameters: { + query?: { + /** @description Maximum number of results to return. Default is 100. Maximum allowed is 1000. */ + limit?: components["parameters"]["LimitParam"]; + /** @description Cursor for pagination. Obtain this value from the 'nextCursor' field in the previous response. Omit for the first page. */ + cursor?: components["parameters"]["CursorParam"]; + }; + header?: never; + path: { + /** @description The CASE UUID identifier from the CASE Network published by 1EdTech */ + caseIdentifierUUID: components["parameters"]["CaseIdentifierUUIDPath"]; + }; + cookie?: never; + }; + requestBody?: never; + responses: { + /** @description Successfully retrieved list of lesson summaries */ + 200: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "data": [ + * { + * "identifier": "im:2ebf72dc-53f8-557b-b804-fca624be807a", + * "name": "Making a Model for Data", + * "ordinalName": "Lesson 11", + * "author": "Illustrative Mathematics", + * "provider": "Learning Commons", + * "license": "https://creativecommons.org/licenses/by-nc/4.0/", + * "attributionStatement": "Knowledge Graph is provided by Learning Commons under the CC BY-4.0 license. Learning Commons received the scope and sequence of the Illustrative Mathematics 360 curriculum under CC BY-4.0 from Illustrative Mathematics." + * }, + * { + * "identifier": "im:b29e2804-6f89-5cd2-90e5-aa0b15c01343", + * "name": "Predicting Populations", + * "ordinalName": "Lesson 17", + * "author": "Illustrative Mathematics", + * "provider": "Learning Commons", + * "license": "https://creativecommons.org/licenses/by-nc/4.0/", + * "attributionStatement": "Knowledge Graph is provided by Learning Commons under the CC BY-4.0 license. Learning Commons received the scope and sequence of the Illustrative Mathematics 360 curriculum under CC BY-4.0 from Illustrative Mathematics." + * } + * ], + * "pagination": { + * "limit": 100, + * "nextCursor": null, + * "hasMore": false + * } + * } + */ + "application/json": components["schemas"]["PaginatedResponse"] & { + data?: components["schemas"]["LessonSummary"][]; + }; + }; + }; + /** @description Academic standard not found */ + 404: { + headers: { + [name: string]: unknown; + }; + content: { + "application/json": components["schemas"]["Error"]; + }; + }; + /** @description Internal server error */ + 500: { + headers: { + [name: string]: unknown; + }; + content: { + "application/json": components["schemas"]["Error"]; + }; + }; + }; + }; + getStandardActivities: { + parameters: { + query?: { + /** @description Maximum number of results to return. Default is 100. Maximum allowed is 1000. */ + limit?: components["parameters"]["LimitParam"]; + /** @description Cursor for pagination. Obtain this value from the 'nextCursor' field in the previous response. Omit for the first page. */ + cursor?: components["parameters"]["CursorParam"]; + }; + header?: never; + path: { + /** @description The CASE UUID identifier from the CASE Network published by 1EdTech */ + caseIdentifierUUID: components["parameters"]["CaseIdentifierUUIDPath"]; + }; + cookie?: never; + }; + requestBody?: never; + responses: { + /** @description Successfully retrieved list of activity summaries */ + 200: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "data": [ + * { + * "identifier": "im:98928b4e-0183-5e0e-955d-230653db7332", + * "name": "Water in a Tank", + * "ordinalName": "Activity 1", + * "author": "Illustrative Mathematics", + * "provider": "Learning Commons", + * "license": "https://creativecommons.org/licenses/by-nc/4.0/", + * "attributionStatement": "Knowledge Graph is provided by Learning Commons under the CC BY-4.0 license. Learning Commons received the scope and sequence of the Illustrative Mathematics 360 curriculum under CC BY-4.0 from Illustrative Mathematics." + * }, + * { + * "identifier": "im:a859c7f9-ba5c-5b2e-82e9-1b948e4ee01c", + * "name": "Swing Time", + * "ordinalName": "Activity 2", + * "author": "Illustrative Mathematics", + * "provider": "Learning Commons", + * "license": "https://creativecommons.org/licenses/by-nc/4.0/", + * "attributionStatement": "nKnowledge Graph is provided by Learning Commons under the CC BY-4.0 license. Learning Commons received the scope and sequence of the Illustrative Mathematics 360 curriculum under CC BY-4.0 from Illustrative Mathematics.l" + * } + * ], + * "pagination": { + * "limit": 100, + * "nextCursor": null, + * "hasMore": false + * } + * } + */ + "application/json": components["schemas"]["PaginatedResponse"] & { + data?: components["schemas"]["ActivitySummary"][]; + }; + }; + }; + /** @description Academic standard not found */ + 404: { + headers: { + [name: string]: unknown; + }; + content: { + "application/json": components["schemas"]["Error"]; + }; + }; + /** @description Internal server error */ + 500: { + headers: { + [name: string]: unknown; + }; + content: { + "application/json": components["schemas"]["Error"]; + }; + }; + }; + }; + getStandardAssessments: { + parameters: { + query?: { + /** @description Maximum number of results to return. Default is 100. Maximum allowed is 1000. */ + limit?: components["parameters"]["LimitParam"]; + /** @description Cursor for pagination. Obtain this value from the 'nextCursor' field in the previous response. Omit for the first page. */ + cursor?: components["parameters"]["CursorParam"]; + }; + header?: never; + path: { + /** @description The CASE UUID identifier from the CASE Network published by 1EdTech */ + caseIdentifierUUID: components["parameters"]["CaseIdentifierUUIDPath"]; + }; + cookie?: never; + }; + requestBody?: never; + responses: { + /** @description Successfully retrieved list of assessment summaries */ + 200: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "data": [ + * { + * "identifier": "im:5f1b43a3-a087-5f15-8e0e-b5dd3d2d3d23", + * "name": "End-of-Unit Assessment", + * "author": "Illustrative Mathematics", + * "provider": "Learning Commons", + * "license": "https://creativecommons.org/licenses/by-nc/4.0/", + * "attributionStatement": "Knowledge Graph is provided by Learning Commons under the CC BY-4.0 license. Learning Commons received the scope and sequence of the Illustrative Mathematics 360 curriculum under CC BY-4.0 from Illustrative Mathematics." + * }, + * { + * "identifier": "im:b98c7782-3cb1-5198-8ebe-aab294d9227b", + * "name": "End-of-Unit Assessment", + * "author": "Illustrative Mathematics", + * "provider": "Learning Commons", + * "license": "https://creativecommons.org/licenses/by-nc/4.0/", + * "attributionStatement": "Knowledge Graph is provided by Learning Commons under the CC BY-4.0 license. Learning Commons received the scope and sequence of the Illustrative Mathematics 360 curriculum under CC BY-4.0 from Illustrative Mathematics." + * } + * ], + * "pagination": { + * "limit": 100, + * "nextCursor": null, + * "hasMore": false + * } + * } + */ + "application/json": components["schemas"]["PaginatedResponse"] & { + data?: components["schemas"]["AssessmentSummary"][]; + }; + }; + }; + /** @description Academic standard not found */ + 404: { + headers: { + [name: string]: unknown; + }; + content: { + "application/json": components["schemas"]["Error"]; + }; + }; + /** @description Internal server error */ + 500: { + headers: { + [name: string]: unknown; + }; + content: { + "application/json": components["schemas"]["Error"]; + }; + }; + }; + }; + listLearningComponents: { + parameters: { + query: { + /** @description The academic subject area to retrieve learning components for. Mathematics and English Language Arts have the most comprehensive coverage, with additional subjects being developed. */ + academicSubject: components["schemas"]["AcademicSubjectENUM"]; + /** @description Maximum number of results to return. Default is 100. Maximum allowed is 1000. */ + limit?: components["parameters"]["LimitParam"]; + /** @description Cursor for pagination. Obtain this value from the 'nextCursor' field in the previous response. Omit for the first page. */ + cursor?: components["parameters"]["CursorParam"]; + }; + header?: never; + path?: never; + cookie?: never; + }; + requestBody?: never; + responses: { + /** @description Successfully retrieved list of learning components */ + 200: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "data": [ + * { + * "identifier": "0013fbee-3e76-500f-9978-42aa1a65f105", + * "description": "Use conversions to solve multi-step real-world problems", + * "academicSubject": "Mathematics", + * "inLanguage": "en-US", + * "dateCreated": "2025-04-01", + * "dateModified": "2025-04-01", + * "author": "Achievement Network", + * "provider": "Learning Commons", + * "license": "https://creativecommons.org/licenses/by/4.0/", + * "attributionStatement": "Knowledge Graph is provided by Learning Commons under the CC BY-4.0 license. Learning Commons received learning components under CC BY-4.0 from Achievement Network." + * }, + * { + * "identifier": "457afeb6-6d17-5cff-8679-7b919d744bdd", + * "description": "Print uppercase \"A\"", + * "academicSubject": "English Language Arts", + * "inLanguage": "en-US", + * "dateCreated": "2025-04-01", + * "dateModified": "2025-04-01", + * "author": "Achievement Network", + * "provider": "Learning Commons", + * "license": "https://creativecommons.org/licenses/by/4.0/", + * "attributionStatement": "Knowledge Graph is provided by Learning Commons under the CC BY-4.0 license. Learning Commons received learning components under CC BY-4.0 from Achievement Network." + * } + * ], + * "pagination": { + * "limit": 100, + * "nextCursor": "eyJpZGVudGlmaWVyIjogIjA5OWNlY2NiLTQ3MzItNTZjMC1iZGIxLTYxZjljNmZjYmQ2NSJ9", + * "hasMore": true + * } + * } + */ + "application/json": components["schemas"]["PaginatedResponse"] & { + data?: components["schemas"]["LearningComponent"][]; + }; + }; + }; + /** @description Bad request - Missing required parameter or invalid values */ + 400: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "ValidationError", + * "message": "Missing required parameter: academicSubject. Example: ?academicSubject=Mathematics or ?academicSubject=English Language Arts", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + /** @description Unprocessable Entity - Invalid parameter values (e.g., enum value not in allowed list) */ + 422: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "ValidationError", + * "message": "Input should be 'English Language Arts', 'Mathematics', 'Science', 'Social Studies', or 'Other'", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + /** @description Internal server error */ + 500: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "InternalServerError", + * "message": "An unexpected error occurred while retrieving learning components", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + }; + }; + searchLearningComponents: { + parameters: { + query: { + /** @description Free-text query for semantic search against learning component descriptions. Results are ranked by relevance score. */ + query: string; + /** @description Filter by academic subject area */ + academicSubject?: components["parameters"]["AcademicSubjectParam"]; + /** @description Maximum number of results to return. Default is 5. Maximum allowed is 50. */ + limit?: number; + }; + header?: never; + path?: never; + cookie?: never; + }; + requestBody?: never; + responses: { + /** @description Successfully retrieved search results */ + 200: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example [ + * { + * "identifier": "0013fbee-3e76-500f-9978-42aa1a65f105", + * "description": "Use conversions to solve multi-step real-world problems", + * "author": "Achievement Network", + * "provider": "Learning Commons", + * "license": "https://creativecommons.org/licenses/by/4.0/", + * "attributionStatement": "Knowledge Graph is provided by Learning Commons under the CC BY-4.0 license. Learning Commons received learning components under CC BY-4.0 from Achievement Network.", + * "score": 0.94 + * }, + * { + * "identifier": "0046446a-0a9b-5ace-92a3-23d4bb158c68", + * "description": "Determine the lateral surface area of three-dimensional cylinders in real-world problems", + * "author": "Achievement Network", + * "provider": "Learning Commons", + * "license": "https://creativecommons.org/licenses/by/4.0/", + * "attributionStatement": "Knowledge Graph is provided by Learning Commons under the CC BY-4.0 license. Learning Commons received learning components under CC BY-4.0 from Achievement Network.", + * "score": 0.81 + * } + * ] + */ + "application/json": components["schemas"]["LearningComponentSearchResult"][]; + }; + }; + /** @description Bad request - Missing required query parameter */ + 400: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "ValidationError", + * "message": "Missing required parameter: query. Example: ?query=solve+multi-step+real-world+problems", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + /** @description Unprocessable Entity - Invalid parameter values (e.g., enum value not in allowed list) */ + 422: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "ValidationError", + * "message": "Input should be 'English Language Arts', 'Mathematics', 'Science', 'Social Studies', or 'Other'", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + /** @description Internal server error */ + 500: { + headers: { + [name: string]: unknown; + }; + content: { + /** + * @example { + * "error": "InternalServerError", + * "message": "An unexpected error occurred while searching for learning components", + * "requestId": "req_12345" + * } + */ + "application/json": components["schemas"]["Error"]; + }; + }; + }; + }; +} diff --git a/sdks/typescript/src/knowledge-graph/types.ts b/sdks/typescript/src/knowledge-graph/types.ts new file mode 100644 index 0000000..0b5b9a2 --- /dev/null +++ b/sdks/typescript/src/knowledge-graph/types.ts @@ -0,0 +1,34 @@ +// Generated spec types are in kg-api.d.ts — see npm run generate:kg-types. +// We use string for normalizedStatementType and gradeLevel rather than the +// spec's strict enum types so the interfaces remain compatible if the API +// returns values outside the current spec. + +/** + * An academic standard from the LC Knowledge Graph (spec: StandardsFrameworkItem). + * Subset of fields used for alignment evaluation. + */ +export interface AcademicStandard { + caseIdentifierUUID: string; + statementCode: string | null | undefined; + description: string | null | undefined; + statementType: string | null | undefined; + normalizedStatementType: string | null | undefined; + gradeLevel: string[]; +} + +/** + * A learning component from the LC Knowledge Graph. + * description is guaranteed non-null — nulls are filtered at fetch time. + * identifier is the KG system UUID echoed back by the model to verify + * each evaluation maps to the correct learning component. + */ +export interface LearningComponent { + identifier: string; + description: string; +} + +/** Resolved info from a standard code lookup. */ +export interface StandardInfo { + uuid: string; + description?: string; +} diff --git a/sdks/typescript/tests/unit/knowledge-graph/client.test.ts b/sdks/typescript/tests/unit/knowledge-graph/client.test.ts new file mode 100644 index 0000000..68a4341 --- /dev/null +++ b/sdks/typescript/tests/unit/knowledge-graph/client.test.ts @@ -0,0 +1,167 @@ +import { describe, it, expect, vi, beforeEach } from 'vitest'; +import { KnowledgeGraphClient } from '../../../src/knowledge-graph/client.js'; +import { KnowledgeGraphError, AuthenticationError, RateLimitError, NetworkError } from '../../../src/errors.js'; + +function mockFetch(status: number, body: unknown) { + const text = typeof body === 'string' ? body : JSON.stringify(body); + vi.stubGlobal('fetch', vi.fn().mockResolvedValue({ + ok: status >= 200 && status < 300, + status, + json: () => Promise.resolve(body), + text: () => Promise.resolve(text), + })); +} + +beforeEach(() => { vi.unstubAllGlobals(); }); + +const API_KEY = 'test-key'; + +describe('KnowledgeGraphClient - getStandardInfo', () => { + it('returns uuid and description for an exact match', async () => { + mockFetch(200, [{ caseIdentifierUUID: 'abc-123', description: 'Recognize area as additive' }]); + const info = await new KnowledgeGraphClient(API_KEY).getStandardInfo('3.MD.C.7.d'); + expect(info.uuid).toBe('abc-123'); + expect(info.description).toBe('Recognize area as additive'); + }); + + it('returns uuid with no description when absent from response', async () => { + mockFetch(200, [{ caseIdentifierUUID: 'abc-123' }]); + const info = await new KnowledgeGraphClient(API_KEY).getStandardInfo('3.MD.C.7.d'); + expect(info.uuid).toBe('abc-123'); + expect(info.description).toBeUndefined(); + }); + + it('throws KnowledgeGraphError when no standard found', async () => { + mockFetch(200, []); + await expect(new KnowledgeGraphClient(API_KEY).getStandardInfo('X.YZ.A.1')).rejects.toThrow(KnowledgeGraphError); + }); + + it('throws KnowledgeGraphError when ambiguous (>1 results)', async () => { + mockFetch(200, [{ caseIdentifierUUID: 'a' }, { caseIdentifierUUID: 'b' }]); + await expect(new KnowledgeGraphClient(API_KEY).getStandardInfo('3.MD')).rejects.toThrow('Ambiguous'); + }); + + it('throws AuthenticationError on 401', async () => { + mockFetch(401, 'Unauthorized'); + await expect(new KnowledgeGraphClient(API_KEY).getStandardInfo('3.MD.C.7.d')).rejects.toThrow(AuthenticationError); + }); + + it('throws RateLimitError on 429', async () => { + mockFetch(429, 'Too Many Requests'); + await expect(new KnowledgeGraphClient(API_KEY).getStandardInfo('3.MD.C.7.d')).rejects.toThrow(RateLimitError); + }); + + it('throws KnowledgeGraphError with statusCode on 500', async () => { + mockFetch(500, 'Server Error'); + const err = await new KnowledgeGraphClient(API_KEY).getStandardInfo('3.MD.C.7.d').catch((e) => e); + expect(err).toBeInstanceOf(KnowledgeGraphError); + expect(err.statusCode).toBe(500); + }); + + it('throws NetworkError when fetch throws', async () => { + vi.stubGlobal('fetch', vi.fn().mockRejectedValue(new Error('ECONNREFUSED'))); + await expect(new KnowledgeGraphClient(API_KEY).getStandardInfo('3.MD.C.7.d')).rejects.toThrow(NetworkError); + }); + + it('throws NetworkError with timeout message when AbortSignal fires', async () => { + vi.stubGlobal('fetch', vi.fn().mockRejectedValue(new DOMException('aborted', 'TimeoutError'))); + const err = await new KnowledgeGraphClient(API_KEY).getStandardInfo('3.MD.C.7.d').catch((e) => e); + expect(err).toBeInstanceOf(NetworkError); + expect(err.message).toContain('timed out'); + }); + + it('sends x-api-key header', async () => { + const fetchMock = vi.fn().mockResolvedValue({ ok: true, status: 200, json: () => Promise.resolve([{ caseIdentifierUUID: 'u1' }]), text: () => Promise.resolve('') }); + vi.stubGlobal('fetch', fetchMock); + await new KnowledgeGraphClient('my-secret-key').getStandardInfo('3.MD.C.7.d'); + expect(fetchMock.mock.calls[0][1]).toMatchObject({ headers: { 'x-api-key': 'my-secret-key' } }); + }); + + it('evicts cache on rejection so the next call retries', async () => { + const fetchMock = vi.fn() + .mockRejectedValueOnce(new Error('transient')) + .mockResolvedValue({ ok: true, status: 200, json: () => Promise.resolve([{ caseIdentifierUUID: 'recovered' }]), text: () => Promise.resolve('') }); + vi.stubGlobal('fetch', fetchMock); + const client = new KnowledgeGraphClient(API_KEY); + await expect(client.getStandardInfo('3.MD.C.7.d')).rejects.toThrow(); + const info = await client.getStandardInfo('3.MD.C.7.d'); + expect(info.uuid).toBe('recovered'); + expect(fetchMock).toHaveBeenCalledTimes(2); + }); +}); + +describe('KnowledgeGraphClient - getLearningComponents', () => { + it('returns learning components', async () => { + mockFetch(200, { data: [{ description: 'Recognize area as additive' }, { description: 'Find areas' }], pagination: { hasMore: false, nextCursor: null } }); + const lcs = await new KnowledgeGraphClient(API_KEY).getLearningComponents('uuid-abc'); + expect(lcs).toHaveLength(2); + expect(lcs[0].description).toBe('Recognize area as additive'); + }); + + it('filters out null descriptions', async () => { + mockFetch(200, { data: [{ description: 'Valid' }, { description: null }, { description: 'Also valid' }], pagination: { hasMore: false, nextCursor: null } }); + const lcs = await new KnowledgeGraphClient(API_KEY).getLearningComponents('uuid-abc'); + expect(lcs).toHaveLength(2); + }); + + it('follows cursor pagination across pages', async () => { + let call = 0; + vi.stubGlobal('fetch', vi.fn().mockImplementation(() => { + call++; + return Promise.resolve({ ok: true, status: 200, json: () => Promise.resolve({ data: [{ description: `LC ${call}` }], pagination: { hasMore: call === 1, nextCursor: call === 1 ? 'page-2' : null } }), text: () => Promise.resolve('') }); + })); + const lcs = await new KnowledgeGraphClient(API_KEY).getLearningComponents('uuid-abc'); + expect(lcs).toHaveLength(2); + expect(call).toBe(2); + }); + + it('throws KnowledgeGraphError if hasMore=true but nextCursor is null', async () => { + mockFetch(200, { data: [], pagination: { hasMore: true, nextCursor: null } }); + await expect(new KnowledgeGraphClient(API_KEY).getLearningComponents('uuid')).rejects.toThrow(KnowledgeGraphError); + }); + + it('evicts LC cache on rejection so the next call retries', async () => { + const fetchMock = vi.fn() + .mockRejectedValueOnce(new Error('transient 503')) + .mockResolvedValue({ ok: true, status: 200, json: () => Promise.resolve({ data: [{ description: 'Recovered LC' }], pagination: { hasMore: false, nextCursor: null } }), text: () => Promise.resolve('') }); + vi.stubGlobal('fetch', fetchMock); + const client = new KnowledgeGraphClient(API_KEY); + await expect(client.getLearningComponents('uuid-abc')).rejects.toThrow(); + const lcs = await client.getLearningComponents('uuid-abc'); + expect(lcs[0].description).toBe('Recovered LC'); + expect(fetchMock).toHaveBeenCalledTimes(2); + }); +}); + +describe('KnowledgeGraphClient - getStandardsByGrade', () => { + it('returns standards filtered to normalizedStatementType=Standard via URL', async () => { + const fetchMock = vi.fn().mockResolvedValue({ ok: true, status: 200, json: () => Promise.resolve({ data: [ + { caseIdentifierUUID: 'u1', statementCode: '3.MD.C.7.d', normalizedStatementType: 'Standard', gradeLevel: ['3'] }, + ] }), text: () => Promise.resolve('') }); + vi.stubGlobal('fetch', fetchMock); + const results = await new KnowledgeGraphClient(API_KEY).getStandardsByGrade('3'); + expect(fetchMock.mock.calls[0][0]).toContain('normalizedStatementType=Standard'); + expect(results).toHaveLength(1); + expect(results[0].statementCode).toBe('3.MD.C.7.d'); + }); + + it('throws KnowledgeGraphError if hasMore=true (pagination not implemented for standards)', async () => { + mockFetch(200, { data: [], pagination: { hasMore: true, nextCursor: 'page-2' } }); + await expect(new KnowledgeGraphClient(API_KEY).getStandardsByGrade('3')) + .rejects.toThrow(KnowledgeGraphError); + }); +}); + +describe('KnowledgeGraphClient - getLearningComponentsByCode', () => { + it('chains standard info lookup then LC fetch', async () => { + const fetchMock = vi.fn() + .mockResolvedValueOnce({ ok: true, status: 200, json: () => Promise.resolve([{ caseIdentifierUUID: 'test-uuid', description: 'Area additive' }]), text: () => Promise.resolve('') }) + .mockResolvedValueOnce({ ok: true, status: 200, json: () => Promise.resolve({ data: [{ description: 'LC one' }], pagination: { hasMore: false, nextCursor: null } }), text: () => Promise.resolve('') }); + vi.stubGlobal('fetch', fetchMock); + const result = await new KnowledgeGraphClient(API_KEY).getLearningComponentsByCode('3.MD.C.7.d'); + expect(result.uuid).toBe('test-uuid'); + expect(result.description).toBe('Area additive'); + expect(result.components[0].description).toBe('LC one'); + expect(fetchMock).toHaveBeenCalledTimes(2); + }); +});