diff --git a/.speakeasy/gen.lock b/.speakeasy/gen.lock
index 52c8e151a..0bc964bac 100644
--- a/.speakeasy/gen.lock
+++ b/.speakeasy/gen.lock
@@ -1,19 +1,19 @@
lockVersion: ""
id: ""
management:
- docChecksum: 02b4c06ec2d52324408d051bd1168781
+ docChecksum: bbf4b94181ce514922a85b674fe8a9d6
docVersion: 1.0.0
speakeasyVersion: 1.787.0
generationVersion: 2.914.0
- releaseVersion: 1.3.8
- configChecksum: e7d73e099a3f00a2b6a28aba29165bf3
+ releaseVersion: 1.3.9
+ configChecksum: 750331a981585266cb185054afe594ed
repoURL: https://github.com/OpenRouterTeam/typescript-sdk.git
installationURL: https://github.com/OpenRouterTeam/typescript-sdk
published: true
persistentEdits:
- generation_id: 2f195164-ed59-4a37-99e5-bf853e71c5c7
- pristine_commit_hash: be866010dc5972ed501e239d2b6e6ac7e5b527b0
- pristine_tree_hash: d8367ee92538fa9973b18117f9d3673bdd02af78
+ generation_id: b02f39b4-24a8-4a34-a5c7-e90576f817ae
+ pristine_commit_hash: c29d4ccc16b66bb21a1cc66bf9b597dcff7899c1
+ pristine_tree_hash: aada573d0db51250b52d4657abfd6d6c785a9f2b
features:
typescript:
acceptHeaders: 2.81.2
@@ -3851,8 +3851,8 @@ trackedFiles:
pristine_git_object: b3d9a23cd77aeade0505ea3c6ac588fb70e92bfa
docs/models/errors/internchaterrorresponse.mdx:
id: 4a194a124c11
- last_write_checksum: sha1:e8f89669bfc768f5b8f63aec74b980e64a95e68b
- pristine_git_object: 74ede0c21da185b375e55557f58383fbd7b2ec20
+ last_write_checksum: sha1:8f5b8e026ad1a0a22e01685b4e9ca28d7127b0eb
+ pristine_git_object: 97e17714bb6d94ef7e2aa4949fa4c801fa89d88f
docs/models/errors/internlifecycleerror.mdx:
id: "187091522104"
last_write_checksum: sha1:73dedffc08184418b70832c52e9d1e4ab6c7d9eb
@@ -5462,8 +5462,8 @@ trackedFiles:
pristine_git_object: 499465b7f8a297d0212ee2f20cbad1b6bde01fa6
docs/models/internchatcompletionchunk.mdx:
id: 0068460f12e3
- last_write_checksum: sha1:8a1767dcff6411a0a8db5b270fdd0663b0acfac1
- pristine_git_object: d558a4b084233a83ffabd898005f6ac50d95d992
+ last_write_checksum: sha1:58bc0b9071d5140d15fee66f24c402b88edfa6df
+ pristine_git_object: 2ba88694a8b782188901980d65b04b81b64b8204
docs/models/internchatcompletionchunkobject.mdx:
id: e281295610be
last_write_checksum: sha1:d6e73aa1e66a16cf0cfd5a43178a078f5e8efdf4
@@ -5494,12 +5494,12 @@ trackedFiles:
pristine_git_object: 45faaeb03d51dbee60d4a14347f1756b7b2441ed
docs/models/internchaterror.mdx:
id: a64f4c0ec047
- last_write_checksum: sha1:dbbd782986aa54309067f9046c8b29ac5cd1f44b
- pristine_git_object: 7ea3b82db72ed3c5dabed25ab1d97a08dca3272d
+ last_write_checksum: sha1:fe3741903db6bf0392de5c48ccc136b91e69ec33
+ pristine_git_object: 7707fe274aa18c677b5404123bada03a893be908
docs/models/internchaterrormetadata.mdx:
id: 768e549d2f1f
- last_write_checksum: sha1:d29cb5d9f2c05ef890f6bb699e89837450ac2052
- pristine_git_object: b15902672d57a4a45025a69b5fa855f598098a86
+ last_write_checksum: sha1:7340078098ea4d12d3216dc97da80df3d2d1688b
+ pristine_git_object: 30f18d2dd7094a78a42b8e259a2654e8f95850d8
docs/models/internchaterrormetadatareason.mdx:
id: a277cb62fe10
last_write_checksum: sha1:2bb9ded604a1424dd89f7d6d4816441f4d860cb2
@@ -5518,8 +5518,8 @@ trackedFiles:
pristine_git_object: fccc5f9c0dc57e2c64325fa32bd0009dbee7aa8b
docs/models/internchatstreamerror.mdx:
id: 6b0f5db985c8
- last_write_checksum: sha1:56a8f96c7fdbcbcee0204b794b057927a4acc9c2
- pristine_git_object: cac1699bbe442fe0d93c3dccd4b10a219e6b0f24
+ last_write_checksum: sha1:9e8c3120134129b30f9eb92bd478cfc389ecd562
+ pristine_git_object: c754a9cebcb83eeebda5fff0916ffa20443a5d47
docs/models/internchatstreamingresponse.mdx:
id: 1618863d6728
last_write_checksum: sha1:02fe441cf9944d53e25de4f6be6bb485becef166
@@ -5566,8 +5566,12 @@ trackedFiles:
pristine_git_object: 2b3c42b383091a4fd9423c0f07b47e9de6168549
docs/models/internlifecycleerrorerror.mdx:
id: 03984489ae4f
- last_write_checksum: sha1:30913dbd4b07442728fe6a69f5fdb2669cba980d
- pristine_git_object: 9ae4de8c73c4bcea74bc0ff0f68791fb127dcb0d
+ last_write_checksum: sha1:4500621f32eb63bb62efc51ecba5c7792239028f
+ pristine_git_object: 41d89dac424d90b926db267207c180834eee10ac
+ docs/models/internlifecycleerrormetadata.mdx:
+ id: cb4a26d2d14a
+ last_write_checksum: sha1:9e69c77974ee853684e7212456fe77d0f13002e4
+ pristine_git_object: cedd755fbc554d8b5584ce8fee175edbe2f1207f
docs/models/internlistresponse.mdx:
id: 5c9b286a062d
last_write_checksum: sha1:229ca1d55f775c434ac49f957cd8d91f11c36145
@@ -7577,14 +7581,18 @@ trackedFiles:
id: 4f8dc8d59d98
last_write_checksum: sha1:c93c511bf8f77f8fb4d9632364851ac062344501
pristine_git_object: 239255eaca58f2b126737a264119be9b00895ee6
+ docs/models/operations/createinternchatcompletionresponse.mdx:
+ id: 658bd77b0441
+ last_write_checksum: sha1:156b3d14efab69cb3b6abdcffc6a1c777630a34c
+ pristine_git_object: 86f2ab6c3925bd0698cc9f95fcedbd03deeb6963
docs/models/operations/createinternglobals.mdx:
id: c8ffa9eab0e8
last_write_checksum: sha1:ea4175474bd3016b8279fdca55aecc1539e9cb46
pristine_git_object: d5daed778fa4d4c6bb51fe557fbaf6b96ed8e849
docs/models/operations/createinternrequest.mdx:
id: d2745e216be4
- last_write_checksum: sha1:8449cb5b6cd72703b4cc534ca5244f22af254ba0
- pristine_git_object: fab871c901f7fe84a942f147b5b01ecea10c5aed
+ last_write_checksum: sha1:1d1ec87969fbeb266d68d25d24ecabdc5aea14b3
+ pristine_git_object: 01167c66569c8143cb62f48d253dd13b36ddbb04
docs/models/operations/createkeysdata.mdx:
id: bfdef9b8abf8
last_write_checksum: sha1:3b7b75e7a6178e4ad5ef7d1ab27f9d00ce2fd3ec
@@ -8834,8 +8842,8 @@ trackedFiles:
pristine_git_object: e35bf2a8b4d6a47d2c2de3ad766e075c0a050dbd
docs/models/operations/listinternsrequest.mdx:
id: 74ce63b4e73a
- last_write_checksum: sha1:a614615da5dacd0781e642569820cc49d22d2ae6
- pristine_git_object: 476c6344d27d607b72a0690bbc344648d1da6cb9
+ last_write_checksum: sha1:04c0373c405c27b3e4d4b1487ab4ff2e588a5275
+ pristine_git_object: e65454e019dc260d55278574c0b1a1a4c6ccd90e
docs/models/operations/listinternvaultsecretsglobals.mdx:
id: d50aa244883c
last_write_checksum: sha1:994c63623ed392a3445ee5739ce025ca725f5a33
@@ -13658,8 +13666,8 @@ trackedFiles:
pristine_git_object: 15b7b4c80d50dd3aa0f7adc3ab4d9fb03a8efaa7
docs/sdks/interns/README.mdx:
id: 2f8a053ffe78
- last_write_checksum: sha1:f4f0d9b9eeebff511f489d65b7bd92b52317a582
- pristine_git_object: bd1a9aec740cb00ce8d297f299ec750e31f2c92e
+ last_write_checksum: sha1:072e518137d1e4148c5d7b055f16830b048751c7
+ pristine_git_object: 6f5a9900f6c6162b24a5cb8eb5042b373223a0ed
docs/sdks/models/README.mdx:
id: 58f1ca464e0b
last_write_checksum: sha1:dbae6f74244ab3e9fe38e075ab67f926f33ef87d
@@ -13782,12 +13790,12 @@ trackedFiles:
pristine_git_object: 410efafd6a7f50d91ccb87131fedbe0c3d47e15a
jsr.json:
id: 7f6ab7767282
- last_write_checksum: sha1:d6f8a7ef49bc1b7a5bb8a927882c66b271e7c8eb
- pristine_git_object: be3e0babc6a39b526683ecc11e6407f18963292e
+ last_write_checksum: sha1:d80bfa1b7b8c18894ed100f384f9106e9220227a
+ pristine_git_object: 9bbc05101617430a1fab01263154591de5d1ff7b
package.json:
id: 7030d0b2f71b
- last_write_checksum: sha1:d74eaf28ee1efc7a498f0046d0beabce53f40cb3
- pristine_git_object: 4cf3a1777ced6eac316f37c97a3bd222637b286c
+ last_write_checksum: sha1:073f34db59b4c3090e0f6abfb0a83ae0b0aa9bc0
+ pristine_git_object: 3f929892c1828d9b014f21f47340d088ff67c046
src/core.ts:
id: f431fdbcd144
last_write_checksum: sha1:5aa66b0b6a5964f3eea7f3098c2eb3c0ee9c0131
@@ -14010,8 +14018,8 @@ trackedFiles:
pristine_git_object: 7cae27395a6f842cde95565a869b1ba8567b38fd
src/funcs/internsChat.ts:
id: 36149dc7ea8d
- last_write_checksum: sha1:ca845a5adfc8014a77d334bc59ea614076b49a34
- pristine_git_object: bcd4742cb3c6184ebada20ca029f3a0148c9c429
+ last_write_checksum: sha1:6d3d03eff4c2ef91ec022fad84439fb2f4454ce7
+ pristine_git_object: e24ddf38b83551a5dbaa53593c322d9b29a492f9
src/funcs/internsCreateIntern.ts:
id: 74ff6cd8e4b0
last_write_checksum: sha1:4fda15c193e8c750e366940931884db9c9e80496
@@ -14030,16 +14038,16 @@ trackedFiles:
pristine_git_object: 48cd8682b2086de133ae3bb3c85c9b42a87a8b23
src/funcs/internsProvisionIntern.ts:
id: 38001699f102
- last_write_checksum: sha1:a6ce42e9ca605d9e32999a0f49ac538a4c2b5302
- pristine_git_object: 45ccd2e1b76e5c4d3f4b9ddf23820f63ffe31cc7
+ last_write_checksum: sha1:625d4fbcaa3a69a4b3f5dd1dab03a1683acbac1f
+ pristine_git_object: adb6b70af323f428b439815bb6157201e181f751
src/funcs/internsSuspendIntern.ts:
id: 5928ef254c09
- last_write_checksum: sha1:4e87032f30a7c4d7f5f929a55cd89dfdb39977f0
- pristine_git_object: f245137070216c323996b4bcb18a984b94beeb2a
+ last_write_checksum: sha1:43344f743770825e70975019e5095734e87a38bb
+ pristine_git_object: 51d4e415cd551acd4d8cf1c3cd2e7f6411faaf1f
src/funcs/internsUpdateIntern.ts:
id: 1d493469e489
- last_write_checksum: sha1:bac43a5ef65501749165c74b2d3179ff173869a0
- pristine_git_object: dbaceeac6a281ff28d67e05ad7df4e65f71f8700
+ last_write_checksum: sha1:315c1cc51ab6eafcfee8eb7ddf884e695aa5ea9b
+ pristine_git_object: d22be9b1ea235580a301f7a4908cb2e2df33fc18
src/funcs/modelsCount.ts:
id: 371adfc67b48
last_write_checksum: sha1:b5207eb21e0d08e0f1384059f5507fdb2eb16fe0
@@ -14298,8 +14306,8 @@ trackedFiles:
pristine_git_object: a187e58707bdb726ca2aff74941efe7493422d4e
src/lib/config.ts:
id: 320761608fb3
- last_write_checksum: sha1:9fade4cf1bca63a2b085ab8abaa6dc19b5fecd82
- pristine_git_object: 8aec2c30548ca1528f9a8dda377c1e34f751315a
+ last_write_checksum: sha1:a2de76c31f1366e18d2b2ee7c69e637ab10a5e83
+ pristine_git_object: 85397d0335e526f0053fbce5addfb364b8c2503a
src/lib/dlv.ts:
id: b1988214835a
last_write_checksum: sha1:eaac763b22717206a6199104e0403ed17a4e2711
@@ -15788,8 +15796,8 @@ trackedFiles:
pristine_git_object: d6060b435c0c598f20072b45fa0481a5d217d43b
src/models/internchaterrormetadata.ts:
id: 3a4e9b3de0d5
- last_write_checksum: sha1:02d1a63fdab97f11efac2726211f28cb00f703d1
- pristine_git_object: 5025da6ca62e7a046536498a537dd2a7aab217a0
+ last_write_checksum: sha1:45e727447b86692f22ac1b93a1474308861386ff
+ pristine_git_object: f1ad7371f55f8ad52f9e812830f0cd44f339b062
src/models/internchatmessage.ts:
id: b5080dcf9c97
last_write_checksum: sha1:a490db9666a36cddb5f9837d057de649a4826a1b
@@ -15840,8 +15848,8 @@ trackedFiles:
pristine_git_object: ae6f841af0a49f34f93eded5da09e1db819b5d2f
src/models/internlifecycleerror.ts:
id: 9d7cc6ac0062
- last_write_checksum: sha1:62eb8bdc836a65809eee48295fd25497f831c756
- pristine_git_object: 03b583846aff6f7cfe9d10fb0df3d44314535cd0
+ last_write_checksum: sha1:c9a538da773832d841820900d5764b1b37db3e40
+ pristine_git_object: a65e488c583cbd95c67dec12dfd13c1fda68021e
src/models/internlistresponse.ts:
id: cd6ace7e64c6
last_write_checksum: sha1:229306f65504f90f66f349a5322d0ea2cdb2dc37
@@ -16320,12 +16328,12 @@ trackedFiles:
pristine_git_object: 0a2ca2582247b2b60db1b464933ef5e599e430b8
src/models/operations/createintern.ts:
id: 49d763cf1338
- last_write_checksum: sha1:f5696019ce9bb5131b7b3c5175acbb323f6ee975
- pristine_git_object: b4ced13db2a2f538882678be873e2d74b06a2cd7
+ last_write_checksum: sha1:7e2d225847ec5613f55df7a179082e44b9d4f303
+ pristine_git_object: 1b89a6c6ff342d27af41a842b232931d59dc2446
src/models/operations/createinternchatcompletion.ts:
id: 0d92e801a635
- last_write_checksum: sha1:fe209c38ef045e7963dcff2b27020121986cee82
- pristine_git_object: 310ac2ef4d71d46983efbe5372a59932a44a8571
+ last_write_checksum: sha1:2a9192166df0cbc53d14bca299f33b7633d6af68
+ pristine_git_object: 17bc0b3d72b4d7661ea7b9ea07b9cd98c2c9c5bf
src/models/operations/createkeys.ts:
id: e7a250c8b7bb
last_write_checksum: sha1:f2f885bd37b28338188fb6daf52df4f4484fd975
@@ -16596,8 +16604,8 @@ trackedFiles:
pristine_git_object: 53af57ce4fbd45ca669919b1e55d41052b43bb74
src/models/operations/listinterns.ts:
id: 3fe8f2b8da99
- last_write_checksum: sha1:37baa89eaa2c881ed3019f31f2b1eab70415048e
- pristine_git_object: ad3509ebef850d80f92f917aca134e2ea80aae81
+ last_write_checksum: sha1:9b698c834a6e3f647f566ea445980e3e28378ebd
+ pristine_git_object: 688a9eba8222986615678f432546cb1c84880618
src/models/operations/listinternvaultsecrets.ts:
id: b36839da75f4
last_write_checksum: sha1:e0fb63ce51a57af12347462eea27ef389e0590cb
@@ -17792,8 +17800,8 @@ trackedFiles:
pristine_git_object: 5c82fe389f888827f98aa52788b850ef43422e07
src/sdk/interns.ts:
id: fc3b4e6c5008
- last_write_checksum: sha1:2c79df7d2c8ec4a11068620082fea7910dd02808
- pristine_git_object: 486223a71030bee4b0bc6c7b16a47ae65071d421
+ last_write_checksum: sha1:e34a19e0e23c27191193d54ef33cb0e4afc07022
+ pristine_git_object: c4df57e4383446f6b3b19858190c62e90999bf5b
src/sdk/models.ts:
id: 8c761ab180fd
last_write_checksum: sha1:0c5e5cefb7079fc69eb11ef157af6d2cb5255933
@@ -20983,9 +20991,9 @@ examples:
"200":
application/json: {"data": [{"attached_vault_id": null, "created_at": "2026-09-16T08:30:00.000Z", "description": "Researches customer questions", "hostname": "research-assistant.openrouter.ai", "id": "7c9e6679-7425-40de-944b-e07fc1f90ae7", "instructions": null, "last_failure_message": null, "model": "openai/gpt-5.4", "name": "research-assistant", "progress": null, "status": "running", "updated_at": "2026-09-16T08:45:00.000Z", "vault_id": "b431c59d-6eed-41ac-bc89-9a89be79a121", "workspace_id": "89f9f5b2-3f89-4eaf-83ca-5ceae149e8bb"}], "has_more": false}
"400":
- application/json: {"error": {"code": "not_found", "message": "Intern not found"}}
+ application/json: {"error": {"code": 404, "message": "Intern not found"}}
"500":
- application/json: {"error": {"code": "not_found", "message": "Intern not found"}}
+ application/json: {"error": {"code": 404, "message": "Intern not found"}}
createIntern:
speakeasy-default-create-intern:
requestBody:
@@ -20994,9 +21002,9 @@ examples:
"200":
application/json: {"attached_vault_id": null, "created_at": "2026-09-16T08:30:00.000Z", "description": "Researches customer questions", "hostname": "research-assistant.openrouter.ai", "id": "7c9e6679-7425-40de-944b-e07fc1f90ae7", "instructions": null, "last_failure_message": null, "model": "openai/gpt-5.4", "name": "research-assistant", "progress": null, "status": "running", "updated_at": "2026-09-16T08:45:00.000Z", "vault_id": "b431c59d-6eed-41ac-bc89-9a89be79a121", "workspace_id": "89f9f5b2-3f89-4eaf-83ca-5ceae149e8bb"}
"400":
- application/json: {"error": {"code": "not_found", "message": "Intern not found"}}
+ application/json: {"error": {"code": 404, "message": "Intern not found"}}
"500":
- application/json: {"error": {"code": "not_found", "message": "Intern not found"}}
+ application/json: {"error": {"code": 404, "message": "Intern not found"}}
deleteIntern:
speakeasy-default-delete-intern:
parameters:
@@ -21010,9 +21018,9 @@ examples:
"401":
application/json: {"error": {"code": "not_found", "message": "Intern not found"}}
"500":
- application/json: {"error": {"code": "not_found", "message": "Intern not found"}}
+ application/json: {"error": {"code": 404, "message": "Intern not found"}}
"400":
- application/json: {"error": {"code": "not_found", "message": "Intern not found"}}
+ application/json: {"error": {"code": 404, "message": "Intern not found"}}
getIntern:
speakeasy-default-get-intern:
parameters:
@@ -21022,9 +21030,9 @@ examples:
"200":
application/json: {"attached_vault_id": null, "created_at": "2026-09-16T08:30:00.000Z", "description": "Researches customer questions", "hostname": "research-assistant.openrouter.ai", "id": "7c9e6679-7425-40de-944b-e07fc1f90ae7", "instructions": null, "last_failure_message": null, "model": "openai/gpt-5.4", "name": "research-assistant", "progress": null, "status": "running", "updated_at": "2026-09-16T08:45:00.000Z", "vault_id": "b431c59d-6eed-41ac-bc89-9a89be79a121", "workspace_id": "89f9f5b2-3f89-4eaf-83ca-5ceae149e8bb"}
"401":
- application/json: {"error": {"code": "not_found", "message": "Intern not found"}}
+ application/json: {"error": {"code": 404, "message": "Intern not found"}}
"500":
- application/json: {"error": {"code": "not_found", "message": "Intern not found"}}
+ application/json: {"error": {"code": 404, "message": "Intern not found"}}
updateIntern:
speakeasy-default-update-intern:
parameters:
@@ -21036,9 +21044,9 @@ examples:
"200":
application/json: {"attached_vault_id": null, "created_at": "2026-09-16T08:30:00.000Z", "description": "Researches customer questions", "hostname": "research-assistant.openrouter.ai", "id": "7c9e6679-7425-40de-944b-e07fc1f90ae7", "instructions": null, "last_failure_message": null, "model": "openai/gpt-5.4", "name": "research-assistant", "progress": null, "status": "running", "updated_at": "2026-09-16T08:45:00.000Z", "vault_id": "b431c59d-6eed-41ac-bc89-9a89be79a121", "workspace_id": "89f9f5b2-3f89-4eaf-83ca-5ceae149e8bb"}
"400":
- application/json: {"error": {"code": "not_found", "message": "Intern not found"}}
+ application/json: {"error": {"code": 404, "message": "Intern not found"}}
"500":
- application/json: {"error": {"code": "not_found", "message": "Intern not found"}}
+ application/json: {"error": {"code": 404, "message": "Intern not found"}}
provisionIntern:
speakeasy-default-provision-intern:
parameters:
@@ -21050,7 +21058,9 @@ examples:
"401":
application/json: {"error": {"code": "not_found", "message": "Intern not found"}}
"500":
- application/json: {"error": {"code": "not_found", "message": "Intern not found"}}
+ application/json: {"error": {"code": 404, "message": "Intern not found"}}
+ "400":
+ application/json: {"error": {"code": 404, "message": "Intern not found"}}
suspendIntern:
speakeasy-default-suspend-intern:
parameters:
@@ -21062,7 +21072,9 @@ examples:
"401":
application/json: {"error": {"code": "not_found", "message": "Intern not found"}}
"500":
- application/json: {"error": {"code": "not_found", "message": "Intern not found"}}
+ application/json: {"error": {"code": 404, "message": "Intern not found"}}
+ "400":
+ application/json: {"error": {"code": 404, "message": "Intern not found"}}
createInternChatCompletion:
speakeasy-default-create-intern-chat-completion:
parameters:
@@ -21075,6 +21087,10 @@ examples:
application/json: {"error": {"code": 409, "message": "That question is no longer waiting for an answer."}}
"502":
application/json: {"error": {"code": 409, "message": "That question is no longer waiting for an answer."}}
+ "409":
+ application/json: {"error": {"code": 409, "message": "That question is no longer waiting for an answer."}}
+ "503":
+ application/json: {"error": {"code": 409, "message": "That question is no longer waiting for an answer."}}
createApiAlphaDecisions:
speakeasy-default-create-api-alpha-decisions:
requestBody:
@@ -21138,6 +21154,4 @@ examples:
"529":
application/json: {"error": {"code": 529, "message": "Provider returned error"}}
examplesVersion: 1.0.2
-releaseNotes: |
- ## Typescript SDK Changes:
- * `openrouter.systemOne.create()`: **Added**
+releaseNotes: "## Typescript SDK Changes:\n* `openrouter.interns.listInterns()`: `error.metadata` **Added**\n* `openrouter.interns.createIntern()`: `error.metadata` **Added**\n* `openrouter.interns.deleteIntern()`: `error.metadata` **Added**\n* `openrouter.interns.getIntern()`: `error.metadata` **Added**\n* `openrouter.interns.updateIntern()`: `error` **Changed**\n* `openrouter.interns.provisionIntern()`: `error` **Changed**\n* `openrouter.interns.suspendIntern()`: `error` **Changed**\n* `openrouter.interns.chat()`: \n * `response.[].data.error.metadata.retryable` **Added**\n * `error` **Changed**\n"
diff --git a/.speakeasy/gen.yaml b/.speakeasy/gen.yaml
index 569c87482..e67fef312 100644
--- a/.speakeasy/gen.yaml
+++ b/.speakeasy/gen.yaml
@@ -37,7 +37,7 @@ generation:
documentation: mintlify
preApplyUnionDiscriminators: true
typescript:
- version: 1.3.8
+ version: 1.3.9
acceptHeaderEnum: false
additionalDependencies:
dependencies:
diff --git a/.speakeasy/out.openapi.yaml b/.speakeasy/out.openapi.yaml
index d877656cb..aae9a0e2d 100644
--- a/.speakeasy/out.openapi.yaml
+++ b/.speakeasy/out.openapi.yaml
@@ -12772,6 +12772,7 @@ components:
message: 'That question is no longer waiting for an answer.'
metadata:
reason: 'interaction_not_pending'
+ retryable: false
properties:
code:
description: 'The HTTP status of the response.'
@@ -12788,6 +12789,7 @@ components:
description: 'Machine-readable detail for the failure.'
example:
reason: 'interaction_not_pending'
+ retryable: false
properties:
reason:
description: 'A stable reason a client can branch on.'
@@ -12810,8 +12812,12 @@ components:
- 'turn_failed'
type: 'string'
x-speakeasy-unknown-values: allow
+ retryable:
+ description: 'Whether the same request may be sent again unchanged. Always `true` for the transient refusals — `busy`, `intern_not_ready`, `intern_unreachable`, `rate_limited`, `stream_severed` and `timeout` — and always `false` for the ones a retry cannot fix. For `turn_failed` it varies by failure and is the intern''s own classification of what went wrong: `true` for an upstream overload, rate limit, timeout or transport fault, `false` for an authentication or bad-request failure that would be rejected the same way again. Branch on this field rather than on `reason` when deciding whether to retry. A `429`, and a `409` or `503` with reason `busy`, also carry a `Retry-After` header saying how long to wait.'
+ type: 'boolean'
required:
- 'reason'
+ - 'retryable'
type: 'object'
InternChatErrorResponse:
description: 'A refusal before the stream opens. Once the response is `200` and streaming, failures arrive as a chunk with `finish_reason: "error"` instead.'
@@ -12821,6 +12827,7 @@ components:
message: 'That question is no longer waiting for an answer.'
metadata:
reason: 'interaction_not_pending'
+ retryable: false
properties:
error:
$ref: '#/components/schemas/InternChatError'
@@ -12872,6 +12879,7 @@ components:
message: 'The intern could not continue this run.'
metadata:
reason: 'attachment_failed'
+ retryable: false
properties:
code:
description: 'The HTTP status this failure would have had before the stream opened.'
@@ -13057,8 +13065,11 @@ components:
description: 'Intern lifecycle request failure.'
example:
error:
- code: 'not_found'
+ code: 404
message: 'Intern not found'
+ metadata:
+ reason: 'not_found'
+ retryable: false
properties:
error:
additionalProperties: false
@@ -13069,6 +13080,17 @@ components:
- type: 'integer'
message:
type: 'string'
+ metadata:
+ additionalProperties: false
+ properties:
+ reason:
+ type: 'string'
+ retryable:
+ type: 'boolean'
+ required:
+ - 'reason'
+ - 'retryable'
+ type: 'object'
required:
- 'code'
- 'message'
@@ -36364,13 +36386,13 @@ paths:
maximum: 500
minimum: 1
type: 'integer'
- - description: 'Comma-separated lifecycle statuses to include.'
+ - description: 'Comma-separated lifecycle statuses to include, at most 8. Repeats are collapsed.'
explode: false
in: 'query'
name: 'status'
required: false
schema:
- description: 'Comma-separated lifecycle statuses to include.'
+ description: 'Comma-separated lifecycle statuses to include, at most 8. Repeats are collapsed.'
example:
- 'queued'
- 'running'
@@ -36386,6 +36408,7 @@ paths:
- 'destroy_failed'
type: 'string'
x-speakeasy-unknown-values: allow
+ maxItems: 8
type: 'array'
style: 'form'
- description: 'The opaque `next_cursor` of the previous page. Returns the interns that come after it in the newest-first order. A malformed cursor is a 400.'
@@ -36434,8 +36457,11 @@ paths:
application/json:
example:
error:
- code: 'invalid_body'
+ code: 400
message: 'Invalid list query'
+ metadata:
+ reason: 'invalid_body'
+ retryable: false
schema:
$ref: '#/components/schemas/InternLifecycleError'
description: 'The list filters are invalid.'
@@ -36464,8 +36490,11 @@ paths:
application/json:
example:
error:
- code: 'not_found'
+ code: 404
message: 'Intern not found'
+ metadata:
+ reason: 'not_found'
+ retryable: false
schema:
$ref: '#/components/schemas/InternLifecycleError'
description: 'The caller is outside the Intern API programme, the intern is hidden, or lifecycle writes are disabled.'
@@ -36475,20 +36504,26 @@ paths:
example:
error:
code: 408
- message: 'Request timed out'
+ message: 'Operation timed out after 10s. Please try again later.'
+ metadata:
+ reason: 'timeout'
+ retryable: true
schema:
$ref: '#/components/schemas/InternLifecycleError'
- description: 'The request exceeded its route deadline.'
+ description: 'The request exceeded its route deadline. The deadline quoted in the message is the route''s own, so it differs between operations.'
'500':
content:
application/json:
example:
error:
- code: 'internal_error'
+ code: 500
message: 'The request could not be completed'
+ metadata:
+ reason: 'internal_error'
+ retryable: true
schema:
$ref: '#/components/schemas/InternLifecycleError'
- description: 'The request could not be completed.'
+ description: 'The request could not be completed. `metadata.reason` says whether to try again: `internal_error` is a transient failure and carries `metadata.retryable: true`, so the same request may be sent again, while `configuration_error` carries `retryable: false` because the next attempt reads the same missing binding or unusable stored credential.'
security:
- apiKey: []
summary: 'List interns'
@@ -36498,13 +36533,14 @@ paths:
description: 'Creates an intern in an explicit workspace. The operation also creates its private vault. It can start provisioning immediately or wait for a later provision call. A retry with the same idempotency key and body resumes unfinished work. The request body is capped at 1048576 bytes and a larger body is refused with 413. The API key selects the caller, workspace and visible interns. There is no default workspace fallback. Requests on regional hostnames such as `eu.openrouter.ai` are refused. [API key](/docs/api-reference/authentication) required.'
operationId: 'createIntern'
parameters:
- - description: 'Key that makes retries resume the same create operation. Without one, the server derives a stable key from the request body.'
+ - description: 'Key that makes retries resume the same create operation, from 1 through 255 characters. An empty or longer key is refused with 400. Without the header, the server derives a stable key from the request body.'
in: 'header'
name: 'Idempotency-Key'
required: false
schema:
- description: 'Key that makes retries resume the same create operation. Without one, the server derives a stable key from the request body.'
+ description: 'Key that makes retries resume the same create operation, from 1 through 255 characters. An empty or longer key is refused with 400. Without the header, the server derives a stable key from the request body.'
example: 'create-research-assistant-2026-09-16'
+ maxLength: 255
minLength: 1
type: 'string'
requestBody:
@@ -36565,8 +36601,11 @@ paths:
application/json:
example:
error:
- code: 'invalid_body'
+ code: 400
message: 'Invalid request body'
+ metadata:
+ reason: 'invalid_body'
+ retryable: false
schema:
$ref: '#/components/schemas/InternLifecycleError'
description: 'The request body is invalid.'
@@ -36585,8 +36624,11 @@ paths:
application/json:
example:
error:
- code: 'no_acting_user'
+ code: 403
message: 'This key acts as the organization and has no member to own a new intern'
+ metadata:
+ reason: 'no_acting_user'
+ retryable: false
schema:
$ref: '#/components/schemas/InternLifecycleError'
description: 'The key acts as an organization and has no member who can own the intern, or regional access is refused.'
@@ -36595,8 +36637,11 @@ paths:
application/json:
example:
error:
- code: 'not_found'
+ code: 404
message: 'Intern not found'
+ metadata:
+ reason: 'not_found'
+ retryable: false
schema:
$ref: '#/components/schemas/InternLifecycleError'
description: 'The caller is outside the Intern API programme, the intern is hidden, or lifecycle writes are disabled.'
@@ -36606,10 +36651,13 @@ paths:
example:
error:
code: 408
- message: 'Request timed out'
+ message: 'Operation timed out after 10s. Please try again later.'
+ metadata:
+ reason: 'timeout'
+ retryable: true
schema:
$ref: '#/components/schemas/InternLifecycleError'
- description: 'The request exceeded its route deadline.'
+ description: 'The request exceeded its route deadline. The deadline quoted in the message is the route''s own, so it differs between operations.'
'409':
content:
application/json:
@@ -36617,13 +36665,19 @@ paths:
idempotency_key_reused:
value:
error:
- code: 'idempotency_key_reused'
+ code: 409
message: 'This Idempotency-Key was already used with a different request'
+ metadata:
+ reason: 'idempotency_key_reused'
+ retryable: false
name_taken:
value:
error:
- code: 'name_taken'
+ code: 409
message: 'An intern named "research-assistant" already exists in this workspace'
+ metadata:
+ reason: 'name_taken'
+ retryable: false
schema:
$ref: '#/components/schemas/InternLifecycleError'
description: 'The idempotency key was reused, the intern name is already taken in the workspace, the member reached the intern limit, or the requested vault cannot be attached.'
@@ -36632,8 +36686,11 @@ paths:
application/json:
example:
error:
- code: 'payload_too_large'
+ code: 413
message: 'Request body exceeds 1048576 bytes'
+ metadata:
+ reason: 'payload_too_large'
+ retryable: false
schema:
$ref: '#/components/schemas/InternLifecycleError'
description: 'The request body is larger than 1048576 bytes.'
@@ -36642,18 +36699,24 @@ paths:
application/json:
example:
error:
- code: 'internal_error'
+ code: 500
message: 'The request could not be completed'
+ metadata:
+ reason: 'internal_error'
+ retryable: true
schema:
$ref: '#/components/schemas/InternLifecycleError'
- description: 'The request could not be completed.'
+ description: 'The request could not be completed. `metadata.reason` says whether to try again: `internal_error` is a transient failure and carries `metadata.retryable: true`, so the same request may be sent again, while `configuration_error` carries `retryable: false` because the next attempt reads the same missing binding or unusable stored credential.'
'502':
content:
application/json:
example:
error:
- code: 'upstream_unavailable'
+ code: 502
message: 'The intern was created but setup is not ready yet, retry the request'
+ metadata:
+ reason: 'upstream_unavailable'
+ retryable: true
schema:
$ref: '#/components/schemas/InternLifecycleError'
description: 'The vault or provisioner did not complete a recoverable create step. Retry the same request.'
@@ -36702,8 +36765,11 @@ paths:
application/json:
example:
error:
- code: 'invalid_body'
+ code: 400
message: 'Invalid request body'
+ metadata:
+ reason: 'invalid_body'
+ retryable: false
schema:
$ref: '#/components/schemas/InternLifecycleError'
description: 'The request body is invalid.'
@@ -36732,8 +36798,11 @@ paths:
application/json:
example:
error:
- code: 'not_found'
+ code: 404
message: 'Intern not found'
+ metadata:
+ reason: 'not_found'
+ retryable: false
schema:
$ref: '#/components/schemas/InternLifecycleError'
description: 'The caller is outside the Intern API programme, the intern is hidden, or lifecycle writes are disabled.'
@@ -36743,17 +36812,23 @@ paths:
example:
error:
code: 408
- message: 'Request timed out'
+ message: 'Operation timed out after 10s. Please try again later.'
+ metadata:
+ reason: 'timeout'
+ retryable: true
schema:
$ref: '#/components/schemas/InternLifecycleError'
- description: 'The request exceeded its route deadline.'
+ description: 'The request exceeded its route deadline. The deadline quoted in the message is the route''s own, so it differs between operations.'
'409':
content:
application/json:
example:
error:
- code: 'intern_busy'
+ code: 409
message: 'The intern is not in a state that allows this operation'
+ metadata:
+ reason: 'intern_busy'
+ retryable: false
schema:
$ref: '#/components/schemas/InternLifecycleError'
description: 'The intern is not in a state that allows this operation.'
@@ -36762,8 +36837,11 @@ paths:
application/json:
example:
error:
- code: 'payload_too_large'
+ code: 413
message: 'Request body exceeds 1048576 bytes'
+ metadata:
+ reason: 'payload_too_large'
+ retryable: false
schema:
$ref: '#/components/schemas/InternLifecycleError'
description: 'The request body is larger than 1048576 bytes.'
@@ -36772,18 +36850,24 @@ paths:
application/json:
example:
error:
- code: 'internal_error'
+ code: 500
message: 'The request could not be completed'
+ metadata:
+ reason: 'internal_error'
+ retryable: true
schema:
$ref: '#/components/schemas/InternLifecycleError'
- description: 'The request could not be completed.'
+ description: 'The request could not be completed. `metadata.reason` says whether to try again: `internal_error` is a transient failure and carries `metadata.retryable: true`, so the same request may be sent again, while `configuration_error` carries `retryable: false` because the next attempt reads the same missing binding or unusable stored credential.'
'502':
content:
application/json:
example:
error:
- code: 'upstream_unavailable'
+ code: 502
message: 'The intern service could not be reached, retry the request'
+ metadata:
+ reason: 'upstream_unavailable'
+ retryable: true
schema:
$ref: '#/components/schemas/InternLifecycleError'
description: 'The intern service could not accept the operation.'
@@ -36852,8 +36936,11 @@ paths:
application/json:
example:
error:
- code: 'not_found'
+ code: 404
message: 'Intern not found'
+ metadata:
+ reason: 'not_found'
+ retryable: false
schema:
$ref: '#/components/schemas/InternLifecycleError'
description: 'The caller is outside the Intern API programme, the intern is hidden, or lifecycle writes are disabled.'
@@ -36863,20 +36950,26 @@ paths:
example:
error:
code: 408
- message: 'Request timed out'
+ message: 'Operation timed out after 10s. Please try again later.'
+ metadata:
+ reason: 'timeout'
+ retryable: true
schema:
$ref: '#/components/schemas/InternLifecycleError'
- description: 'The request exceeded its route deadline.'
+ description: 'The request exceeded its route deadline. The deadline quoted in the message is the route''s own, so it differs between operations.'
'500':
content:
application/json:
example:
error:
- code: 'internal_error'
+ code: 500
message: 'The request could not be completed'
+ metadata:
+ reason: 'internal_error'
+ retryable: true
schema:
$ref: '#/components/schemas/InternLifecycleError'
- description: 'The request could not be completed.'
+ description: 'The request could not be completed. `metadata.reason` says whether to try again: `internal_error` is a transient failure and carries `metadata.retryable: true`, so the same request may be sent again, while `configuration_error` carries `retryable: false` because the next attempt reads the same missing binding or unusable stored credential.'
security:
- apiKey: []
summary: 'Get an intern'
@@ -36931,8 +37024,11 @@ paths:
application/json:
example:
error:
- code: 'invalid_body'
+ code: 400
message: 'Invalid request body'
+ metadata:
+ reason: 'invalid_body'
+ retryable: false
schema:
$ref: '#/components/schemas/InternLifecycleError'
description: 'The request body is invalid.'
@@ -36961,8 +37057,11 @@ paths:
application/json:
example:
error:
- code: 'not_found'
+ code: 404
message: 'Intern not found'
+ metadata:
+ reason: 'not_found'
+ retryable: false
schema:
$ref: '#/components/schemas/InternLifecycleError'
description: 'The caller is outside the Intern API programme, the intern is hidden, or lifecycle writes are disabled.'
@@ -36972,17 +37071,36 @@ paths:
example:
error:
code: 408
- message: 'Request timed out'
+ message: 'Operation timed out after 10s. Please try again later.'
+ metadata:
+ reason: 'timeout'
+ retryable: true
+ schema:
+ $ref: '#/components/schemas/InternLifecycleError'
+ description: 'The request exceeded its route deadline. The deadline quoted in the message is the route''s own, so it differs between operations.'
+ '409':
+ content:
+ application/json:
+ example:
+ error:
+ code: 409
+ message: 'An intern named "research-assistant" already exists in this workspace'
+ metadata:
+ reason: 'name_taken'
+ retryable: false
schema:
$ref: '#/components/schemas/InternLifecycleError'
- description: 'The request exceeded its route deadline.'
+ description: 'The new name is already taken by an intern in this workspace.'
'413':
content:
application/json:
example:
error:
- code: 'payload_too_large'
+ code: 413
message: 'Request body exceeds 1048576 bytes'
+ metadata:
+ reason: 'payload_too_large'
+ retryable: false
schema:
$ref: '#/components/schemas/InternLifecycleError'
description: 'The request body is larger than 1048576 bytes.'
@@ -36991,11 +37109,14 @@ paths:
application/json:
example:
error:
- code: 'internal_error'
+ code: 500
message: 'The request could not be completed'
+ metadata:
+ reason: 'internal_error'
+ retryable: true
schema:
$ref: '#/components/schemas/InternLifecycleError'
- description: 'The request could not be completed.'
+ description: 'The request could not be completed. `metadata.reason` says whether to try again: `internal_error` is a transient failure and carries `metadata.retryable: true`, so the same request may be sent again, while `configuration_error` carries `retryable: false` because the next attempt reads the same missing binding or unusable stored credential.'
security:
- apiKey: []
summary: 'Update an intern'
@@ -37064,6 +37185,7 @@ paths:
message: 'The intern did not accept that answer for this tool_call_id.'
metadata:
reason: 'bad_request'
+ retryable: false
schema:
$ref: '#/components/schemas/InternChatErrorResponse'
description: 'The body is not a valid request (`bad_request`), or the intern did not accept the answer for the pending question, such as a permission option it did not offer.'
@@ -37096,9 +37218,23 @@ paths:
message: 'No pending question has this tool_call_id.'
metadata:
reason: 'interaction_unknown'
+ retryable: false
schema:
$ref: '#/components/schemas/InternChatErrorResponse'
description: 'The caller is outside the interns programme, the intern does not exist for this key (`not_found`), or no pending question has this `tool_call_id` in this session (`interaction_unknown`).'
+ '408':
+ content:
+ application/json:
+ example:
+ error:
+ code: 408
+ message: 'Operation timed out after 300s. Please try again later.'
+ metadata:
+ reason: 'timeout'
+ retryable: true
+ schema:
+ $ref: '#/components/schemas/InternChatErrorResponse'
+ description: 'The request exceeded the route''s own deadline before the handler answered (`timeout`). Distinct from the 504, which is the intern failing to answer within the turn budget.'
'409':
content:
application/json:
@@ -37108,9 +37244,18 @@ paths:
message: 'The run that asked this question has already ended.'
metadata:
reason: 'interaction_not_pending'
+ retryable: false
schema:
$ref: '#/components/schemas/InternChatErrorResponse'
- description: 'The intern is not running (`intern_not_ready`), another turn is running in this session (`busy`), the question is no longer waiting (`interaction_not_pending`), or another request is already attached to the run (`attachment_failed`).'
+ description: 'The intern is not running (`intern_not_ready`), another turn is already running on this intern (`busy`), the question is no longer waiting (`interaction_not_pending`), or another request is already attached to the run (`attachment_failed`). The turn lock is per intern, not per session. `intern_not_ready` and `busy` report `retryable: true`, and a `busy` refusal carries `Retry-After`.'
+ headers:
+ Retry-After:
+ description: 'Seconds to wait before retrying this request. Present only on a `busy` refusal.'
+ required: false
+ schema:
+ description: 'Seconds to wait before retrying this request. Present only on a `busy` refusal.'
+ example: '5'
+ type: 'string'
'410':
content:
application/json:
@@ -37120,6 +37265,7 @@ paths:
message: 'The run produced more output than the intern retains for replay.'
metadata:
reason: 'attachment_failed'
+ retryable: false
schema:
$ref: '#/components/schemas/InternChatErrorResponse'
description: 'The run produced more output than the intern retains, so the paused stream cannot be resumed (`attachment_failed`).'
@@ -37132,6 +37278,7 @@ paths:
message: 'Request body exceeds 1048576 bytes'
metadata:
reason: 'payload_too_large'
+ retryable: false
schema:
$ref: '#/components/schemas/InternChatErrorResponse'
description: 'The body exceeds 1 MiB (`payload_too_large`).'
@@ -37144,9 +37291,18 @@ paths:
message: 'Too many intern turns. Please wait a moment.'
metadata:
reason: 'rate_limited'
+ retryable: true
schema:
$ref: '#/components/schemas/InternChatErrorResponse'
- description: 'Too many turns for the user or organization this key acts as (`rate_limited`).'
+ description: 'Too many turns for the user or organization this key acts as (`rate_limited`). It reports `retryable: true` and carries `Retry-After`.'
+ headers:
+ Retry-After:
+ description: 'Seconds to wait before retrying this request.'
+ required: true
+ schema:
+ description: 'Seconds to wait before retrying this request.'
+ example: '60'
+ type: 'string'
'502':
content:
application/json:
@@ -37156,9 +37312,10 @@ paths:
message: 'The intern could not be reached.'
metadata:
reason: 'intern_unreachable'
+ retryable: true
schema:
$ref: '#/components/schemas/InternChatErrorResponse'
- description: 'The intern could not be reached or rejected the request (`intern_unreachable`, `intern_rejected`), the intern refused the turn before any output (`turn_failed`), or its stream ended before the turn started (`stream_severed`).'
+ description: 'The intern could not be reached or rejected the request (`intern_unreachable`, `intern_rejected`), the intern refused the turn before any output (`turn_failed`), or its stream ended before the turn started (`stream_severed`). `intern_unreachable` and `stream_severed` are transient and report `retryable: true`; `intern_rejected` reports `false`. A `turn_failed` varies by failure and carries the intern''s own classification of what went wrong, so read `metadata.retryable` rather than assuming from the reason.'
'503':
content:
application/json:
@@ -37168,9 +37325,18 @@ paths:
message: 'The intern cannot hold another run open across a question right now. Retry later.'
metadata:
reason: 'busy'
+ retryable: true
schema:
$ref: '#/components/schemas/InternChatErrorResponse'
- description: 'The intern cannot hold another run open across a question right now (`busy`). Retry later.'
+ description: 'The intern cannot hold another run open across a question right now (`busy`). It reports `retryable: true` and carries `Retry-After`.'
+ headers:
+ Retry-After:
+ description: 'Seconds to wait before retrying this request.'
+ required: true
+ schema:
+ description: 'Seconds to wait before retrying this request.'
+ example: '5'
+ type: 'string'
'504':
content:
application/json:
@@ -37180,6 +37346,7 @@ paths:
message: 'The intern did not answer in time.'
metadata:
reason: 'timeout'
+ retryable: true
schema:
$ref: '#/components/schemas/InternChatErrorResponse'
description: 'The intern did not answer within the request budget (`timeout`).'
@@ -37196,7 +37363,7 @@ paths:
- $ref: "#/components/parameters/AppCategories"
/interns/{internId}/provision:
post:
- description: 'Starts the first boot, or resumes an intern after suspension. The API key selects the caller, workspace and visible interns. There is no default workspace fallback. Requests on regional hostnames such as `eu.openrouter.ai` are refused. [API key](/docs/api-reference/authentication) required.'
+ description: 'Starts the first boot, or resumes an intern after suspension. This operation takes no request body. A body carrying any field is refused with 400 rather than ignored. The API key selects the caller, workspace and visible interns. There is no default workspace fallback. Requests on regional hostnames such as `eu.openrouter.ai` are refused. [API key](/docs/api-reference/authentication) required.'
operationId: 'provisionIntern'
parameters:
- description: 'ID of an intern visible to the authenticated API key.'
@@ -37217,6 +37384,19 @@ paths:
schema:
$ref: '#/components/schemas/ProvisionInternResponse'
description: 'The operation was accepted.'
+ '400':
+ content:
+ application/json:
+ example:
+ error:
+ code: 400
+ message: 'Invalid request body'
+ metadata:
+ reason: 'invalid_body'
+ retryable: false
+ schema:
+ $ref: '#/components/schemas/InternLifecycleError'
+ description: 'The request body is invalid.'
'401':
content:
application/json:
@@ -37242,8 +37422,11 @@ paths:
application/json:
example:
error:
- code: 'not_found'
+ code: 404
message: 'Intern not found'
+ metadata:
+ reason: 'not_found'
+ retryable: false
schema:
$ref: '#/components/schemas/InternLifecycleError'
description: 'The caller is outside the Intern API programme, the intern is hidden, or lifecycle writes are disabled.'
@@ -37253,37 +37436,62 @@ paths:
example:
error:
code: 408
- message: 'Request timed out'
+ message: 'Operation timed out after 10s. Please try again later.'
+ metadata:
+ reason: 'timeout'
+ retryable: true
schema:
$ref: '#/components/schemas/InternLifecycleError'
- description: 'The request exceeded its route deadline.'
+ description: 'The request exceeded its route deadline. The deadline quoted in the message is the route''s own, so it differs between operations.'
'409':
content:
application/json:
example:
error:
- code: 'intern_busy'
+ code: 409
message: 'The intern is not in a state that allows this operation'
+ metadata:
+ reason: 'intern_busy'
+ retryable: false
schema:
$ref: '#/components/schemas/InternLifecycleError'
description: 'The intern is not in a state that allows this operation.'
+ '413':
+ content:
+ application/json:
+ example:
+ error:
+ code: 413
+ message: 'Request body exceeds 1048576 bytes'
+ metadata:
+ reason: 'payload_too_large'
+ retryable: false
+ schema:
+ $ref: '#/components/schemas/InternLifecycleError'
+ description: 'The request body is larger than 1048576 bytes.'
'500':
content:
application/json:
example:
error:
- code: 'internal_error'
+ code: 500
message: 'The request could not be completed'
+ metadata:
+ reason: 'internal_error'
+ retryable: true
schema:
$ref: '#/components/schemas/InternLifecycleError'
- description: 'The request could not be completed.'
+ description: 'The request could not be completed. `metadata.reason` says whether to try again: `internal_error` is a transient failure and carries `metadata.retryable: true`, so the same request may be sent again, while `configuration_error` carries `retryable: false` because the next attempt reads the same missing binding or unusable stored credential.'
'502':
content:
application/json:
example:
error:
- code: 'upstream_unavailable'
+ code: 502
message: 'The intern service could not be reached, retry the request'
+ metadata:
+ reason: 'upstream_unavailable'
+ retryable: true
schema:
$ref: '#/components/schemas/InternLifecycleError'
description: 'The intern service could not accept the operation.'
@@ -37298,7 +37506,7 @@ paths:
- $ref: "#/components/parameters/AppCategories"
/interns/{internId}/suspend:
post:
- description: 'Stops the intern runtime while keeping its disk and configuration for a later provision call. The API key selects the caller, workspace and visible interns. There is no default workspace fallback. Requests on regional hostnames such as `eu.openrouter.ai` are refused. [API key](/docs/api-reference/authentication) required.'
+ description: 'Stops the intern runtime while keeping its disk and configuration for a later provision call. This operation takes no request body. A body carrying any field is refused with 400 rather than ignored. The API key selects the caller, workspace and visible interns. There is no default workspace fallback. Requests on regional hostnames such as `eu.openrouter.ai` are refused. [API key](/docs/api-reference/authentication) required.'
operationId: 'suspendIntern'
parameters:
- description: 'ID of an intern visible to the authenticated API key.'
@@ -37319,6 +37527,19 @@ paths:
schema:
$ref: '#/components/schemas/SuspendInternResponse'
description: 'Intern suspended.'
+ '400':
+ content:
+ application/json:
+ example:
+ error:
+ code: 400
+ message: 'Invalid request body'
+ metadata:
+ reason: 'invalid_body'
+ retryable: false
+ schema:
+ $ref: '#/components/schemas/InternLifecycleError'
+ description: 'The request body is invalid.'
'401':
content:
application/json:
@@ -37344,8 +37565,11 @@ paths:
application/json:
example:
error:
- code: 'not_found'
+ code: 404
message: 'Intern not found'
+ metadata:
+ reason: 'not_found'
+ retryable: false
schema:
$ref: '#/components/schemas/InternLifecycleError'
description: 'The caller is outside the Intern API programme, the intern is hidden, or lifecycle writes are disabled.'
@@ -37355,37 +37579,62 @@ paths:
example:
error:
code: 408
- message: 'Request timed out'
+ message: 'Operation timed out after 10s. Please try again later.'
+ metadata:
+ reason: 'timeout'
+ retryable: true
schema:
$ref: '#/components/schemas/InternLifecycleError'
- description: 'The request exceeded its route deadline.'
+ description: 'The request exceeded its route deadline. The deadline quoted in the message is the route''s own, so it differs between operations.'
'409':
content:
application/json:
example:
error:
- code: 'intern_busy'
+ code: 409
message: 'The intern is not in a state that allows this operation'
+ metadata:
+ reason: 'intern_busy'
+ retryable: false
schema:
$ref: '#/components/schemas/InternLifecycleError'
description: 'The intern is not in a state that allows this operation.'
+ '413':
+ content:
+ application/json:
+ example:
+ error:
+ code: 413
+ message: 'Request body exceeds 1048576 bytes'
+ metadata:
+ reason: 'payload_too_large'
+ retryable: false
+ schema:
+ $ref: '#/components/schemas/InternLifecycleError'
+ description: 'The request body is larger than 1048576 bytes.'
'500':
content:
application/json:
example:
error:
- code: 'internal_error'
+ code: 500
message: 'The request could not be completed'
+ metadata:
+ reason: 'internal_error'
+ retryable: true
schema:
$ref: '#/components/schemas/InternLifecycleError'
- description: 'The request could not be completed.'
+ description: 'The request could not be completed. `metadata.reason` says whether to try again: `internal_error` is a transient failure and carries `metadata.retryable: true`, so the same request may be sent again, while `configuration_error` carries `retryable: false` because the next attempt reads the same missing binding or unusable stored credential.'
'502':
content:
application/json:
example:
error:
- code: 'upstream_unavailable'
+ code: 502
message: 'The intern service could not be reached, retry the request'
+ metadata:
+ reason: 'upstream_unavailable'
+ retryable: true
schema:
$ref: '#/components/schemas/InternLifecycleError'
description: 'The intern service could not accept the operation.'
diff --git a/.speakeasy/workflow.lock b/.speakeasy/workflow.lock
index 25558463b..050c0b95b 100644
--- a/.speakeasy/workflow.lock
+++ b/.speakeasy/workflow.lock
@@ -2,8 +2,8 @@ speakeasyVersion: 1.787.0
sources:
OpenRouter API:
sourceNamespace: open-router-chat-completions-api
- sourceRevisionDigest: sha256:217cc17d35c02b1b2bb855a52836ea401e778d519baec6679c86e18d07311a76
- sourceBlobDigest: sha256:7228242345cf800709206502b1f6b6103752a46578e8f553d67bc6e373995327
+ sourceRevisionDigest: sha256:28c9fb69b7ab04edbbe4d9b887d11553e2c4e7d147dd3e1e73fe642a00741d7c
+ sourceBlobDigest: sha256:ef9a1f17fef94059bf6972bd0dd96bff3166a06edf81f9ede3cfca9e47162f59
tags:
- latest
- 1.0.0
@@ -11,10 +11,10 @@ targets:
openrouter:
source: OpenRouter API
sourceNamespace: open-router-chat-completions-api
- sourceRevisionDigest: sha256:217cc17d35c02b1b2bb855a52836ea401e778d519baec6679c86e18d07311a76
- sourceBlobDigest: sha256:7228242345cf800709206502b1f6b6103752a46578e8f553d67bc6e373995327
+ sourceRevisionDigest: sha256:28c9fb69b7ab04edbbe4d9b887d11553e2c4e7d147dd3e1e73fe642a00741d7c
+ sourceBlobDigest: sha256:ef9a1f17fef94059bf6972bd0dd96bff3166a06edf81f9ede3cfca9e47162f59
codeSamplesNamespace: open-router-chat-completions-api-typescript-code-samples
- codeSamplesRevisionDigest: sha256:df5447f18e01ce0c745bf36442e17e092031f31fdf1a3c9d8de2fa52eac174c9
+ codeSamplesRevisionDigest: sha256:9345520320f4dd008b31de30aa45fdb3f47741b5ddef4ec9f8ce8e3b62858bf1
workflow:
workflowVersion: 1.0.0
speakeasyVersion: 1.787.0
diff --git a/RELEASES.md b/RELEASES.md
index ca21e3db6..28294daf2 100644
--- a/RELEASES.md
+++ b/RELEASES.md
@@ -3876,4 +3876,14 @@ Based on:
### Generated
- [typescript v1.3.8] .
### Releases
-- [NPM v1.3.8] https://www.npmjs.com/package/@openrouter/sdk/v/1.3.8 - .
\ No newline at end of file
+- [NPM v1.3.8] https://www.npmjs.com/package/@openrouter/sdk/v/1.3.8 - .
+
+## 2026-09-21 01:08:11
+### Changes
+Based on:
+- OpenAPI Doc
+- Speakeasy CLI 1.787.0 (2.914.0) https://github.com/speakeasy-api/speakeasy
+### Generated
+- [typescript v1.3.9] .
+### Releases
+- [NPM v1.3.9] https://www.npmjs.com/package/@openrouter/sdk/v/1.3.9 - .
\ No newline at end of file
diff --git a/docs/models/errors/internchaterrorresponse.mdx b/docs/models/errors/internchaterrorresponse.mdx
index 74ede0c21..97e17714b 100644
--- a/docs/models/errors/internchaterrorresponse.mdx
+++ b/docs/models/errors/internchaterrorresponse.mdx
@@ -16,4 +16,4 @@ import { InternChatErrorResponse } from "@openrouter/sdk/models/errors";
| Field | Type | Required | Description | Example |
| --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
-| `error` | [models.InternChatError](../../models/internchaterror.mdx) | :heavy_check_mark: | The OpenAI-compatible error object. `metadata` is present on refusals from the chat route. Authentication refusals (`401`), the departed-creator `403` and the programme `404` carry only `code` and `message`. | \{
"code": 409,
"message": "That question is no longer waiting for an answer.",
"metadata": \{
"reason": "interaction_not_pending"
}
} |
\ No newline at end of file
+| `error` | [models.InternChatError](../../models/internchaterror.mdx) | :heavy_check_mark: | The OpenAI-compatible error object. `metadata` is present on refusals from the chat route. Authentication refusals (`401`), the departed-creator `403` and the programme `404` carry only `code` and `message`. | \{
"code": 409,
"message": "That question is no longer waiting for an answer.",
"metadata": \{
"reason": "interaction_not_pending",
"retryable": false
}
} |
\ No newline at end of file
diff --git a/docs/models/internchatcompletionchunk.mdx b/docs/models/internchatcompletionchunk.mdx
index d558a4b08..2ba88694a 100644
--- a/docs/models/internchatcompletionchunk.mdx
+++ b/docs/models/internchatcompletionchunk.mdx
@@ -30,7 +30,7 @@ let value: InternChatCompletionChunk = {
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `choices` | [models.InternChatChoice](../models/internchatchoice.mdx)[] | :heavy_check_mark: | One choice on content, tool-call and error chunks. Empty on the final chunk that carries `session_id`. | |
| `created` | *number* | :heavy_check_mark: | N/A | |
-| `error` | [models.InternChatStreamError](../models/internchatstreamerror.mdx) | :heavy_minus_sign: | A failure after the response headers were sent. The chunk that carries it has `finish_reason: "error"`, then the final empty-`choices` chunk and `[DONE]` follow. Reasons here are `attachment_failed`, `busy`, `client_closed_request`, `interaction_not_pending`, `interaction_unknown`, `intern_unreachable`, `run_ended`, `stream_severed`, `timeout` or `turn_failed`. `run_ended` reports an ending the intern confirmed, such as a cancellation or a deadline, while `stream_severed` reports a connection lost without that confirmation. | \{
"code": 502,
"message": "The intern could not continue this run.",
"metadata": \{
"reason": "attachment_failed"
}
} |
+| `error` | [models.InternChatStreamError](../models/internchatstreamerror.mdx) | :heavy_minus_sign: | A failure after the response headers were sent. The chunk that carries it has `finish_reason: "error"`, then the final empty-`choices` chunk and `[DONE]` follow. Reasons here are `attachment_failed`, `busy`, `client_closed_request`, `interaction_not_pending`, `interaction_unknown`, `intern_unreachable`, `run_ended`, `stream_severed`, `timeout` or `turn_failed`. `run_ended` reports an ending the intern confirmed, such as a cancellation or a deadline, while `stream_severed` reports a connection lost without that confirmation. | \{
"code": 502,
"message": "The intern could not continue this run.",
"metadata": \{
"reason": "attachment_failed",
"retryable": false
}
} |
| `id` | *string* | :heavy_check_mark: | The completion id, constant for the whole response. | chatcmpl-f727571a-3bad-4e0d-8a9e-f18f8cda9750 |
| `model` | *string* | :heavy_check_mark: | The runtime's identifier for the model the intern is running, as the intern reports it. Each chunk carries the model from the event behind it: `openrouter/intern` on chunks emitted before the intern has reported one and on chunks the API emits itself (timeout, run-ended and severed-stream errors and their final usage chunk), even after an earlier chunk named a model. It can change within a stream. It is not an OpenRouter model slug, and the request `model` is never used. | |
| `object` | [models.InternChatCompletionChunkObject](../models/internchatcompletionchunkobject.mdx) | :heavy_check_mark: | N/A | |
diff --git a/docs/models/internchaterror.mdx b/docs/models/internchaterror.mdx
index 7ea3b82db..7707fe274 100644
--- a/docs/models/internchaterror.mdx
+++ b/docs/models/internchaterror.mdx
@@ -21,4 +21,4 @@ let value: InternChatError = {
| ---------------------------------------------------------------------- | ---------------------------------------------------------------------- | ---------------------------------------------------------------------- | ---------------------------------------------------------------------- | ---------------------------------------------------------------------- |
| `code` | *number* | :heavy_check_mark: | The HTTP status of the response. | |
| `message` | *string* | :heavy_check_mark: | N/A | |
-| `metadata` | [models.InternChatErrorMetadata](../models/internchaterrormetadata.mdx) | :heavy_minus_sign: | Machine-readable detail for the failure. | \{
"reason": "interaction_not_pending"
} |
\ No newline at end of file
+| `metadata` | [models.InternChatErrorMetadata](../models/internchaterrormetadata.mdx) | :heavy_minus_sign: | Machine-readable detail for the failure. | \{
"reason": "interaction_not_pending",
"retryable": false
} |
\ No newline at end of file
diff --git a/docs/models/internchaterrormetadata.mdx b/docs/models/internchaterrormetadata.mdx
index b15902672..30f18d2dd 100644
--- a/docs/models/internchaterrormetadata.mdx
+++ b/docs/models/internchaterrormetadata.mdx
@@ -11,11 +11,13 @@ import { InternChatErrorMetadata } from "@openrouter/sdk/models";
let value: InternChatErrorMetadata = {
reason: "interaction_not_pending",
+ retryable: false,
};
```
## Fields
-| Field | Type | Required | Description |
-| ---------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- |
-| `reason` | [models.InternChatErrorMetadataReason](../models/internchaterrormetadatareason.mdx) | :heavy_check_mark: | A stable reason a client can branch on. |
\ No newline at end of file
+| Field | Type | Required | Description |
+| ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
+| `reason` | [models.InternChatErrorMetadataReason](../models/internchaterrormetadatareason.mdx) | :heavy_check_mark: | A stable reason a client can branch on. |
+| `retryable` | *boolean* | :heavy_check_mark: | Whether the same request may be sent again unchanged. Always `true` for the transient refusals — `busy`, `intern_not_ready`, `intern_unreachable`, `rate_limited`, `stream_severed` and `timeout` — and always `false` for the ones a retry cannot fix. For `turn_failed` it varies by failure and is the intern's own classification of what went wrong: `true` for an upstream overload, rate limit, timeout or transport fault, `false` for an authentication or bad-request failure that would be rejected the same way again. Branch on this field rather than on `reason` when deciding whether to retry. A `429`, and a `409` or `503` with reason `busy`, also carry a `Retry-After` header saying how long to wait. |
\ No newline at end of file
diff --git a/docs/models/internchatstreamerror.mdx b/docs/models/internchatstreamerror.mdx
index cac1699bb..c754a9ceb 100644
--- a/docs/models/internchatstreamerror.mdx
+++ b/docs/models/internchatstreamerror.mdx
@@ -14,6 +14,7 @@ let value: InternChatStreamError = {
message: "The intern could not continue this run.",
metadata: {
reason: "attachment_failed",
+ retryable: false,
},
};
```
@@ -24,4 +25,4 @@ let value: InternChatStreamError = {
| ---------------------------------------------------------------------- | ---------------------------------------------------------------------- | ---------------------------------------------------------------------- | ---------------------------------------------------------------------- | ---------------------------------------------------------------------- |
| `code` | *number* | :heavy_check_mark: | The HTTP status this failure would have had before the stream opened. | |
| `message` | *string* | :heavy_check_mark: | N/A | |
-| `metadata` | [models.InternChatErrorMetadata](../models/internchaterrormetadata.mdx) | :heavy_check_mark: | Machine-readable detail for the failure. | \{
"reason": "interaction_not_pending"
} |
\ No newline at end of file
+| `metadata` | [models.InternChatErrorMetadata](../models/internchaterrormetadata.mdx) | :heavy_check_mark: | Machine-readable detail for the failure. | \{
"reason": "interaction_not_pending",
"retryable": false
} |
\ No newline at end of file
diff --git a/docs/models/internlifecycleerrorerror.mdx b/docs/models/internlifecycleerrorerror.mdx
index 9ae4de8c7..41d89dac4 100644
--- a/docs/models/internlifecycleerrorerror.mdx
+++ b/docs/models/internlifecycleerrorerror.mdx
@@ -15,7 +15,8 @@ let value: InternLifecycleErrorError = {
## Fields
-| Field | Type | Required | Description |
-| ------------------ | ------------------ | ------------------ | ------------------ |
-| `code` | *models.Code* | :heavy_check_mark: | N/A |
-| `message` | *string* | :heavy_check_mark: | N/A |
\ No newline at end of file
+| Field | Type | Required | Description |
+| -------------------------------------------------------------------------------- | -------------------------------------------------------------------------------- | -------------------------------------------------------------------------------- | -------------------------------------------------------------------------------- |
+| `code` | *models.Code* | :heavy_check_mark: | N/A |
+| `message` | *string* | :heavy_check_mark: | N/A |
+| `metadata` | [models.InternLifecycleErrorMetadata](../models/internlifecycleerrormetadata.mdx) | :heavy_minus_sign: | N/A |
\ No newline at end of file
diff --git a/docs/models/internlifecycleerrormetadata.mdx b/docs/models/internlifecycleerrormetadata.mdx
new file mode 100644
index 000000000..cedd755fb
--- /dev/null
+++ b/docs/models/internlifecycleerrormetadata.mdx
@@ -0,0 +1,21 @@
+---
+title: "InternLifecycleErrorMetadata"
+---
+
+## Example Usage
+
+```typescript
+import { InternLifecycleErrorMetadata } from "@openrouter/sdk/models";
+
+let value: InternLifecycleErrorMetadata = {
+ reason: "",
+ retryable: false,
+};
+```
+
+## Fields
+
+| Field | Type | Required | Description |
+| ------------------ | ------------------ | ------------------ | ------------------ |
+| `reason` | *string* | :heavy_check_mark: | N/A |
+| `retryable` | *boolean* | :heavy_check_mark: | N/A |
\ No newline at end of file
diff --git a/docs/models/operations/createinternchatcompletionresponse.mdx b/docs/models/operations/createinternchatcompletionresponse.mdx
new file mode 100644
index 000000000..86f2ab6c3
--- /dev/null
+++ b/docs/models/operations/createinternchatcompletionresponse.mdx
@@ -0,0 +1,18 @@
+---
+title: "CreateInternChatCompletionResponse"
+---
+
+## Example Usage
+
+```typescript
+import { CreateInternChatCompletionResponse } from "@openrouter/sdk/models/operations";
+
+// No examples available for this model
+```
+
+## Fields
+
+| Field | Type | Required | Description |
+| ------------------------------------------------- | ------------------------------------------------- | ------------------------------------------------- | ------------------------------------------------- |
+| `headers` | Record\ | :heavy_check_mark: | N/A |
+| `result` | *EventStream\* | :heavy_check_mark: | N/A |
\ No newline at end of file
diff --git a/docs/models/operations/createinternrequest.mdx b/docs/models/operations/createinternrequest.mdx
index fab871c90..01167c665 100644
--- a/docs/models/operations/createinternrequest.mdx
+++ b/docs/models/operations/createinternrequest.mdx
@@ -17,10 +17,10 @@ let value: CreateInternRequest = {
## Fields
-| Field | Type | Required | Description | Example |
-| ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------- |
-| `httpReferer` | *string* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.
This is used to track API usage per application.
| |
-| `appTitle` | *string* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.
| |
-| `appCategories` | *string* | :heavy_minus_sign: | Comma-separated list of app categories (e.g. "cli-agent,cloud-agent"). Used for marketplace rankings.
| |
-| `idempotencyKey` | *string* | :heavy_minus_sign: | Key that makes retries resume the same create operation. Without one, the server derives a stable key from the request body. | create-research-assistant-2026-09-16 |
-| `createInternRequest` | [models.CreateInternRequest](../../models/createinternrequest.mdx) | :heavy_check_mark: | N/A | \{
"name": "research-assistant",
"provision": true,
"workspace_id": "89f9f5b2-3f89-4eaf-83ca-5ceae149e8bb"
} |
\ No newline at end of file
+| Field | Type | Required | Description | Example |
+| -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
+| `httpReferer` | *string* | :heavy_minus_sign: | The app identifier should be your app's URL and is used as the primary identifier for rankings.
This is used to track API usage per application.
| |
+| `appTitle` | *string* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.
| |
+| `appCategories` | *string* | :heavy_minus_sign: | Comma-separated list of app categories (e.g. "cli-agent,cloud-agent"). Used for marketplace rankings.
| |
+| `idempotencyKey` | *string* | :heavy_minus_sign: | Key that makes retries resume the same create operation, from 1 through 255 characters. An empty or longer key is refused with 400. Without the header, the server derives a stable key from the request body. | create-research-assistant-2026-09-16 |
+| `createInternRequest` | [models.CreateInternRequest](../../models/createinternrequest.mdx) | :heavy_check_mark: | N/A | \{
"name": "research-assistant",
"provision": true,
"workspace_id": "89f9f5b2-3f89-4eaf-83ca-5ceae149e8bb"
} |
\ No newline at end of file
diff --git a/docs/models/operations/listinternsrequest.mdx b/docs/models/operations/listinternsrequest.mdx
index 476c6344d..e65454e01 100644
--- a/docs/models/operations/listinternsrequest.mdx
+++ b/docs/models/operations/listinternsrequest.mdx
@@ -18,6 +18,6 @@ let value: ListInternsRequest = {};
| `appTitle` | *string* | :heavy_minus_sign: | The app display name allows you to customize how your app appears in OpenRouter's dashboard.
| |
| `appCategories` | *string* | :heavy_minus_sign: | Comma-separated list of app categories (e.g. "cli-agent,cloud-agent"). Used for marketplace rankings.
| |
| `limit` | *number* | :heavy_minus_sign: | Maximum number of interns to return, from 1 through 500. | 50 |
-| `status` | [operations.Status](../../models/operations/status.mdx)[] | :heavy_minus_sign: | Comma-separated lifecycle statuses to include. | [
"queued",
"running"
] |
+| `status` | [operations.Status](../../models/operations/status.mdx)[] | :heavy_minus_sign: | Comma-separated lifecycle statuses to include, at most 8. Repeats are collapsed. | [
"queued",
"running"
] |
| `startingAfter` | *string* | :heavy_minus_sign: | The opaque `next_cursor` of the previous page. Returns the interns that come after it in the newest-first order. A malformed cursor is a 400. | MjAyNi0wOS0xNlQwODozMDowMC4wMDAwMDBafDdjOWU2Njc5LTc0MjUtNDBkZS05NDRiLWUwN2ZjMWY5MGFlNw |
| `workspaceId` | *string* | :heavy_minus_sign: | Only return interns in this workspace. It must match the API key workspace. | 89f9f5b2-3f89-4eaf-83ca-5ceae149e8bb |
\ No newline at end of file
diff --git a/docs/sdks/interns/README.mdx b/docs/sdks/interns/README.mdx
index bd1a9aec7..6f5a9900f 100644
--- a/docs/sdks/interns/README.mdx
+++ b/docs/sdks/interns/README.mdx
@@ -430,15 +430,15 @@ run();
### Errors
-| Error Type | Status Code | Content Type |
-| ----------------------------- | ----------------------------- | ----------------------------- |
-| errors.InternLifecycleError | 400, 401, 403, 404, 408, 413 | application/json |
-| errors.InternLifecycleError | 500 | application/json |
-| errors.OpenRouterDefaultError | 4XX, 5XX | \*/\* |
+| Error Type | Status Code | Content Type |
+| --------------------------------- | --------------------------------- | --------------------------------- |
+| errors.InternLifecycleError | 400, 401, 403, 404, 408, 409, 413 | application/json |
+| errors.InternLifecycleError | 500 | application/json |
+| errors.OpenRouterDefaultError | 4XX, 5XX | \*/\* |
## provisionIntern
-Starts the first boot, or resumes an intern after suspension. The API key selects the caller, workspace and visible interns. There is no default workspace fallback. Requests on regional hostnames such as `eu.openrouter.ai` are refused. [API key](/docs/api-reference/authentication) required.
+Starts the first boot, or resumes an intern after suspension. This operation takes no request body. A body carrying any field is refused with 400 rather than ignored. The API key selects the caller, workspace and visible interns. There is no default workspace fallback. Requests on regional hostnames such as `eu.openrouter.ai` are refused. [API key](/docs/api-reference/authentication) required.
### Example Usage
@@ -510,15 +510,15 @@ run();
### Errors
-| Error Type | Status Code | Content Type |
-| ----------------------------- | ----------------------------- | ----------------------------- |
-| errors.InternLifecycleError | 401, 403, 404, 408, 409 | application/json |
-| errors.InternLifecycleError | 500, 502 | application/json |
-| errors.OpenRouterDefaultError | 4XX, 5XX | \*/\* |
+| Error Type | Status Code | Content Type |
+| --------------------------------- | --------------------------------- | --------------------------------- |
+| errors.InternLifecycleError | 400, 401, 403, 404, 408, 409, 413 | application/json |
+| errors.InternLifecycleError | 500, 502 | application/json |
+| errors.OpenRouterDefaultError | 4XX, 5XX | \*/\* |
## suspendIntern
-Stops the intern runtime while keeping its disk and configuration for a later provision call. The API key selects the caller, workspace and visible interns. There is no default workspace fallback. Requests on regional hostnames such as `eu.openrouter.ai` are refused. [API key](/docs/api-reference/authentication) required.
+Stops the intern runtime while keeping its disk and configuration for a later provision call. This operation takes no request body. A body carrying any field is refused with 400 rather than ignored. The API key selects the caller, workspace and visible interns. There is no default workspace fallback. Requests on regional hostnames such as `eu.openrouter.ai` are refused. [API key](/docs/api-reference/authentication) required.
### Example Usage
@@ -590,11 +590,11 @@ run();
### Errors
-| Error Type | Status Code | Content Type |
-| ----------------------------- | ----------------------------- | ----------------------------- |
-| errors.InternLifecycleError | 401, 403, 404, 408, 409 | application/json |
-| errors.InternLifecycleError | 500, 502 | application/json |
-| errors.OpenRouterDefaultError | 4XX, 5XX | \*/\* |
+| Error Type | Status Code | Content Type |
+| --------------------------------- | --------------------------------- | --------------------------------- |
+| errors.InternLifecycleError | 400, 401, 403, 404, 408, 409, 413 | application/json |
+| errors.InternLifecycleError | 500, 502 | application/json |
+| errors.OpenRouterDefaultError | 4XX, 5XX | \*/\* |
## chat
@@ -702,12 +702,14 @@ run();
### Response
-**Promise\<[EventStream\](../../models/.mdx)\>**
+**Promise\<[operations.CreateInternChatCompletionResponse](../../models/operations/createinternchatcompletionresponse.mdx)\>**
### Errors
-| Error Type | Status Code | Content Type |
-| -------------------------------------- | -------------------------------------- | -------------------------------------- |
-| errors.InternChatErrorResponse | 400, 401, 403, 404, 409, 410, 413, 429 | application/json |
-| errors.InternChatErrorResponse | 502, 503, 504 | application/json |
-| errors.OpenRouterDefaultError | 4XX, 5XX | \*/\* |
\ No newline at end of file
+| Error Type | Status Code | Content Type |
+| --------------------------------- | --------------------------------- | --------------------------------- |
+| errors.InternChatErrorResponse | 400, 401, 403, 404, 408, 410, 413 | application/json |
+| errors.InternChatErrorResponse | 409, 429 | application/json |
+| errors.InternChatErrorResponse | 503 | application/json |
+| errors.InternChatErrorResponse | 502, 504 | application/json |
+| errors.OpenRouterDefaultError | 4XX, 5XX | \*/\* |
\ No newline at end of file
diff --git a/jsr.json b/jsr.json
index be3e0babc..9bbc05101 100644
--- a/jsr.json
+++ b/jsr.json
@@ -2,7 +2,7 @@
{
"name": "@openrouter/sdk",
- "version": "1.3.8",
+ "version": "1.3.9",
"exports": {
".": "./src/index.ts",
"./models/errors": "./src/models/errors/index.ts",
diff --git a/package.json b/package.json
index d5c362659..1ad3d434e 100644
--- a/package.json
+++ b/package.json
@@ -1,6 +1,6 @@
{
"name": "@openrouter/sdk",
- "version": "1.3.8",
+ "version": "1.3.9",
"author": "OpenRouter",
"description": "The OpenRouter TypeScript SDK is a type-safe toolkit for building AI applications with access to 400+ language models through a unified API.",
"keywords": [
@@ -75,13 +75,13 @@
"prepublishOnly": "npm run build",
"compile": "tsc",
"postinstall": "node scripts/check-types.js || true",
- "test": "vitest --run --project unit",
"test:e2e": "vitest --run --project e2e",
"test:watch": "vitest --watch --project unit",
+ "typecheck:transit": "exit 0",
"prepare": "npm run build",
+ "test": "vitest --run --project unit",
"test:transit": "exit 0",
- "typecheck": "tsc --noEmit",
- "typecheck:transit": "exit 0"
+ "typecheck": "tsc --noEmit"
},
"peerDependencies": {},
"devDependencies": {
diff --git a/src/funcs/internsChat.ts b/src/funcs/internsChat.ts
index bcd4742cb..e24ddf38b 100644
--- a/src/funcs/internsChat.ts
+++ b/src/funcs/internsChat.ts
@@ -3,10 +3,8 @@
* @generated-id: 36149dc7ea8d
*/
-import * as z from "zod/v4";
import { OpenRouterCore } from "../core.js";
import { encodeJSON, encodeSimple } from "../lib/encodings.js";
-import { EventStream } from "../lib/event-streams.js";
import { matchStatusCode } from "../lib/http.js";
import * as M from "../lib/matchers.js";
import { compactMap } from "../lib/primitives.js";
@@ -25,7 +23,6 @@ import * as errors from "../models/errors/index.js";
import { OpenRouterError } from "../models/errors/openroutererror.js";
import { ResponseValidationError } from "../models/errors/responsevalidationerror.js";
import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
-import * as models from "../models/index.js";
import * as operations from "../models/operations/index.js";
import { APICall, APIPromise } from "../types/async.js";
import { Result } from "../types/fp.js";
@@ -56,7 +53,7 @@ export function internsChat(
options?: RequestOptions,
): APIPromise<
Result<
- EventStream,
+ operations.CreateInternChatCompletionResponse,
| errors.InternChatErrorResponse
| OpenRouterError
| ResponseValidationError
@@ -82,7 +79,7 @@ async function $do(
): Promise<
[
Result<
- EventStream,
+ operations.CreateInternChatCompletionResponse,
| errors.InternChatErrorResponse
| OpenRouterError
| ResponseValidationError
@@ -199,7 +196,7 @@ async function $do(
};
const [result] = await M.match<
- EventStream,
+ operations.CreateInternChatCompletionResponse,
| errors.InternChatErrorResponse
| OpenRouterError
| ResponseValidationError
@@ -210,28 +207,20 @@ async function $do(
| UnexpectedClientError
| SDKValidationError
>(
- M.sse(
- 200,
- z.custom>(x => x instanceof ReadableStream)
- .transform(stream => {
- return new EventStream(stream, rawEvent => {
- if (rawEvent.data === "[DONE]") {
- return { done: true, value: undefined };
- }
- return {
- done: false,
- value: models.InternChatStreamingResponse$inboundSchema.parse(
- rawEvent,
- )?.data,
- };
- });
- }),
- ),
+ M.sse(200, operations.CreateInternChatCompletionResponse$inboundSchema, {
+ key: "Result",
+ }),
M.jsonErr(
- [400, 401, 403, 404, 409, 410, 413, 429],
+ [400, 401, 403, 404, 408, 410, 413],
errors.InternChatErrorResponse$inboundSchema,
),
- M.jsonErr([502, 503, 504], errors.InternChatErrorResponse$inboundSchema),
+ M.jsonErr([409, 429], errors.InternChatErrorResponse$inboundSchema, {
+ hdrs: true,
+ }),
+ M.jsonErr(503, errors.InternChatErrorResponse$inboundSchema, {
+ hdrs: true,
+ }),
+ M.jsonErr([502, 504], errors.InternChatErrorResponse$inboundSchema),
M.fail("4XX"),
M.fail("5XX"),
)(response, req, { extraFields: responseFields });
diff --git a/src/funcs/internsProvisionIntern.ts b/src/funcs/internsProvisionIntern.ts
index 45ccd2e1b..adb6b70af 100644
--- a/src/funcs/internsProvisionIntern.ts
+++ b/src/funcs/internsProvisionIntern.ts
@@ -32,7 +32,7 @@ import { Result } from "../types/fp.js";
* Provision an intern
*
* @remarks
- * Starts the first boot, or resumes an intern after suspension. The API key selects the caller, workspace and visible interns. There is no default workspace fallback. Requests on regional hostnames such as `eu.openrouter.ai` are refused. [API key](/docs/api-reference/authentication) required.
+ * Starts the first boot, or resumes an intern after suspension. This operation takes no request body. A body carrying any field is refused with 400 rather than ignored. The API key selects the caller, workspace and visible interns. There is no default workspace fallback. Requests on regional hostnames such as `eu.openrouter.ai` are refused. [API key](/docs/api-reference/authentication) required.
*
* If set, this operation will use {@link Security.apiKey} from the global security.
*/
@@ -194,7 +194,7 @@ async function $do(
>(
M.json(202, models.ProvisionInternResponse$inboundSchema),
M.jsonErr(
- [401, 403, 404, 408, 409],
+ [400, 401, 403, 404, 408, 409, 413],
errors.InternLifecycleError$inboundSchema,
),
M.jsonErr([500, 502], errors.InternLifecycleError$inboundSchema),
diff --git a/src/funcs/internsSuspendIntern.ts b/src/funcs/internsSuspendIntern.ts
index f24513707..51d4e415c 100644
--- a/src/funcs/internsSuspendIntern.ts
+++ b/src/funcs/internsSuspendIntern.ts
@@ -32,7 +32,7 @@ import { Result } from "../types/fp.js";
* Suspend an intern
*
* @remarks
- * Stops the intern runtime while keeping its disk and configuration for a later provision call. The API key selects the caller, workspace and visible interns. There is no default workspace fallback. Requests on regional hostnames such as `eu.openrouter.ai` are refused. [API key](/docs/api-reference/authentication) required.
+ * Stops the intern runtime while keeping its disk and configuration for a later provision call. This operation takes no request body. A body carrying any field is refused with 400 rather than ignored. The API key selects the caller, workspace and visible interns. There is no default workspace fallback. Requests on regional hostnames such as `eu.openrouter.ai` are refused. [API key](/docs/api-reference/authentication) required.
*
* If set, this operation will use {@link Security.apiKey} from the global security.
*/
@@ -194,7 +194,7 @@ async function $do(
>(
M.json(200, models.SuspendInternResponse$inboundSchema),
M.jsonErr(
- [401, 403, 404, 408, 409],
+ [400, 401, 403, 404, 408, 409, 413],
errors.InternLifecycleError$inboundSchema,
),
M.jsonErr([500, 502], errors.InternLifecycleError$inboundSchema),
diff --git a/src/funcs/internsUpdateIntern.ts b/src/funcs/internsUpdateIntern.ts
index dbaceeac6..d22be9b1e 100644
--- a/src/funcs/internsUpdateIntern.ts
+++ b/src/funcs/internsUpdateIntern.ts
@@ -197,7 +197,7 @@ async function $do(
>(
M.json(200, models.Intern$inboundSchema),
M.jsonErr(
- [400, 401, 403, 404, 408, 413],
+ [400, 401, 403, 404, 408, 409, 413],
errors.InternLifecycleError$inboundSchema,
),
M.jsonErr(500, errors.InternLifecycleError$inboundSchema),
diff --git a/src/lib/config.ts b/src/lib/config.ts
index 304ed1e51..8a4266d25 100644
--- a/src/lib/config.ts
+++ b/src/lib/config.ts
@@ -79,7 +79,7 @@ export function serverURLFromOptions(options: SDKOptions): URL | null {
export const SDK_METADATA = {
language: "typescript",
openapiDocVersion: "1.0.0",
- sdkVersion: "1.3.8",
+ sdkVersion: "1.3.9",
genVersion: "2.914.0",
- userAgent: "speakeasy-sdk/typescript 1.3.8 2.914.0 1.0.0 @openrouter/sdk",
+ userAgent: "speakeasy-sdk/typescript 1.3.9 2.914.0 1.0.0 @openrouter/sdk",
} as const;
diff --git a/src/models/internchaterrormetadata.ts b/src/models/internchaterrormetadata.ts
index 5025da6ca..f1ad7371f 100644
--- a/src/models/internchaterrormetadata.ts
+++ b/src/models/internchaterrormetadata.ts
@@ -46,6 +46,10 @@ export type InternChatErrorMetadata = {
* A stable reason a client can branch on.
*/
reason: InternChatErrorMetadataReason;
+ /**
+ * Whether the same request may be sent again unchanged. Always `true` for the transient refusals — `busy`, `intern_not_ready`, `intern_unreachable`, `rate_limited`, `stream_severed` and `timeout` — and always `false` for the ones a retry cannot fix. For `turn_failed` it varies by failure and is the intern's own classification of what went wrong: `true` for an upstream overload, rate limit, timeout or transport fault, `false` for an authentication or bad-request failure that would be rejected the same way again. Branch on this field rather than on `reason` when deciding whether to retry. A `429`, and a `409` or `503` with reason `busy`, also carry a `Retry-After` header saying how long to wait.
+ */
+ retryable: boolean;
};
/** @internal */
@@ -60,6 +64,7 @@ export const InternChatErrorMetadata$inboundSchema: z.ZodType<
unknown
> = z.object({
reason: InternChatErrorMetadataReason$inboundSchema,
+ retryable: z.boolean(),
});
export function internChatErrorMetadataFromJSON(
diff --git a/src/models/internlifecycleerror.ts b/src/models/internlifecycleerror.ts
index 03b583846..a65e488c5 100644
--- a/src/models/internlifecycleerror.ts
+++ b/src/models/internlifecycleerror.ts
@@ -10,9 +10,15 @@ import { SDKValidationError } from "./errors/sdkvalidationerror.js";
export type Code = string | number;
+export type InternLifecycleErrorMetadata = {
+ reason: string;
+ retryable: boolean;
+};
+
export type InternLifecycleErrorError = {
code: string | number;
message: string;
+ metadata?: InternLifecycleErrorMetadata | undefined;
};
/** @internal */
@@ -31,6 +37,25 @@ export function codeFromJSON(
);
}
+/** @internal */
+export const InternLifecycleErrorMetadata$inboundSchema: z.ZodType<
+ InternLifecycleErrorMetadata,
+ unknown
+> = z.object({
+ reason: z.string(),
+ retryable: z.boolean(),
+});
+
+export function internLifecycleErrorMetadataFromJSON(
+ jsonString: string,
+): SafeParseResult {
+ return safeParse(
+ jsonString,
+ (x) => InternLifecycleErrorMetadata$inboundSchema.parse(JSON.parse(x)),
+ `Failed to parse 'InternLifecycleErrorMetadata' from JSON`,
+ );
+}
+
/** @internal */
export const InternLifecycleErrorError$inboundSchema: z.ZodType<
InternLifecycleErrorError,
@@ -38,6 +63,7 @@ export const InternLifecycleErrorError$inboundSchema: z.ZodType<
> = z.object({
code: z.union([z.string(), z.int()]),
message: z.string(),
+ metadata: z.lazy(() => InternLifecycleErrorMetadata$inboundSchema).optional(),
});
export function internLifecycleErrorErrorFromJSON(
diff --git a/src/models/operations/createintern.ts b/src/models/operations/createintern.ts
index b4ced13db..1b89a6c6f 100644
--- a/src/models/operations/createintern.ts
+++ b/src/models/operations/createintern.ts
@@ -50,7 +50,7 @@ export type CreateInternRequest = {
*/
appCategories?: string | undefined;
/**
- * Key that makes retries resume the same create operation. Without one, the server derives a stable key from the request body.
+ * Key that makes retries resume the same create operation, from 1 through 255 characters. An empty or longer key is refused with 400. Without the header, the server derives a stable key from the request body.
*/
idempotencyKey?: string | undefined;
createInternRequest: models.CreateInternRequest;
diff --git a/src/models/operations/createinternchatcompletion.ts b/src/models/operations/createinternchatcompletion.ts
index 310ac2ef4..17bc0b3d7 100644
--- a/src/models/operations/createinternchatcompletion.ts
+++ b/src/models/operations/createinternchatcompletion.ts
@@ -4,7 +4,11 @@
*/
import * as z from "zod/v4";
+import { EventStream } from "../../lib/event-streams.js";
import { remap as remap$ } from "../../lib/primitives.js";
+import { safeParse } from "../../lib/schemas.js";
+import { Result as SafeParseResult } from "../../types/fp.js";
+import { SDKValidationError } from "../errors/sdkvalidationerror.js";
import * as models from "../index.js";
export type CreateInternChatCompletionGlobals = {
@@ -56,6 +60,11 @@ export type CreateInternChatCompletionRequest = {
internChatCompletionRequest: models.InternChatCompletionRequest;
};
+export type CreateInternChatCompletionResponse = {
+ headers: { [k: string]: Array };
+ result: EventStream;
+};
+
/** @internal */
export type CreateInternChatCompletionRequest$Outbound = {
"HTTP-Referer"?: string | undefined;
@@ -92,3 +101,39 @@ export function createInternChatCompletionRequestToJSON(
),
);
}
+
+/** @internal */
+export const CreateInternChatCompletionResponse$inboundSchema: z.ZodType<
+ CreateInternChatCompletionResponse,
+ unknown
+> = z.object({
+ Headers: z.record(z.string(), z.array(z.string())).default({}),
+ Result: z.custom>(x => x instanceof ReadableStream)
+ .transform(stream => {
+ return new EventStream(stream, rawEvent => {
+ if (rawEvent.data === "[DONE]") return { done: true, value: undefined };
+ return {
+ done: false,
+ value: models.InternChatStreamingResponse$inboundSchema.parse(
+ rawEvent,
+ )?.data,
+ };
+ });
+ }),
+}).transform((v) => {
+ return remap$(v, {
+ "Headers": "headers",
+ "Result": "result",
+ });
+});
+
+export function createInternChatCompletionResponseFromJSON(
+ jsonString: string,
+): SafeParseResult {
+ return safeParse(
+ jsonString,
+ (x) =>
+ CreateInternChatCompletionResponse$inboundSchema.parse(JSON.parse(x)),
+ `Failed to parse 'CreateInternChatCompletionResponse' from JSON`,
+ );
+}
diff --git a/src/models/operations/listinterns.ts b/src/models/operations/listinterns.ts
index ad3509ebe..688a9eba8 100644
--- a/src/models/operations/listinterns.ts
+++ b/src/models/operations/listinterns.ts
@@ -67,7 +67,7 @@ export type ListInternsRequest = {
*/
limit?: number | undefined;
/**
- * Comma-separated lifecycle statuses to include.
+ * Comma-separated lifecycle statuses to include, at most 8. Repeats are collapsed.
*/
status?: Array | undefined;
/**
diff --git a/src/sdk/interns.ts b/src/sdk/interns.ts
index 486223a71..c4df57e43 100644
--- a/src/sdk/interns.ts
+++ b/src/sdk/interns.ts
@@ -11,7 +11,6 @@ import { internsListInterns } from "../funcs/internsListInterns.js";
import { internsProvisionIntern } from "../funcs/internsProvisionIntern.js";
import { internsSuspendIntern } from "../funcs/internsSuspendIntern.js";
import { internsUpdateIntern } from "../funcs/internsUpdateIntern.js";
-import { EventStream } from "../lib/event-streams.js";
import { ClientSDK, RequestOptions } from "../lib/sdks.js";
import * as models from "../models/index.js";
import * as operations from "../models/operations/index.js";
@@ -107,7 +106,7 @@ export class Interns extends ClientSDK {
* Provision an intern
*
* @remarks
- * Starts the first boot, or resumes an intern after suspension. The API key selects the caller, workspace and visible interns. There is no default workspace fallback. Requests on regional hostnames such as `eu.openrouter.ai` are refused. [API key](/docs/api-reference/authentication) required.
+ * Starts the first boot, or resumes an intern after suspension. This operation takes no request body. A body carrying any field is refused with 400 rather than ignored. The API key selects the caller, workspace and visible interns. There is no default workspace fallback. Requests on regional hostnames such as `eu.openrouter.ai` are refused. [API key](/docs/api-reference/authentication) required.
*/
async provisionIntern(
request: operations.ProvisionInternRequest,
@@ -124,7 +123,7 @@ export class Interns extends ClientSDK {
* Suspend an intern
*
* @remarks
- * Stops the intern runtime while keeping its disk and configuration for a later provision call. The API key selects the caller, workspace and visible interns. There is no default workspace fallback. Requests on regional hostnames such as `eu.openrouter.ai` are refused. [API key](/docs/api-reference/authentication) required.
+ * Stops the intern runtime while keeping its disk and configuration for a later provision call. This operation takes no request body. A body carrying any field is refused with 400 rather than ignored. The API key selects the caller, workspace and visible interns. There is no default workspace fallback. Requests on regional hostnames such as `eu.openrouter.ai` are refused. [API key](/docs/api-reference/authentication) required.
*/
async suspendIntern(
request: operations.SuspendInternRequest,
@@ -158,7 +157,7 @@ export class Interns extends ClientSDK {
async chat(
request: operations.CreateInternChatCompletionRequest,
options?: RequestOptions,
- ): Promise> {
+ ): Promise {
return unwrapAsync(internsChat(
this,
request,