Skip to content

Commit 190f718

Browse files
author
OpenRouter SDK Bot
committed
chore: update OpenAPI spec [sdk-bot]
1 parent 182e95d commit 190f718

1 file changed

Lines changed: 48 additions & 7 deletions

File tree

‎.speakeasy/in.openapi.yaml‎

Lines changed: 48 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -8523,6 +8523,17 @@ components:
85238523
required:
85248524
- 'deleted'
85258525
type: 'object'
8526+
DeleteInternRequest:
8527+
additionalProperties: false
8528+
description: 'Optional consent for a teardown that discards the workspace.'
8529+
example:
8530+
acknowledge_workspace_loss: true
8531+
properties:
8532+
acknowledge_workspace_loss:
8533+
default: false
8534+
description: 'Delete even though the workspace backup was not confirmed. Defaults to false, which refuses the teardown when a workspace archive is missing.'
8535+
type: 'boolean'
8536+
type: 'object'
85268537
DeleteInternResponse:
85278538
additionalProperties: false
85288539
properties:
@@ -12497,14 +12508,14 @@ components:
1249712508
example: 'chatcmpl-f727571a-3bad-4e0d-8a9e-f18f8cda9750'
1249812509
type: 'string'
1249912510
model:
12500-
description: 'The request `model` when given, or `openrouter/intern`. The final chunk may carry the model the intern reported for the run instead.'
12511+
description: '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.'
1250112512
type: 'string'
1250212513
object:
1250312514
enum:
1250412515
- 'chat.completion.chunk'
1250512516
type: 'string'
1250612517
session_id:
12507-
description: 'On the final chunk of every response, the daemon session to continue with, or `null` when the run failed before the intern reported one. Send it as `session_id` on the next request, including the `tool` reply to an interaction.'
12518+
description: 'On the final chunk of every response, the daemon session to continue with, or `null` when the run failed before the intern reported one. Send it as `session_id` on the next request, including the `tool` reply to an interaction. Session ids are client-visible and scoped to the intern''s own daemon.'
1250812519
example: 'ses_7f3c9a'
1250912520
type:
1251012521
- 'string'
@@ -12536,20 +12547,20 @@ components:
1253612547
minItems: 1
1253712548
type: 'array'
1253812549
model:
12539-
description: 'Accepted for OpenAI compatibility and ignored. Streamed chunks report the model the intern actually used, or `openrouter/intern` when it did not report one.'
12550+
description: 'Accepted for OpenAI compatibility and never used. The intern runs the model configured on it (`PATCH` the intern to change it). Streamed chunks report the runtime''s identifier for that model as the intern reports it, or `openrouter/intern` on chunks whose event carries no model (before the intern reports one, and on the chunks the API emits itself: the timeout, run-ended and severed-stream error chunks, the stop chunk of a replay that ends without a terminal daemon event, and the final usage chunk after any of them). A usage chunk that follows a daemon completion event carries the model the intern reported.'
1254012551
example: 'openrouter/intern'
1254112552
maxLength: 256
1254212553
minLength: 1
1254312554
type: 'string'
1254412555
session_id:
12545-
description: 'The daemon session to continue, as returned in `session_id` on the final chunk of an earlier response. Omit it to start a new session. Required when the last message has role `tool`.'
12556+
description: 'The daemon session to continue, as returned in `session_id` on the final chunk of an earlier response. Omit it to start a new session. An id the intern has not seen before is not an error: it starts a new session under that id, so a mistyped id forks the conversation. Sessions are scoped to the intern''s own daemon. Required when the last message has role `tool`.'
1254612557
example: 'ses_7f3c9a'
1254712558
maxLength: 256
1254812559
minLength: 1
1254912560
type: 'string'
1255012561
stream:
1255112562
const: true
12552-
description: 'Must be `true`. This endpoint only streams.'
12563+
description: 'Must be `true`. This endpoint only streams. `false` or an omitted `stream` is refused with `400` and reason `bad_request`.'
1255312564
example: true
1255412565
type: 'boolean'
1255512566
required:
@@ -27809,8 +27820,10 @@ components:
2780927820
- 'string'
2781027821
- 'null'
2781127822
model:
27812-
description: 'New OpenRouter model slug. Null restores the workspace default.'
27823+
description: 'New OpenRouter model slug in `author/slug` form (an optional `:variant` suffix is accepted). Other shapes are refused with 400. Null restores the workspace default. Takes effect on the next provision: until then `GET` shows this configured model while chat chunks show the model the running intern reports.'
2781327824
maxLength: 200
27825+
minLength: 1
27826+
pattern: '^[A-Za-z0-9~._:@+-]+\/[A-Za-z0-9~._:@+-]+$'
2781427827
type:
2781527828
- 'string'
2781627829
- 'null'
@@ -36205,7 +36218,7 @@ paths:
3620536218
- 'Interns'
3620636219
/interns/{internId}:
3620736220
delete:
36208-
description: 'Starts safe teardown of the intern, its runtime and its private vault. 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.'
36221+
description: 'Starts safe teardown of the intern, its runtime and its private vault. The body is optional. Send `{"acknowledge_workspace_loss": true}` to delete a `destroy_failed` intern whose `last_failure_message` names `workspace_archive_failed`, accepting that its workspace is not backed up. 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.'
3620936222
operationId: 'deleteIntern'
3621036223
parameters:
3621136224
- description: 'ID of an intern visible to the authenticated API key.'
@@ -36217,6 +36230,14 @@ paths:
3621736230
example: '7c9e6679-7425-40de-944b-e07fc1f90ae7'
3621836231
minLength: 1
3621936232
type: 'string'
36233+
requestBody:
36234+
content:
36235+
application/json:
36236+
example:
36237+
acknowledge_workspace_loss: true
36238+
schema:
36239+
$ref: '#/components/schemas/DeleteInternRequest'
36240+
required: true
3622036241
responses:
3622136242
'202':
3622236243
content:
@@ -36226,6 +36247,16 @@ paths:
3622636247
schema:
3622736248
$ref: '#/components/schemas/DeleteInternResponse'
3622836249
description: 'The operation was accepted.'
36250+
'400':
36251+
content:
36252+
application/json:
36253+
example:
36254+
error:
36255+
code: 'invalid_body'
36256+
message: 'Invalid request body'
36257+
schema:
36258+
$ref: '#/components/schemas/InternLifecycleError'
36259+
description: 'The request body is invalid.'
3622936260
'401':
3623036261
content:
3623136262
application/json:
@@ -36276,6 +36307,16 @@ paths:
3627636307
schema:
3627736308
$ref: '#/components/schemas/InternLifecycleError'
3627836309
description: 'The intern is not in a state that allows this operation.'
36310+
'413':
36311+
content:
36312+
application/json:
36313+
example:
36314+
error:
36315+
code: 'payload_too_large'
36316+
message: 'Request body exceeds 1048576 bytes'
36317+
schema:
36318+
$ref: '#/components/schemas/InternLifecycleError'
36319+
description: 'The request body is larger than 1048576 bytes.'
3627936320
'500':
3628036321
content:
3628136322
application/json:

0 commit comments

Comments
 (0)