@labelbox/recursion-sdk 0.0.166 → 0.0.168

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -44872,7 +44872,7 @@ export const SDK_REFERENCE = {
44872
44872
  cliExample: "rl managed-agents create-agent \\\n --name 'example-name' \\\n --system 'example' \\\n --from-json body.json",
44873
44873
  curlExample: 'curl -X POST \'https://api.recursion.labelbox.com/managed-agents/v1/agents\' \\\n -H \'Authorization: Bearer $LABELBOX_API_KEY\' \\\n -H \'Content-Type: application/json\' \\\n -d \'{\n "custom_tools": [\n {\n "config": {\n "key": "example"\n },\n "name": "example-name",\n "type": "example"\n }\n ],\n "default_credential_refs": [\n {\n "credential_id": "9f8b1c2d-3e4f-5a6b-7c8d-9e0f1a2b3c4d",\n "vault_id": "9f8b1c2d-3e4f-5a6b-7c8d-9e0f1a2b3c4d"\n }\n ],\n "default_rubric": "example",\n "default_vault_ids": [\n "example"\n ],\n "description": "example",\n "mcp_servers": [\n {\n "key": "example"\n }\n ],\n "metadata": {\n "key": "example"\n },\n "model": "example",\n "model_config": {\n "max_tokens": 1,\n "provider_params": {\n "key": "example"\n },\n "reasoning_effort": "example",\n "response_format": "example",\n "temperature": 1.5,\n "tool_choice": "example",\n "top_p": 1.5\n },\n "model_ref_id": "9f8b1c2d-3e4f-5a6b-7c8d-9e0f1a2b3c4d",\n "multiagent": {\n "key": "example"\n },\n "name": "example-name",\n "runtime_adapters": [\n {\n "key": "example"\n }\n ],\n "skills": [\n {\n "key": "example"\n }\n ],\n "system": "example",\n "tools": [\n {\n "config": {\n "key": "example"\n },\n "name": "example-name",\n "type": "example"\n }\n ],\n "toolsets": [\n {\n "config": {\n "key": "example"\n },\n "name": "example-name",\n "type": "example"\n }\n ],\n "web_search_enabled": true\n }\'',
44874
44874
  summary: 'Create an agent and immutable version',
44875
- description: 'Creates an agent and its first immutable version, and returns the agent resolved to that version. Exactly one of model or model_ref_id is required alongside name and system. The body is also accepted as application/x-yaml with the same schema. Any vault named in default_vault_ids must already exist.',
44875
+ description: 'Creates an agent and its first immutable version, and returns the agent resolved to that version. Exactly one of model or model_ref_id is required alongside name and system. The body is also accepted as application/x-yaml with the same schema. Any vault named in default_vault_ids must already exist. Invalid model_config and unsupported reasoning_effort values return 400, including when a reachable gateway model publishes no exact options; an unconfigured or unreachable gateway that prevents verification returns 503.',
44876
44876
  httpMethod: 'post',
44877
44877
  path: '/managed-agents/v1/agents',
44878
44878
  requiredPermissions: ['managed-agents:create'],
@@ -44980,7 +44980,7 @@ export const SDK_REFERENCE = {
44980
44980
  in: 'body',
44981
44981
  required: false,
44982
44982
  type: 'ManagedAgentsInferenceConfig',
44983
- description: 'Default inference config applied to sessions started from this agent.',
44983
+ description: "Default inference config applied to sessions started from this agent. Omit model_config or send {} to use provider defaults; null is invalid. reasoning_effort is normalized and validated for direct providers, and must exactly match the selected gateway model's published options. An unsupported value, including a reachable gateway model that publishes no exact options, returns 400; an unconfigured or unreachable gateway that prevents verification returns 503.",
44984
44984
  fields: [
44985
44985
  {
44986
44986
  name: 'max_tokens',
@@ -44999,7 +44999,7 @@ export const SDK_REFERENCE = {
44999
44999
  name: 'reasoning_effort',
45000
45000
  required: false,
45001
45001
  type: 'string',
45002
- description: 'Thinking-budget hint for reasoning-capable models, e.g. low, medium, or high. Ignored by models that do not support reasoning.',
45002
+ description: "Provider-native reasoning depth value. For gateway models, use one of supported_reasoning_efforts from the models catalog; omit it to follow the provider's current default.",
45003
45003
  },
45004
45004
  {
45005
45005
  name: 'response_format',
@@ -45234,7 +45234,7 @@ export const SDK_REFERENCE = {
45234
45234
  name: 'reasoning_effort',
45235
45235
  required: false,
45236
45236
  type: 'string',
45237
- description: 'Thinking-budget hint for reasoning-capable models, e.g. low, medium, or high. Ignored by models that do not support reasoning.',
45237
+ description: "Provider-native reasoning depth value. For gateway models, use one of supported_reasoning_efforts from the models catalog; omit it to follow the provider's current default.",
45238
45238
  },
45239
45239
  {
45240
45240
  name: 'response_format',
@@ -48639,7 +48639,7 @@ export const SDK_REFERENCE = {
48639
48639
  name: 'reasoning_effort',
48640
48640
  required: false,
48641
48641
  type: 'string',
48642
- description: 'Thinking-budget hint for reasoning-capable models, e.g. low, medium, or high. Ignored by models that do not support reasoning.',
48642
+ description: "Provider-native reasoning depth value. For gateway models, use one of supported_reasoning_efforts from the models catalog; omit it to follow the provider's current default.",
48643
48643
  },
48644
48644
  {
48645
48645
  name: 'response_format',
@@ -49025,7 +49025,7 @@ export const SDK_REFERENCE = {
49025
49025
  name: 'reasoning_effort',
49026
49026
  required: false,
49027
49027
  type: 'string',
49028
- description: 'Thinking-budget hint for reasoning-capable models, e.g. low, medium, or high. Ignored by models that do not support reasoning.',
49028
+ description: "Provider-native reasoning depth value. For gateway models, use one of supported_reasoning_efforts from the models catalog; omit it to follow the provider's current default.",
49029
49029
  },
49030
49030
  {
49031
49031
  name: 'response_format',
@@ -51421,6 +51421,69 @@ export const SDK_REFERENCE = {
51421
51421
  ],
51422
51422
  },
51423
51423
  },
51424
+ managedAgentsGetSessionBudget: {
51425
+ operationId: 'managedAgentsGetSessionBudget',
51426
+ tag: 'managed-agents',
51427
+ callPath: ['managedAgents', 'getSessionBudget'],
51428
+ namespace: 'managedAgents',
51429
+ method: 'getSessionBudget',
51430
+ signature: 'rl.managedAgents.getSessionBudget({ session_id })',
51431
+ example: "const result = await rl.managedAgents.getSessionBudget({\n session_id: '<session_id>',\n});",
51432
+ cliInvocation: 'rl managed-agents get-session-budget',
51433
+ cliExample: 'rl managed-agents get-session-budget \\\n --session_id <session_id>',
51434
+ curlExample: "curl -X GET 'https://api.recursion.labelbox.com/managed-agents/v1/sessions/<session_id>/budget' \\\n -H 'Authorization: Bearer $LABELBOX_API_KEY'",
51435
+ summary: "Get the session tree's model-cost cap",
51436
+ description: "Returns the cost cap the session's tree runs under and how much of it is spent. Any session in the tree may be named; the cap belongs to the root. A tree whose agent declared no multiagent.limits.max_tree_cost_usd and was never given a cap here has no budget and answers 404.",
51437
+ httpMethod: 'get',
51438
+ path: '/managed-agents/v1/sessions/{session_id}/budget',
51439
+ requiredPermissions: ['managed-agents:read'],
51440
+ params: [
51441
+ {
51442
+ name: 'session_id',
51443
+ in: 'path',
51444
+ required: true,
51445
+ type: 'string',
51446
+ description: 'Session id (UUID) as returned by startSession or listSessions.',
51447
+ format: 'uuid',
51448
+ },
51449
+ ],
51450
+ response: {
51451
+ type: 'ManagedAgentsSessionBudgetResponse',
51452
+ description: 'The model-cost cap of one session tree and how much of it is spent. The cap is enforced between model requests, never mid-request, so the overshoot is bounded by one request per running session.',
51453
+ fields: [
51454
+ {
51455
+ name: 'consumed_cost_usd',
51456
+ required: false,
51457
+ type: 'string',
51458
+ description: 'Model cost the tree has been charged so far, as a decimal USD string, maintained as charges land.',
51459
+ },
51460
+ {
51461
+ name: 'exhausted',
51462
+ required: false,
51463
+ type: 'boolean',
51464
+ description: 'True when consumed cost has reached the cap. Sessions in the tree stop with stop_reason budget_reached at their next turn boundary and stay idle until the cap is raised.',
51465
+ },
51466
+ {
51467
+ name: 'max_tree_cost_usd',
51468
+ required: false,
51469
+ type: 'string',
51470
+ description: 'The cap as a decimal USD string. Absent when the budget row carries no cost cap.',
51471
+ },
51472
+ {
51473
+ name: 'resumed_session_ids',
51474
+ required: false,
51475
+ type: 'string[]',
51476
+ description: 'On a write, the sessions that had stopped at the old cap and were sent a resume message because the new cap leaves room. Absent on a read, and when nothing was waiting.',
51477
+ },
51478
+ {
51479
+ name: 'root_session_id',
51480
+ required: false,
51481
+ type: 'string',
51482
+ description: 'Root session the cap belongs to (UUID). Every session in the tree draws on the same amount.',
51483
+ },
51484
+ ],
51485
+ },
51486
+ },
51424
51487
  managedAgentsGetSessionEventContent: {
51425
51488
  operationId: 'managedAgentsGetSessionEventContent',
51426
51489
  tag: 'managed-agents',
@@ -55018,6 +55081,77 @@ export const SDK_REFERENCE = {
55018
55081
  },
55019
55082
  ],
55020
55083
  },
55084
+ managedAgentsSetSessionBudget: {
55085
+ operationId: 'managedAgentsSetSessionBudget',
55086
+ tag: 'managed-agents',
55087
+ callPath: ['managedAgents', 'setSessionBudget'],
55088
+ namespace: 'managedAgents',
55089
+ method: 'setSessionBudget',
55090
+ bodyKey: 'body',
55091
+ signature: 'rl.managedAgents.setSessionBudget({ session_id, body })',
55092
+ example: 'const result = await rl.managedAgents.setSessionBudget({\n session_id: \'<session_id>\',\n body: {\n max_tree_cost_usd: "example"\n },\n});',
55093
+ cliInvocation: 'rl managed-agents set-session-budget',
55094
+ cliExample: 'rl managed-agents set-session-budget \\\n --session_id <session_id> \\\n --from-json body.json',
55095
+ curlExample: "curl -X PUT 'https://api.recursion.labelbox.com/managed-agents/v1/sessions/<session_id>/budget' \\\n -H 'Authorization: Bearer $LABELBOX_API_KEY' \\\n -H 'Content-Type: application/json' \\\n -d '{\n \"max_tree_cost_usd\": \"example\"\n }'",
55096
+ summary: "Set or raise the session tree's model-cost cap",
55097
+ description: 'Sets the model-cost cap for the whole session tree; any session in the tree may be named. A tree that stopped with stop_reason budget_reached resumes when the new cap leaves room: every stopped session in the tree is sent a message saying so and takes its next turn, and resumed_session_ids lists them. A cap below what is already spent stops the tree at its next turn boundary. The cap is checked between model requests, so one in-flight request per running session may still complete after it is reached.',
55098
+ httpMethod: 'put',
55099
+ path: '/managed-agents/v1/sessions/{session_id}/budget',
55100
+ requiredPermissions: ['managed-agents:update'],
55101
+ params: [
55102
+ {
55103
+ name: 'session_id',
55104
+ in: 'path',
55105
+ required: true,
55106
+ type: 'string',
55107
+ description: 'Session id (UUID) as returned by startSession or listSessions.',
55108
+ format: 'uuid',
55109
+ },
55110
+ {
55111
+ name: 'max_tree_cost_usd',
55112
+ in: 'body',
55113
+ required: false,
55114
+ type: 'string',
55115
+ description: 'New model-cost cap for the whole session tree, as a decimal USD string such as "25" or "12.50". Must be positive. Lower than what is already spent stops the tree at its next turn boundary; higher than what is spent wakes every session that had stopped at the old cap.',
55116
+ },
55117
+ ],
55118
+ response: {
55119
+ type: 'ManagedAgentsSessionBudgetResponse',
55120
+ description: 'The model-cost cap of one session tree and how much of it is spent. The cap is enforced between model requests, never mid-request, so the overshoot is bounded by one request per running session.',
55121
+ fields: [
55122
+ {
55123
+ name: 'consumed_cost_usd',
55124
+ required: false,
55125
+ type: 'string',
55126
+ description: 'Model cost the tree has been charged so far, as a decimal USD string, maintained as charges land.',
55127
+ },
55128
+ {
55129
+ name: 'exhausted',
55130
+ required: false,
55131
+ type: 'boolean',
55132
+ description: 'True when consumed cost has reached the cap. Sessions in the tree stop with stop_reason budget_reached at their next turn boundary and stay idle until the cap is raised.',
55133
+ },
55134
+ {
55135
+ name: 'max_tree_cost_usd',
55136
+ required: false,
55137
+ type: 'string',
55138
+ description: 'The cap as a decimal USD string. Absent when the budget row carries no cost cap.',
55139
+ },
55140
+ {
55141
+ name: 'resumed_session_ids',
55142
+ required: false,
55143
+ type: 'string[]',
55144
+ description: 'On a write, the sessions that had stopped at the old cap and were sent a resume message because the new cap leaves room. Absent on a read, and when nothing was waiting.',
55145
+ },
55146
+ {
55147
+ name: 'root_session_id',
55148
+ required: false,
55149
+ type: 'string',
55150
+ description: 'Root session the cap belongs to (UUID). Every session in the tree draws on the same amount.',
55151
+ },
55152
+ ],
55153
+ },
55154
+ },
55021
55155
  managedAgentsStartAgentReflection: {
55022
55156
  operationId: 'managedAgentsStartAgentReflection',
55023
55157
  tag: 'managed-agents',
@@ -55184,7 +55318,7 @@ export const SDK_REFERENCE = {
55184
55318
  cliExample: "rl managed-agents start-session \\\n --agent_id '9f8b1c2d-3e4f-5a6b-7c8d-9e0f1a2b3c4d' \\\n --environment_id '9f8b1c2d-3e4f-5a6b-7c8d-9e0f1a2b3c4d' \\\n --from-json body.json",
55185
55319
  curlExample: 'curl -X POST \'https://api.recursion.labelbox.com/managed-agents/v1/sessions\' \\\n -H \'Authorization: Bearer $LABELBOX_API_KEY\' \\\n -H \'Content-Type: application/json\' \\\n -d \'{\n "agent_id": "9f8b1c2d-3e4f-5a6b-7c8d-9e0f1a2b3c4d",\n "credential_refs": [\n {\n "credential_id": "9f8b1c2d-3e4f-5a6b-7c8d-9e0f1a2b3c4d",\n "vault_id": "9f8b1c2d-3e4f-5a6b-7c8d-9e0f1a2b3c4d"\n }\n ],\n "environment_id": "9f8b1c2d-3e4f-5a6b-7c8d-9e0f1a2b3c4d",\n "external_source_id": "9f8b1c2d-3e4f-5a6b-7c8d-9e0f1a2b3c4d",\n "external_source_type": "example",\n "idempotency_key": "example",\n "message": "example",\n "metadata": {\n "key": "example"\n },\n "outcome": {\n "description": "example",\n "grader_model_ref_id": "9f8b1c2d-3e4f-5a6b-7c8d-9e0f1a2b3c4d",\n "max_iterations": 1,\n "rubric": "example"\n },\n "project_id": "9f8b1c2d-3e4f-5a6b-7c8d-9e0f1a2b3c4d",\n "skip_default_outcome": true,\n "vault_ids": [\n "example"\n ]\n }\'',
55186
55320
  summary: 'Start a managed session',
55187
- description: 'Starts a managed agent session and returns 202 with its session_id and status_path; the agent runs asynchronously, so poll getSession or subscribe with streamSessionEvents to follow it. Sandbox compute is provisioned here, which is where a session begins costing money. Send an Idempotency-Key header to make retries safe: the same key with the same body returns the original session, and with a different body is rejected.',
55321
+ description: 'Starts a managed agent session and returns 202 with its session_id and status_path; the agent runs asynchronously, so poll getSession or subscribe with streamSessionEvents to follow it. Sandbox compute is provisioned here, which is where a session begins costing money. Send an Idempotency-Key header to make retries safe: the same key with the same body returns the original session, and with a different body is rejected. A reasoning_effort incompatible with the selected model or its frozen output capacity returns 400 before provisioning; a temporarily unavailable model reference or catalog dependency returns 503.',
55188
55322
  httpMethod: 'post',
55189
55323
  path: '/managed-agents/v1/sessions',
55190
55324
  requiredPermissions: ['managed-agents:create'],
@@ -55351,7 +55485,7 @@ export const SDK_REFERENCE = {
55351
55485
  cliExample: 'rl managed-agents update-agent \\\n --agent_id <agent_id> \\\n --from-json body.json',
55352
55486
  curlExample: 'curl -X PATCH \'https://api.recursion.labelbox.com/managed-agents/v1/agents/<agent_id>\' \\\n -H \'Authorization: Bearer $LABELBOX_API_KEY\' \\\n -H \'Content-Type: application/json\' \\\n -d \'{\n "agent_id": "9f8b1c2d-3e4f-5a6b-7c8d-9e0f1a2b3c4d",\n "created_at": "2026-02-18T09:30:00Z",\n "custom_tools": [\n {\n "config": {\n "key": "example"\n },\n "name": "example-name",\n "type": "example"\n }\n ],\n "default_credential_refs": [\n {\n "credential_id": "9f8b1c2d-3e4f-5a6b-7c8d-9e0f1a2b3c4d",\n "vault_id": "9f8b1c2d-3e4f-5a6b-7c8d-9e0f1a2b3c4d"\n }\n ],\n "default_rubric": "example",\n "default_vault_ids": [\n "example"\n ],\n "description": "example",\n "latest_agent_version_id": "9f8b1c2d-3e4f-5a6b-7c8d-9e0f1a2b3c4d",\n "mcp_servers": [\n {\n "key": "example"\n }\n ],\n "metadata": {\n "key": "example"\n },\n "model": "example",\n "model_config": {\n "max_tokens": 1,\n "provider_params": {\n "key": "example"\n },\n "reasoning_effort": "example",\n "response_format": "example",\n "temperature": 1.5,\n "tool_choice": "example",\n "top_p": 1.5\n },\n "model_ref_id": "9f8b1c2d-3e4f-5a6b-7c8d-9e0f1a2b3c4d",\n "multiagent": {\n "key": "example"\n },\n "name": "example-name",\n "organization_id": "9f8b1c2d-3e4f-5a6b-7c8d-9e0f1a2b3c4d",\n "runtime_adapters": [\n {\n "key": "example"\n }\n ],\n "skills": [\n {\n "key": "example"\n }\n ],\n "system": "example",\n "toolsets": [\n {\n "config": {\n "key": "example"\n },\n "name": "example-name",\n "type": "example"\n }\n ],\n "updated_at": "2026-02-18T09:30:00Z",\n "web_search_enabled": true\n }\'',
55353
55487
  summary: 'Update agent and create a new immutable version',
55354
- description: 'Applies a partial update and returns the agent resolved to the new version. Agent versions are immutable, so every accepted update mints a new one rather than editing history; omitted fields keep their current values. Running sessions keep the version they started with.',
55488
+ description: 'Applies a partial update and returns the agent resolved to the new version. Agent versions are immutable, so every accepted update mints a new one rather than editing history; omitted fields keep their current values. Running sessions keep the version they started with. Invalid model_config and unsupported new or changed reasoning_effort values return 400, including when a reachable gateway model publishes no exact options; an unconfigured or unreachable gateway that prevents verification returns 503.',
55355
55489
  httpMethod: 'patch',
55356
55490
  path: '/managed-agents/v1/agents/{agent_id}',
55357
55491
  requiredPermissions: ['managed-agents:update'],
@@ -55447,7 +55581,7 @@ export const SDK_REFERENCE = {
55447
55581
  in: 'body',
55448
55582
  required: false,
55449
55583
  type: 'ManagedAgentsInferenceConfig',
55450
- description: 'Default inference settings applied to every turn unless a session overrides them.',
55584
+ description: "Default inference config for the new version. Omit model_config to preserve the current config; send {} to clear the entire config and use provider defaults; null is invalid. reasoning_effort is normalized and validated for direct providers, and must exactly match the selected gateway model's published options. An unsupported new or changed value, including a reachable gateway model that publishes no exact options, returns 400; an unconfigured or unreachable gateway that prevents verification returns 503.",
55451
55585
  fields: [
55452
55586
  {
55453
55587
  name: 'max_tokens',
@@ -55466,7 +55600,7 @@ export const SDK_REFERENCE = {
55466
55600
  name: 'reasoning_effort',
55467
55601
  required: false,
55468
55602
  type: 'string',
55469
- description: 'Thinking-budget hint for reasoning-capable models, e.g. low, medium, or high. Ignored by models that do not support reasoning.',
55603
+ description: "Provider-native reasoning depth value. For gateway models, use one of supported_reasoning_efforts from the models catalog; omit it to follow the provider's current default.",
55470
55604
  },
55471
55605
  {
55472
55606
  name: 'response_format',
@@ -55661,7 +55795,7 @@ export const SDK_REFERENCE = {
55661
55795
  name: 'reasoning_effort',
55662
55796
  required: false,
55663
55797
  type: 'string',
55664
- description: 'Thinking-budget hint for reasoning-capable models, e.g. low, medium, or high. Ignored by models that do not support reasoning.',
55798
+ description: "Provider-native reasoning depth value. For gateway models, use one of supported_reasoning_efforts from the models catalog; omit it to follow the provider's current default.",
55665
55799
  },
55666
55800
  {
55667
55801
  name: 'response_format',
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@labelbox/recursion-sdk",
3
- "version": "0.0.166",
3
+ "version": "0.0.168",
4
4
  "type": "module",
5
5
  "main": "./dist/index.js",
6
6
  "types": "./dist/index.d.ts",