@deepraxis/sdk 0.1.1-dev.54635ff → 0.1.1-dev.68542bb

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.
@@ -106,7 +106,7 @@ export const operations = [
106
106
  "name": "multiagent",
107
107
  "type": "object",
108
108
  "required": false,
109
- "description": "A coordinator topology: the session's primary thread orchestrates\nwork by spawning session threads, each running an agent drawn from the `agents`\nroster."
109
+ "description": "Coordinator roster. A bare string agent id is equivalent to {type: \"agent\", id}; omitting its version pins the referenced agent's current saved version when this roster is saved. {type: \"self\"} refers to this agent. Specify a concrete version to pin it explicitly."
110
110
  },
111
111
  {
112
112
  "name": "skills",
@@ -133,7 +133,7 @@ export const operations = [
133
133
  "type": "array",
134
134
  "itemType": "object",
135
135
  "required": false,
136
- "description": "Platform resources and services this service agent's codemode may reach, as one list of typed bindings. Only kind=service accepts a nonempty list; personal agents return 400. There are two kinds. A resource binding names one resource with id and access: database (id db_..., read_only or read_write), vector_store (id vs_..., read_only or read_write), file (id file- plus 24 letters or digits, as the File API returns it; read_only), media_library (any id without ':' or whitespace, read_only or read_write), model (a model catalog id, invoke), workflow and script (id <namespace>/<name>, invoke). A service binding opens a whole service and carries only enabled: search or browser. At most 20 bindings per type, no repeated type and id, and each service type at most once. A session is authorized by the agent version it runs: newly added bindings apply only to new sessions, and a version saved with apply=false changes no access until it is applied. Applying a version that disables, removes or downgrades a binding revokes it immediately in running sessions on older versions. A resource that is not bound returns 404, a service that is not opened returns 403, and a write to a resource bound read_only returns 403 BINDING_READ_ONLY. Unknown types, fields on the wrong kind (id, access or instructions on a service binding), wrong access and malformed ids return 400. The former databases, vector_stores and files fields are removed and return 400. Omit on create for no bindings."
136
+ "description": "Platform resources and services this service agent's codemode may reach, as one list of typed bindings. Only kind=service accepts a nonempty list; personal agents return 400. There are two kinds. A resource binding names one resource with id and access: database (id db_..., read_only or read_write), vector_store (id vs_..., read_only or read_write), file (id file- plus 24 letters or digits, as the File API returns it; read_only), media_library (any id without ':' or whitespace, read_only or read_write), model (a model catalog id, invoke), workflow and script (id <namespace>/<name>, invoke). A service binding opens a whole service and carries only enabled: search or browser. At most 20 bindings per type, no repeated type and id, and each service type at most once. A session is authorized by the agent version it runs: newly added bindings apply only to new sessions, and a version saved with apply=false changes no access until it is applied. Applying a version that disables, removes or downgrades a binding revokes it immediately in running sessions on older versions. A resource that is not bound returns 404, a service that is not opened returns 403, and a write to a resource bound read_only returns 403 BINDING_READ_ONLY. Unknown types, fields on the wrong kind (id, access or instructions on a service binding), wrong access and malformed ids return 400. The former databases, vector_stores and files fields are removed and return 400. Omit on create for no bindings. Saving checks added or changed database, vector_store, media_library and file bindings in the organization: unknown or deleted ids return 400. If an owner is unavailable or takes more than 3 seconds, saving succeeds with verified=false for the affected bindings. Unchanged bindings keep their previous verification result and are not rechecked. workflow and script ids are not verified at save time."
137
137
  },
138
138
  {
139
139
  "name": "kind",
@@ -226,7 +226,7 @@ export const operations = [
226
226
  "resource": "agent.agents",
227
227
  "method": "retrieve",
228
228
  "summary": "Get agent",
229
- "description": "Read one agent by id. The top level is the latest saved version, the editable head whose version you send back for optimistic concurrency; after a save with apply false it differs from active_version, and new sessions use active_version, which you read with version=active. With version, read a specific saved version. The response lists every native tool with its resolved configuration in one agent_toolset_20260401 entry, so it can be sent back unchanged to agents.update. Use agents.versions.list to enumerate versions.",
229
+ "description": "Read the agent configuration currently effective for new sessions. By default, version equals active_version and latest_version identifies the newest saved version, including an unapplied save. Use latest_version for optimistic concurrency when updating. Pass version as a positive integer to read that saved version; version=active is equivalent to omission. The response lists every native tool with its resolved configuration in one agent_toolset_20260401 entry, so tools can be sent back unchanged to agents.update. Use agents.versions.list to enumerate saved versions.",
230
230
  "http": "GET",
231
231
  "path": "/agent/v1/agents/{agent_id}",
232
232
  "streaming": "no",
@@ -243,7 +243,7 @@ export const operations = [
243
243
  "name": "version",
244
244
  "type": "number",
245
245
  "required": false,
246
- "description": "Agent version to read; omit for the latest saved version. An integer of at least 1 (versions are listed by agents.versions.list), or the string active for the version new sessions use."
246
+ "description": "Agent version to read. Omit, or send active, for the currently effective version used by new sessions. Send an integer of at least 1 from agents.versions.list to read that saved version. The default response also includes latest_version, the newest saved version number."
247
247
  }
248
248
  ]
249
249
  },
@@ -251,7 +251,7 @@ export const operations = [
251
251
  "resource": "agent.agents",
252
252
  "method": "update",
253
253
  "summary": "Update agent",
254
- "description": "Update an agent. Send the current version in the body for optimistic concurrency: a stale version returns 409, and an update that changes nothing keeps the version number. Any real change saves a new version. apply defaults to true and moves active_version to the new version, or to the latest when configuration is unchanged; apply false saves without applying. version_note optionally records up to 280 characters on a newly created version; null means no note, and a note sent when the request changes nothing else returns 400 because a note is stored only with a new version. Existing sessions and tokens keep their version. Omitted fields keep their value. multiagent takes null or a coordinator roster; subagent_model keeps its value when omitted and is cleared by null. Archived agents cannot be updated. tools: [] removes every tool, while tools: null returns 400 (tools cannot be null; send [] to remove every tool). On update, omit skills to keep them, send an array to replace them, or send [] or null to clear them. skills attaches uploaded custom skills as [{type: \"custom\", skill_id, version?}] (skill_id from skills.create or skills.list; at most 20, no repeated skill_id). Omit version, or send \"latest\", to use the skill's newest version when a session starts. type anthropic returns 400.",
254
+ "description": "Save configuration changes as a new immutable version. Send latest_version from a default retrieve or update response as the request version for optimistic concurrency; a stale value returns 409. apply defaults to true and makes the new version effective; apply false saves without changing active_version. The response contains the effective configuration, with version equal to active_version and latest_version naming the newest saved version. An unchanged configuration, including a note-only update, is a no-op returning 200 and the current effective version without creating or activating a version. version_note records up to 280 characters only when a configuration change creates a new version; null is equivalent to omission. Use agents.versions.apply to activate an existing saved version. Existing sessions and tokens keep their version. Omitted fields keep their value. multiagent takes null or a coordinator roster; subagent_model keeps its value when omitted and is cleared by null. Archived agents cannot be updated. tools: [] removes every tool, while tools: null returns 400 (tools cannot be null; send [] to remove every tool). On update, omit skills to keep them, send an array to replace them, or send [] or null to clear them. skills attaches uploaded custom skills as [{type: \"custom\", skill_id, version?}] (skill_id from skills.create or skills.list; at most 20, no repeated skill_id). Omit version, or send \"latest\", to use the skill's newest version when a session starts. type anthropic returns 400.",
255
255
  "http": "POST",
256
256
  "path": "/agent/v1/agents/{agent_id}",
257
257
  "streaming": "no",
@@ -296,7 +296,7 @@ export const operations = [
296
296
  "name": "multiagent",
297
297
  "type": "object",
298
298
  "required": false,
299
- "description": "A coordinator topology: the session's primary thread orchestrates\nwork by spawning session threads, each running an agent drawn from the `agents`\nroster."
299
+ "description": "Coordinator roster. A bare string agent id is equivalent to {type: \"agent\", id}; omitting its version pins the referenced agent's current saved version when this roster is saved. {type: \"self\"} refers to this agent. Specify a concrete version to pin it explicitly."
300
300
  },
301
301
  {
302
302
  "name": "name",
@@ -328,19 +328,19 @@ export const operations = [
328
328
  "name": "version",
329
329
  "type": "number",
330
330
  "required": false,
331
- "description": "The agent's current version, used to prevent concurrent overwrites.\nObtain this value from a create or retrieve response. Must be at least 1 if\nspecified. When supplied, the request fails if it does not match the server's\ncurrent version; omit to apply the update unconditionally."
331
+ "description": "Newest saved version used for optimistic concurrency. Obtain latest_version from the default retrieve or update response, or version from versions.list. A stale value returns 409; omit for an unconditional update."
332
332
  },
333
333
  {
334
334
  "name": "apply",
335
335
  "type": "boolean",
336
336
  "required": false,
337
- "description": "Defaults to true: apply the newly saved version, or the latest version when configuration is unchanged. Set false to save without changing active_version. Unlike Managed Agents, saving and applying can be separate."
337
+ "description": "Defaults to true: apply a newly saved configuration version. Set false to save without changing active_version. An unchanged configuration is a no-op, including note-only updates; use versions.apply to activate a saved version."
338
338
  },
339
339
  {
340
340
  "name": "version_note",
341
341
  "type": "string",
342
342
  "required": false,
343
- "description": "Optional change explanation stored as note on the new immutable version, up to 280 characters. Omission or null stores no note. A note sent when nothing else changes returns 400 (nothing to save), because a note is stored only with a new version."
343
+ "description": "Optional change explanation, at most 280 characters. Recorded only when a configuration change creates a new immutable version. A note-only update is a no-op returning 200 and the current effective version. Null is equivalent to omission."
344
344
  },
345
345
  {
346
346
  "name": "bindings",
@@ -818,188 +818,6 @@ export const operations = [
818
818
  ],
819
819
  "query": []
820
820
  },
821
- {
822
- "resource": "agent.agents.endUsers",
823
- "method": "list",
824
- "summary": "List End Users",
825
- "description": "List users who have sessions or token issuance history on a service agent.\n\nOrdered by last_active_at and external_user_id descending. q is a case-sensitive literal prefix, including underscores. limit is 1–100, default 20. Reuse next_page with the same organization, agent, q and limit. Preemptively blocked users without history do not appear. End-user credentials and inaccessible or personal agents return 404.",
826
- "http": "GET",
827
- "path": "/agent/v1/agents/{agent_id}/end_users",
828
- "streaming": "no",
829
- "pagination": false,
830
- "pathParams": [
831
- {
832
- "name": "agent_id",
833
- "sdkName": "agent_id",
834
- "description": "Active service agent identifier from agent creation or listing."
835
- }
836
- ],
837
- "query": [
838
- {
839
- "name": "limit",
840
- "type": "integer",
841
- "required": false,
842
- "description": "Maximum users per page; defaults to 20."
843
- },
844
- {
845
- "name": "page",
846
- "type": "string",
847
- "required": false,
848
- "description": "next_page from the previous response with the same agent, q and limit."
849
- },
850
- {
851
- "name": "q",
852
- "type": "string",
853
- "required": false,
854
- "description": "Case-sensitive literal prefix of external_user_id; omit or use an empty string for all users."
855
- }
856
- ]
857
- },
858
- {
859
- "resource": "agent.agents.endUsers",
860
- "method": "delete",
861
- "summary": "Delete end-user data",
862
- "description": "Delete a host application's end-user data from one service agent after explicit confirmation.\n\nDevelop only. Set confirm to the exact external_user_id; missing or mismatched confirmation returns 400. Returns 202 with a pending task id, not completion. Poll the deletion endpoint. Concurrent requests reuse the unfinished task; retry DELETE after failure to resume it. Tokens are revoked and the user is blocked before a seven-day recovery snapshot is verified. Sessions including child sessions, conversation data, grants and feedback are then removed. A pre-existing block remains; a temporary block is removed on success. Attachment metadata is recorded and File attachments are retained. No charge is introduced by this operation. Example: DELETE /agent/v1/agents/agent_example/end_users/customer_123?confirm=customer_123.",
863
- "http": "DELETE",
864
- "path": "/agent/v1/agents/{agent_id}/end_users/{external_user_id}",
865
- "streaming": "no",
866
- "pagination": false,
867
- "pathParams": [
868
- {
869
- "name": "agent_id",
870
- "sdkName": "agent_id",
871
- "description": "Active service agent identifier from agent creation or listing."
872
- },
873
- {
874
- "name": "external_user_id",
875
- "sdkName": "external_user_id",
876
- "description": "Host user identifier supplied at issuance or from end-user listing."
877
- }
878
- ],
879
- "query": [
880
- {
881
- "name": "confirm",
882
- "type": "string",
883
- "required": true,
884
- "description": "Must exactly equal the external_user_id path parameter to confirm destructive deletion."
885
- }
886
- ]
887
- },
888
- {
889
- "resource": "agent.agents.endUsers",
890
- "method": "retrieve",
891
- "summary": "Get End User",
892
- "description": "Inspect one end user and their twenty most recently updated sessions.\n\nUse external_user_id from listing or your host application. Users without session or issuance history return 404, including preemptively blocked users. End-user credentials and inaccessible or personal agents return 404.",
893
- "http": "GET",
894
- "path": "/agent/v1/agents/{agent_id}/end_users/{external_user_id}",
895
- "streaming": "no",
896
- "pagination": false,
897
- "pathParams": [
898
- {
899
- "name": "agent_id",
900
- "sdkName": "agent_id",
901
- "description": "Active service agent identifier from agent creation or listing."
902
- },
903
- {
904
- "name": "external_user_id",
905
- "sdkName": "external_user_id",
906
- "description": "Host user identifier supplied at issuance or from end-user listing."
907
- }
908
- ],
909
- "query": []
910
- },
911
- {
912
- "resource": "agent.agents.endUsers.block",
913
- "method": "create",
914
- "summary": "Block End User",
915
- "description": "Block token issuance and session creation, then revoke existing tokens for an end user.\n\nMay block a user before any history exists; timestamps are then null and counts and cost are zero. Requires an embed policy, otherwise returns 409 with setup guidance. Deduplicates the policy blocklist and retains its 1000-user maximum. If revocation returns 502, the user remains blocked; retry to finish revocation. Repeats keep the user blocked and revoke any remaining grants. End-user credentials and inaccessible or personal agents return 404.",
916
- "http": "POST",
917
- "path": "/agent/v1/agents/{agent_id}/end_users/{external_user_id}/block",
918
- "streaming": "no",
919
- "pagination": false,
920
- "pathParams": [
921
- {
922
- "name": "agent_id",
923
- "sdkName": "agent_id",
924
- "description": "Active service agent identifier from agent creation or listing."
925
- },
926
- {
927
- "name": "external_user_id",
928
- "sdkName": "external_user_id",
929
- "description": "Host user identifier supplied at issuance or from end-user listing."
930
- }
931
- ],
932
- "query": []
933
- },
934
- {
935
- "resource": "agent.agents.endUsers",
936
- "method": "retrieveDeletion",
937
- "summary": "Get end-user deletion",
938
- "description": "Poll the latest deletion task for an end user, including after the user data has been removed.\n\nUse the same agent_id and external_user_id as the confirmed DELETE. Status is pending, snapshotting, deleting, done or failed. Counts are empty until a verified snapshot exists. A failed task remains blocked and resumes when DELETE is retried with matching confirmation. snapshot_key is an operator recovery reference retained for seven days, not a public download URL. End-user credentials, inaccessible or personal agents, and missing tasks return 404. This read does not create a task or charge usage.",
939
- "http": "GET",
940
- "path": "/agent/v1/agents/{agent_id}/end_users/{external_user_id}/deletion",
941
- "streaming": "no",
942
- "pagination": false,
943
- "pathParams": [
944
- {
945
- "name": "agent_id",
946
- "sdkName": "agent_id",
947
- "description": "Active service agent identifier from agent creation or listing."
948
- },
949
- {
950
- "name": "external_user_id",
951
- "sdkName": "external_user_id",
952
- "description": "Host user identifier supplied at issuance or from end-user listing."
953
- }
954
- ],
955
- "query": []
956
- },
957
- {
958
- "resource": "agent.agents.endUsers.revokeTokens",
959
- "method": "create",
960
- "summary": "Revoke End User Tokens",
961
- "description": "Revoke all issued tokens for an end user and terminate their open embed streams.\n\nRevokes credentials before marking grants revoked. Upstream failure returns 502 without changing grant revocation timestamps. Returns the count of newly revoked grants; a repeat without new grants returns zero. Does not block future issuance. End-user credentials and inaccessible or personal agents return 404.",
962
- "http": "POST",
963
- "path": "/agent/v1/agents/{agent_id}/end_users/{external_user_id}/revoke_tokens",
964
- "streaming": "no",
965
- "pagination": false,
966
- "pathParams": [
967
- {
968
- "name": "agent_id",
969
- "sdkName": "agent_id",
970
- "description": "Active service agent identifier from agent creation or listing."
971
- },
972
- {
973
- "name": "external_user_id",
974
- "sdkName": "external_user_id",
975
- "description": "Host user identifier supplied at issuance or from end-user listing."
976
- }
977
- ],
978
- "query": []
979
- },
980
- {
981
- "resource": "agent.agents.endUsers.unblock",
982
- "method": "create",
983
- "summary": "Unblock End User",
984
- "description": "Allow an end user to receive new tokens and create new sessions again.\n\nRemoves the user from the blocklist; previously revoked tokens stay revoked. Idempotent. Requires an embed policy, otherwise returns 409 with setup guidance. Returns null timestamps and zero counts and cost when no session or issuance history exists. End-user credentials and inaccessible or personal agents return 404.",
985
- "http": "POST",
986
- "path": "/agent/v1/agents/{agent_id}/end_users/{external_user_id}/unblock",
987
- "streaming": "no",
988
- "pagination": false,
989
- "pathParams": [
990
- {
991
- "name": "agent_id",
992
- "sdkName": "agent_id",
993
- "description": "Active service agent identifier from agent creation or listing."
994
- },
995
- {
996
- "name": "external_user_id",
997
- "sdkName": "external_user_id",
998
- "description": "Host user identifier supplied at issuance or from end-user listing."
999
- }
1000
- ],
1001
- "query": []
1002
- },
1003
821
  {
1004
822
  "resource": "agent.agents.unarchive",
1005
823
  "method": "create",
@@ -1022,7 +840,7 @@ export const operations = [
1022
840
  "resource": "agent.agents.versions",
1023
841
  "method": "list",
1024
842
  "summary": "List agent versions",
1025
- "description": "List the saved versions of one agent, in pages of at most 100 (default 20). Each item is the full agent definition at that version, so you can compare what changed between versions. active is true only for the item that new sessions use; active_version on each item is the agent-level value, kept for compatibility. Use agents.retrieve with version to read a single one; agent_id comes from agents.list or agents.create.",
843
+ "description": "List the saved versions of one agent in ascending version number, oldest first, in pages of at most 100 (default 20). Each item is the full agent definition at that saved version, so you can compare configurations. active is true only for the item new sessions use. active_version on every item is the same agent-level currently effective version; it is not that item's version. Use agents.retrieve with version to read a single saved version; agent_id comes from agents.list or agents.create. Pass next_page as page to continue.",
1026
844
  "http": "GET",
1027
845
  "path": "/agent/v1/agents/{agent_id}/versions",
1028
846
  "streaming": "no",
@@ -1053,7 +871,7 @@ export const operations = [
1053
871
  "resource": "agent.agents.versions",
1054
872
  "method": "apply",
1055
873
  "summary": "Apply Agent Version",
1056
- "description": "Apply a version from agents.versions.list by its version number. This idempotent operation changes active_version without creating a version; existing sessions and tokens keep their version. The response is the latest saved agent with its current active_version. Missing versions return 404 Agent version not found; archived agents return 409 Agent is archived. For example, POST /agent/v1/agents/{agent_id}/versions/2/apply with no body.",
874
+ "description": "Apply a saved version from agents.versions.list for new sessions and newly issued tokens, without creating a version. Existing sessions and tokens retain their version. The response contains the effective configuration with version equal to active_version and latest_version naming the newest saved version. Missing versions return 404; archived agents return 409. For example, POST /agent/v1/agents/{agent_id}/versions/2/apply with no body.",
1057
875
  "http": "POST",
1058
876
  "path": "/agent/v1/agents/{agent_id}/versions/{version}/apply",
1059
877
  "streaming": "no",
@@ -1792,204 +1610,6 @@ export const operations = [
1792
1610
  ],
1793
1611
  "query": []
1794
1612
  },
1795
- {
1796
- "resource": "agent.embed",
1797
- "method": "retrieveAppearance",
1798
- "summary": "Read chat appearance",
1799
- "description": "Load saved appearance for an iframe or Hosted chat page. Supply an end-user embed token as Bearer authorization, or a console-issued publishable key in Praxis-Publishable-Key before anonymous token issuance. The credential selects the agent; identity_number and agent_id query parameters are rejected with 400. Missing appearance returns an empty object. Kit option names retain camelCase. Responses are private and cacheable for 60 seconds. Component hosts configure Kit in their own code instead.",
1800
- "http": "GET",
1801
- "path": "/agent/v1/embed/appearance",
1802
- "streaming": "no",
1803
- "pagination": false,
1804
- "pathParams": [],
1805
- "query": []
1806
- },
1807
- {
1808
- "resource": "agent.embed.exchange",
1809
- "method": "create",
1810
- "summary": "Exchange Hosted Code",
1811
- "description": "Redeem a single-use hosted link credential for an end-user token.\n\nRead code from the c fragment parameter of hosted_url returned by embed token creation with hosted true, then remove the fragment before exchanging. No Authorization header is required; the code authenticates this request. The code expires after 60 seconds and is consumed atomically on exchange, so concurrent attempts have only one winner. Expired, used and unknown codes return the same 404 body. Keep the token in memory and return to the host website for a fresh link when it expires; exchange cannot refresh it. Requests are IP limited per minute using the anonymous entrypoint budget (default 20). Example body is {\"code\":\"<code from hosted_url>\"}.",
1812
- "http": "POST",
1813
- "path": "/agent/v1/embed/exchange",
1814
- "streaming": "no",
1815
- "pagination": false,
1816
- "pathParams": [],
1817
- "query": [],
1818
- "body": {
1819
- "required": true,
1820
- "fields": [
1821
- {
1822
- "name": "code",
1823
- "type": "string",
1824
- "required": true,
1825
- "description": "Single-use credential from the c fragment parameter of hosted_url returned by embed token creation. Valid for 60 seconds."
1826
- }
1827
- ]
1828
- }
1829
- },
1830
- {
1831
- "resource": "agent.embedTokens",
1832
- "method": "list",
1833
- "summary": "List Embed Tokens",
1834
- "description": "List embed token issuance records in your organization.\n\nIncludes expired and revoked grants; returns neither token nor token_id. Sorts by created_at, then grant id, both descending. agent_id accepts agent_ or agt_; external_user_id matches exactly. limit is 1–100 (default 20). Reuse next_page as page with the same filters and organization; a mismatch returns 400. End-user credentials return 404.",
1835
- "http": "GET",
1836
- "path": "/agent/v1/embed_tokens",
1837
- "streaming": "no",
1838
- "pagination": false,
1839
- "pathParams": [],
1840
- "query": [
1841
- {
1842
- "name": "agent_id",
1843
- "type": "string",
1844
- "required": false,
1845
- "description": "Filter by service agent identifier (agent_ or agt_ prefix)."
1846
- },
1847
- {
1848
- "name": "external_user_id",
1849
- "type": "string",
1850
- "required": false,
1851
- "description": "Exact host user identifier supplied at issuance."
1852
- },
1853
- {
1854
- "name": "limit",
1855
- "type": "integer",
1856
- "required": false,
1857
- "description": "Maximum records per page; defaults to 20."
1858
- },
1859
- {
1860
- "name": "page",
1861
- "type": "string",
1862
- "required": false,
1863
- "description": "next_page from a previous response with the same filters."
1864
- }
1865
- ]
1866
- },
1867
- {
1868
- "resource": "agent.embedTokens",
1869
- "method": "create",
1870
- "summary": "Create Embed Token",
1871
- "description": "Issue a short-lived credential on your backend for an end user of a service agent.\n\nRequires an active service agent in your organization with an embed policy. Pins the requested version or the latest version and snapshots the policy environment, vaults and resources; metadata comes from the request. Blocked users cannot receive tokens. Keep your API key on the backend and pass only the returned token to the frontend. Every call creates a new grant; issuance is not idempotent. Set hosted to true to also receive hosted_url; redirect the user there within 60 seconds. The agent must have an identity_number. The URL fragment contains a single-use exchange credential, not the token. Omit hosted or set false for ordinary token issuance.",
1872
- "http": "POST",
1873
- "path": "/agent/v1/embed_tokens",
1874
- "streaming": "no",
1875
- "pagination": false,
1876
- "pathParams": [],
1877
- "query": [],
1878
- "body": {
1879
- "required": true,
1880
- "fields": [
1881
- {
1882
- "name": "hosted",
1883
- "type": "boolean",
1884
- "required": false,
1885
- "description": "Set true to also return a hosted chat URL with a single-use credential valid for 60 seconds. Defaults to false; the agent must have an identity_number."
1886
- },
1887
- {
1888
- "name": "agent",
1889
- "type": "string",
1890
- "required": true,
1891
- "description": "Service agent ID or identity_number from agent retrieval; it must belong to your organization and be active."
1892
- },
1893
- {
1894
- "name": "version",
1895
- "type": "integer",
1896
- "required": false,
1897
- "description": "Existing agent version to pin. Omit to pin the latest version at issuance."
1898
- },
1899
- {
1900
- "name": "external_user_id",
1901
- "type": "string",
1902
- "required": true,
1903
- "description": "Your application's stable end-user identifier, scoped to this organization and agent."
1904
- },
1905
- {
1906
- "name": "ttl_seconds",
1907
- "type": "integer",
1908
- "required": false,
1909
- "description": "Token lifetime in seconds. Defaults to the embed policy TTL and cannot exceed its maximum or 3600 seconds."
1910
- },
1911
- {
1912
- "name": "budget_cents",
1913
- "type": "integer",
1914
- "required": false,
1915
- "description": "Session budget in cents. Defaults to the embed policy session budget and cannot exceed its maximum."
1916
- },
1917
- {
1918
- "name": "system_message",
1919
- "type": "array",
1920
- "itemType": "object",
1921
- "required": false,
1922
- "description": "Optional host context as text blocks, limited to 8192 UTF-8 bytes in total."
1923
- },
1924
- {
1925
- "name": "agent_override",
1926
- "type": "object",
1927
- "required": false,
1928
- "description": "Optional system prompt override, accepted only when the embed policy allows agent overrides."
1929
- },
1930
- {
1931
- "name": "allowed_origins",
1932
- "type": "array",
1933
- "itemType": "string",
1934
- "required": false,
1935
- "description": "Optional subset of the policy origin entries, compared exactly. Omit to snapshot every policy origin."
1936
- },
1937
- {
1938
- "name": "metadata",
1939
- "type": "object",
1940
- "required": false,
1941
- "description": "Host metadata preserved verbatim; at most 16 keys of 1–64 characters and string values of at most 512 characters. Defaults to an empty object."
1942
- }
1943
- ]
1944
- }
1945
- },
1946
- {
1947
- "resource": "agent.embedTokens.anonymous",
1948
- "method": "create",
1949
- "summary": "Issue anonymous visitor token",
1950
- "description": "Obtain a short-lived embedding token for a visitor without an account using the agent owner's publishable key.\n\nNo Authorization header is required. Send the browser Origin allowed by the agent policy. Save a returned visitor_secret and reuse it for refreshes; only new visitors receive one. Unknown secrets create new visitors, and extra fields including visitor_id return 400. Issuance uses the key creator's organization membership, the key session budget and the smaller of the policy TTL maximum and 3600 seconds. IP requests are limited per minute (default 20); UTC daily session and spending caps are checked across the key's primary sessions created that day. Token issuance itself does not create a session or charge usage; subsequent sessions bill the host organization. Example body: {\"publishable_key\":\"pk_praxis_example\"}.",
1951
- "http": "POST",
1952
- "path": "/agent/v1/embed_tokens/anonymous",
1953
- "streaming": "no",
1954
- "pagination": false,
1955
- "pathParams": [],
1956
- "query": [],
1957
- "body": {
1958
- "required": true,
1959
- "fields": [
1960
- {
1961
- "name": "publishable_key",
1962
- "type": "string",
1963
- "required": true,
1964
- "description": "Public key created by the service agent owner; safe to include in browser code."
1965
- },
1966
- {
1967
- "name": "visitor_secret",
1968
- "type": "string",
1969
- "required": false,
1970
- "description": "Secret returned by a previous anonymous issuance for this key. Omit for a new visitor; an unknown secret creates a new visitor."
1971
- }
1972
- ]
1973
- }
1974
- },
1975
- {
1976
- "resource": "agent.embedTokens.revoke",
1977
- "method": "create",
1978
- "summary": "Revoke Embed Token",
1979
- "description": "Revoke an embed token and close its open event streams.\n\nUse an id from issuance or listing. Revokes the credential before setting revoked_at; upstream failure leaves it unset. Streams receive session.error (EMBED_TOKEN_REVOKED), then close immediately; other credentials are unaffected. Idempotent; repeats return the original revoked record without another revocation or audit. Missing or foreign grants and end-user credentials return 404.",
1980
- "http": "POST",
1981
- "path": "/agent/v1/embed_tokens/{id}/revoke",
1982
- "streaming": "no",
1983
- "pagination": false,
1984
- "pathParams": [
1985
- {
1986
- "name": "id",
1987
- "sdkName": "id",
1988
- "description": "Grant id returned by issuance or listing."
1989
- }
1990
- ],
1991
- "query": []
1992
- },
1993
1613
  {
1994
1614
  "resource": "agent.environments",
1995
1615
  "method": "list",
@@ -2278,7 +1898,7 @@ export const operations = [
2278
1898
  "resource": "agent.sessions",
2279
1899
  "method": "create",
2280
1900
  "summary": "Create session",
2281
- "description": "Create a session: one conversation with an agent. Pass agent as an agent id or {type:\"agent\", id, version?}; an id alone, or an object without version, pins the agent's active_version (the version chosen with agents.versions.apply, not necessarily the newest saved one). Unlike Anthropic Managed Agents, omit environment_id to use the default environment saved in the agent version (light for a new agent), unless computer_id (explicit, or the agent's default) selects a Computer; pass an environment id for a sandbox recipe. For service agents, explicit null allocates no machine, so codemode, bash and other machine tools are unavailable. Optional model must be one of the agent's allowed models; optional thinking is {effort: low|medium|high|xhigh|max|none} or null, where null inherits the agent default and then the model default (none requires the model to allow disabling thinking). Selections are saved before initial_events run; invalid ones return 400 invalid_request_error. Unlike Anthropic Managed Agents, the only inline agent override is system ({type:\"agent_with_overrides\", id, system}); to change the model, tools, MCP servers or skills, save a version instead. Supports vault_ids, up to 50, owned by the current organization and not archived; credential injection is deferred to a later version. budget is {type:\"limit\", max_list_cost:{amount, currency:\"USD\"}} where amount is a positive integer string of US cents (\"2000\" is USD 20.00); omitted budget defaults to \"2000\" and null removes the limit. Up to 500 file resources can be attached. Use initial_events to send a first user.message in this request, or send messages afterwards with sessions.events.send. The returned status can still be idle before initial events run; read agent.message and the subsequent session.status_idle event to confirm completion.",
1901
+ "description": "Create a session: one conversation with an agent. Pass agent as an agent id or {type:\"agent\", id, version?}; an id alone, or an object without version, pins the agent's active_version (the version chosen with agents.versions.apply, not necessarily the newest saved one). Unlike Anthropic Managed Agents, omit environment_id to use the default environment saved in the agent version (light for a new agent), unless computer_id (explicit, or the agent's default) selects a Computer; pass an environment id for a sandbox recipe. For service agents, explicit null allocates no machine, so codemode, bash and other machine tools are unavailable. Optional model must be one of the agent's allowed models; optional thinking is {effort: low|medium|high|xhigh|max|none} or null, where null inherits the agent default and then the model default (none requires the model to allow disabling thinking). Selections are saved before initial_events run; invalid ones return 400 invalid_request_error. Unlike Anthropic Managed Agents, the only inline agent override is system ({type:\"agent_with_overrides\", id, system}); to change the model, tools, MCP servers or skills, save a version instead. Supports vault_ids, up to 50, owned by the current organization and not archived; credential injection is deferred to a later version. budget is {type:\"limit\", max_list_cost:{amount, currency:\"USD\"}} where amount is a positive decimal string of US dollars with at most 2 decimal places (\"20.00\" is USD 20.00); omitted budget defaults to \"20.00\" and null removes the limit. Up to 500 file resources can be attached. Use initial_events to send a first user.message in this request, or send messages afterwards with sessions.events.send. The returned status can still be idle before initial events run; read agent.message and the subsequent session.status_idle event to confirm completion.",
2282
1902
  "http": "POST",
2283
1903
  "path": "/agent/v1/sessions",
2284
1904
  "streaming": "no",
@@ -2567,7 +2187,7 @@ export const operations = [
2567
2187
  "resource": "agent.sessions",
2568
2188
  "method": "compact",
2569
2189
  "summary": "Compact Session (Extension)",
2570
- "description": "Request session context compaction and retrieve an operation receipt.\n\nAvailable only on /agent/v1. The body may be omitted or {}. Optional instructions must be a string and is forwarded unchanged. Idempotency-Key is forwarded unchanged; a UUID is generated when absent. Returns { type: session_compaction, id, status, reason? }, where id is the operation ID. queued/running return 202; skipped/succeeded/failed return 200. Non-string instructions return 400 invalid_request_error. Missing or inaccessible managed sessions return 404 not_found_error.",
2190
+ "description": "Request session context compaction and retrieve an operation receipt.\n\nAvailable only on /agent/v1. The body may be omitted or {}. Optional instructions must be a string and is forwarded unchanged. Idempotency-Key is forwarded unchanged; a UUID is generated when absent. Returns { type: session_compaction, id, status, reason? }, where id is the operation ID. queued/running return 202; skipped/succeeded/failed/cancelled return 200. Non-string instructions return 400 invalid_request_error. Missing or inaccessible managed sessions return 404 not_found_error.",
2571
2191
  "http": "POST",
2572
2192
  "path": "/agent/v1/sessions/{session_id}/compact",
2573
2193
  "streaming": "no",
@@ -2619,7 +2239,7 @@ export const operations = [
2619
2239
  "resource": "agent.sessions.compactions",
2620
2240
  "method": "list",
2621
2241
  "summary": "List Session Compactions (Extension)",
2622
- "description": "Read session compaction history and summaries.\n\nAvailable only on /agent/v1. Returns { data: [...] }. Each entry contains type, id, event_id, trigger, status, model, compacted_message_count, input_tokens_before, input_tokens_after, summary, error and created_at, as recorded by the service. Missing or inaccessible managed sessions return 404 not_found_error.",
2242
+ "description": "Read session compaction history and summaries.\n\nAvailable only on /agent/v1. Returns { data: [...], active }. active is the queued or running compaction ({ type: session_compaction, id, status, trigger: manual|auto }), or null when none; manual work takes precedence. Each data entry contains type, id, event_id, trigger, status, model, compacted_message_count, input_tokens_before, input_tokens_after, summary, error and created_at, as recorded by the service. Missing or inaccessible managed sessions return 404 not_found_error.",
2623
2243
  "http": "GET",
2624
2244
  "path": "/agent/v1/sessions/{session_id}/compactions",
2625
2245
  "streaming": "no",
@@ -2831,9 +2451,9 @@ export const operations = [
2831
2451
  "query": [
2832
2452
  {
2833
2453
  "name": "limit",
2834
- "type": "number",
2454
+ "type": "integer",
2835
2455
  "required": false,
2836
- "description": "Number of items per page."
2456
+ "description": "Number of resources per page, from 1 to 100; defaults to 100."
2837
2457
  },
2838
2458
  {
2839
2459
  "name": "page",
@@ -4193,7 +3813,7 @@ export const operations = [
4193
3813
  "resource": "automation.actions",
4194
3814
  "method": "list",
4195
3815
  "summary": "List actions",
4196
- "description": "Discover callable Actions and their ns/name references without executing them. Combine each returned namespace and name as ns/name; Action calls use the current revision and do not accept @version or @tag. Filter by name or description; results include seven-day statistics and revision summaries without implementation source. Archived actions are excluded by default.",
3816
+ "description": "Discover callable Actions and their ns/name references without executing them. Combine each returned namespace and name as ns/name; Action calls use the current revision and do not accept @version or @tag. Filter by name or description; results include seven-day statistics and revision summaries without implementation source. Archived actions are excluded by default. List items carry no input contract: get the action and read current_revision.input_schema. Call it with call(\"ns/name\", input) in a script or call: ns/name with with: in a workflow.",
4197
3817
  "http": "GET",
4198
3818
  "path": "/automation/v1/actions",
4199
3819
  "streaming": "no",
@@ -4362,7 +3982,7 @@ export const operations = [
4362
3982
  "resource": "automation.actions",
4363
3983
  "method": "retrieve",
4364
3984
  "summary": "Get an Action with its current input and output JSON Schemas",
4365
- "description": "Read the Action and its full current implementation, with input and output JSON Schemas at current_revision.input_schema and current_revision.output_schema. To read a built-in Action, use ns=praxis and name=<bare name>, for example name=ocr; invoke it in a script with call(\"ocr\", input). The response ETag is the current revision ID for conditional updates.",
3985
+ "description": "Read the Action and its full current implementation, with input and output JSON Schemas at current_revision.input_schema and current_revision.output_schema. To read a built-in Action, use ns=praxis and name=<bare name>, for example name=ocr; invoke it in a script with call(\"ocr\", input) or in a workflow step with call: ocr and with:. Input that breaks the contract returns INPUT_INVALID, with the fields in errors[]. The response ETag is the current revision ID for conditional updates.",
4366
3986
  "http": "GET",
4367
3987
  "path": "/automation/v1/actions/{ns}/{name}",
4368
3988
  "streaming": "no",
@@ -4778,6 +4398,177 @@ export const operations = [
4778
4398
  "fields": []
4779
4399
  }
4780
4400
  },
4401
+ {
4402
+ "resource": "automation.humanTasks",
4403
+ "method": "list",
4404
+ "summary": "List human tasks",
4405
+ "description": "List the human tasks that praxis/approval workflow steps opened, newest first. By default it returns only open tasks assigned to the caller: their approval inbox. scope=all lists every task of the organization, and status and run_id narrow the list. Use a returned id with retrieve for details and respond to decide. Read-only: listing never changes a task.",
4406
+ "http": "GET",
4407
+ "path": "/automation/v1/human-tasks",
4408
+ "streaming": "no",
4409
+ "pagination": true,
4410
+ "pathParams": [],
4411
+ "query": [
4412
+ {
4413
+ "name": "limit",
4414
+ "type": "integer",
4415
+ "required": false,
4416
+ "description": "Page size, 1–100, default 50."
4417
+ },
4418
+ {
4419
+ "name": "cursor",
4420
+ "type": "string",
4421
+ "required": false,
4422
+ "description": "The next_cursor of the previous page; omit for the first page."
4423
+ },
4424
+ {
4425
+ "name": "status",
4426
+ "type": "array",
4427
+ "itemType": "string",
4428
+ "enum": [
4429
+ "open",
4430
+ "completed",
4431
+ "expired",
4432
+ "cancelled"
4433
+ ],
4434
+ "required": false,
4435
+ "description": "Filter by status, comma-separated: open, completed, expired, cancelled. Defaults to open."
4436
+ },
4437
+ {
4438
+ "name": "run_id",
4439
+ "type": "string",
4440
+ "required": false,
4441
+ "description": "Only tasks opened by this run (run_)."
4442
+ },
4443
+ {
4444
+ "name": "scope",
4445
+ "type": "string",
4446
+ "enum": [
4447
+ "assigned",
4448
+ "all"
4449
+ ],
4450
+ "required": false,
4451
+ "description": "assigned (default) lists only tasks assigned to the caller; all lists every task of the organization."
4452
+ }
4453
+ ]
4454
+ },
4455
+ {
4456
+ "resource": "automation.humanTasks",
4457
+ "method": "retrieve",
4458
+ "summary": "Retrieve a human task",
4459
+ "description": "Read one human task - title, Markdown body, context, actions, form, assignees, mode, due time, responses and outcome - so an assignee can choose an action and fill the form. Read-only; the Console approval page /automation/tasks/{id} reads the same resource.",
4460
+ "http": "GET",
4461
+ "path": "/automation/v1/human-tasks/{id}",
4462
+ "streaming": "no",
4463
+ "pagination": false,
4464
+ "pathParams": [
4465
+ {
4466
+ "name": "id",
4467
+ "sdkName": "id",
4468
+ "description": "Human task ID (htask_), from the list or the run's waits."
4469
+ }
4470
+ ],
4471
+ "query": []
4472
+ },
4473
+ {
4474
+ "resource": "automation.humanTasks",
4475
+ "method": "cancel",
4476
+ "summary": "Cancel a human task",
4477
+ "description": "Cancel an open human task; only the person who started the run or an organization API key may cancel. The task becomes cancelled and the waiting workflow step raises a runtime error with code HUMAN_TASK_CANCELLED, which try/catch can catch. Open tasks are cancelled automatically when their run ends, so this call is not needed then.",
4478
+ "http": "POST",
4479
+ "path": "/automation/v1/human-tasks/{id}/cancel",
4480
+ "streaming": "no",
4481
+ "pagination": false,
4482
+ "pathParams": [
4483
+ {
4484
+ "name": "id",
4485
+ "sdkName": "id",
4486
+ "description": "Human task ID (htask_)."
4487
+ }
4488
+ ],
4489
+ "query": [],
4490
+ "body": {
4491
+ "required": false,
4492
+ "fields": [
4493
+ {
4494
+ "name": "reason",
4495
+ "type": "string",
4496
+ "required": false,
4497
+ "description": "Optional cancellation reason, at most 500 characters."
4498
+ }
4499
+ ]
4500
+ }
4501
+ },
4502
+ {
4503
+ "resource": "automation.humanTasks",
4504
+ "method": "delegate",
4505
+ "summary": "Delegate a human task",
4506
+ "description": "An assignee who has not responded hands their place to another user (to_user), replacing their entry in assignees.users in place, so sequential order is kept. The new user cannot already be an assignee, nor the initiator unless self-approval is allowed. The task must still be open.",
4507
+ "http": "POST",
4508
+ "path": "/automation/v1/human-tasks/{id}/delegate",
4509
+ "streaming": "no",
4510
+ "pagination": false,
4511
+ "pathParams": [
4512
+ {
4513
+ "name": "id",
4514
+ "sdkName": "id",
4515
+ "description": "Human task ID (htask_)."
4516
+ }
4517
+ ],
4518
+ "query": [],
4519
+ "body": {
4520
+ "required": true,
4521
+ "fields": [
4522
+ {
4523
+ "name": "to_user",
4524
+ "type": "string",
4525
+ "required": true,
4526
+ "description": "User ID taking over; cannot already be an assignee, nor the initiator unless self-approval is allowed."
4527
+ }
4528
+ ]
4529
+ }
4530
+ },
4531
+ {
4532
+ "resource": "automation.humanTasks",
4533
+ "method": "respond",
4534
+ "summary": "Respond to a human task",
4535
+ "description": "Submit an action (action_id), form values (values) and a comment as the calling user. Depending on the task's mode the response either decides it (status becomes completed, outcome is set, and the waiting workflow resumes with outcome as the step output) or is recorded while other assignees are awaited. When two assignees respond at once, exactly one decides and the other gets TASK_CLOSED. An agent may respond only if the workflow set allow_agent_decision. Send an Idempotency-Key to retry safely.",
4536
+ "http": "POST",
4537
+ "path": "/automation/v1/human-tasks/{id}/respond",
4538
+ "streaming": "no",
4539
+ "pagination": false,
4540
+ "pathParams": [
4541
+ {
4542
+ "name": "id",
4543
+ "sdkName": "id",
4544
+ "description": "Human task ID (htask_)."
4545
+ }
4546
+ ],
4547
+ "query": [],
4548
+ "body": {
4549
+ "required": true,
4550
+ "fields": [
4551
+ {
4552
+ "name": "action_id",
4553
+ "type": "string",
4554
+ "required": true,
4555
+ "description": "The chosen action ID from the task's actions, for example approve."
4556
+ },
4557
+ {
4558
+ "name": "values",
4559
+ "type": "object",
4560
+ "required": false,
4561
+ "description": "Any JSON object whose keys are strings and whose values are any JSON value."
4562
+ },
4563
+ {
4564
+ "name": "comment",
4565
+ "type": "string",
4566
+ "required": false,
4567
+ "description": "Comment of at most 4000 characters; required when the action has require_comment true."
4568
+ }
4569
+ ]
4570
+ }
4571
+ },
4781
4572
  {
4782
4573
  "resource": "automation.resolve",
4783
4574
  "method": "retrieve",
@@ -4958,7 +4749,7 @@ export const operations = [
4958
4749
  "resource": "automation.runs",
4959
4750
  "method": "create",
4960
4751
  "summary": "Run a published target or execute draft source",
4961
- "description": "Execute a published script or workflow with target, or test unpublished code directly with source and language (ts for TypeScript, yaml for workflow YAML), without first saving or publishing a definition. Minimal script: `export default async ({ file_id }: { file_id: string }) => { const result = await call(\"ocr\", { document: { type: \"file\", file_id } }); return result; }`; send it as source with language=\"ts\", input={\"file_id\":\"<uploaded file ID>\"} and wait=0, using a PDF or image already uploaded to your account. To call a platform API directly in the same script, use the praxis SDK object, for example `praxis.model.ocr.create({ body: { model: \"glm-ocr\", document: { type: \"file\", file_id } } })`; Action IDs are strings passed to call(), not SDK methods such as praxis.ocr(...). praxis, call, invoke, console and codemode are module-scope bindings, not on globalThis, and need no import; invoke(\"namespace/name\", input) starts a child run. target and source are mutually exclusive; target accepts ns/name@version, @tag or @range and defaults to latest when @ is omitted. Source/input validation precedes run creation, so a separate validate call is optional. input defaults to {} and must match the input schema and fit within 1 MiB. wait is 0–60 seconds (default 0): a terminal run returns 200, otherwise 202. Use the returned id with praxis.automation.runs.retrieve and inspect status, output and error; acceptance does not mean successful completion. For long-running, background or batch work, use wait: 0 and poll the run, or split work into child runs or a workflow; wait only controls the response wait and does not extend execution limits. Actions time out after 30 s (run-sandbox after 10 min); scripts have a 5 min wall-clock limit and a 30 s CPU limit; workflows default to 24 h and allow up to 7 days. Each run can start at most 100 child runs, with at most 20 active at once; nesting depth is limited to 10. Idempotency-Key is scoped to tenant, method and path for 24 hours, excluding wait from the fingerprint; replay returns the current run with Idempotent-Replayed: true, changed contents return 422 and an in-flight request returns 409. New non-deterministic run IDs contain 78 characters, compared with 46 for legacy random IDs; treat IDs as opaque strings. Historical and deterministic IDs remain valid; same-millisecond order is not guaranteed.",
4752
+ "description": "Execute a published script or workflow with target, or test unpublished code directly with source and language (ts for TypeScript, yaml for workflow YAML), without first saving or publishing a definition. Minimal script: `export default async ({ file_id }: { file_id: string }) => { const result = await call(\"ocr\", { document: { type: \"file\", file_id } }); return result; }`; send it as source with language=\"ts\", input={\"file_id\":\"<uploaded file ID>\"} and wait=0, using a PDF or image already uploaded to your account. To call a platform API directly in the same script, use the praxis SDK object, for example `praxis.model.ocr.create({ body: { model: \"glm-ocr\", document: { type: \"file\", file_id } } })`; Action IDs are strings passed to call(), not SDK methods such as praxis.ocr(...). praxis, call, invoke, console and codemode are module-scope bindings, not on globalThis, and need no import; invoke(\"namespace/name\", input) starts a child run. target and source are mutually exclusive; target accepts ns/name@version, @tag or @range and defaults to latest when @ is omitted. Source/input validation precedes run creation, so a separate validate call is optional. input defaults to {} and must match the input schema and fit within 1 MiB. wait is 0–60 seconds (default 0): a terminal run returns 200, otherwise 202. Use the returned id with praxis.automation.runs.retrieve and inspect status, output and error; acceptance does not mean successful completion. For long-running, background or batch work, use wait: 0 and poll the run, or split work into child runs or a workflow; wait only controls the response wait and does not extend execution limits. Actions time out after 30 s (run-sandbox after 10 min); scripts have a 5 min wall-clock limit and a 30 s CPU limit; workflows default to 24 h and allow up to 30 days. Each run can start at most 100 child runs, with at most 20 active at once; nesting depth is limited to 10. Idempotency-Key is scoped to tenant, method and path for 24 hours, excluding wait from the fingerprint; replay returns the current run with Idempotent-Replayed: true, changed contents return 422 and an in-flight request returns 409. With language=yaml, source is a workflow YAML: the run input is . in the first step, and the shape is described in create workflow. Error details are in errors[] (pointer, detail, hint). New non-deterministic run IDs contain 78 characters, compared with 46 for legacy random IDs; treat IDs as opaque strings. Historical and deterministic IDs remain valid; same-millisecond order is not guaranteed.",
4962
4753
  "http": "POST",
4963
4754
  "path": "/automation/v1/runs",
4964
4755
  "streaming": "no",
@@ -5450,7 +5241,7 @@ export const operations = [
5450
5241
  "resource": "automation.scripts",
5451
5242
  "method": "create",
5452
5243
  "summary": "Create a script",
5453
- "description": "Save a TypeScript script as an editable draft for later reuse; this does not publish or start a run. Choose your own namespace without registering it first; praxis is reserved for built-in Actions. Scripts and workflows share names within the tenant; a duplicate returns NAME_TAKEN. The draft is a source string with a default-exported function, for example `export default async (input: {name: string}) => ({greeting: \"Hello, \" + input.name});`. Scripts provide praxis, call, invoke, console and codemode as module-scope bindings, not on globalThis, with no import needed: praxis.<domain>.<resource>.<method>(...) calls a platform API, call(\"ocr\", input) calls a built-in Action, and invoke(\"namespace/name\", input) starts a child run. Action IDs are strings (bare names for built-ins, namespace/name for your own Actions); praxis.ocr(...) does not exist. To test it, pass that source and language=ts to praxis.automation.runs.create without publishing. To publish later, use the returned draft.revision as expected_draft_revision.",
5244
+ "description": "Save a TypeScript script as an editable draft for later reuse; this does not publish or start a run. Choose your own namespace without registering it first; praxis is reserved for built-in Actions. Scripts and workflows share names within the tenant; a duplicate returns NAME_TAKEN. The draft is a source string with a default-exported function, for example `export default async (input: {name: string}) => ({greeting: \"Hello, \" + input.name});`. Scripts provide praxis, call, invoke, console and codemode as module-scope bindings, not on globalThis, with no import needed: praxis.<domain>.<resource>.<method>(...) calls a platform API, call(\"ocr\", input) calls a built-in Action, and invoke(\"namespace/name\", input) starts a child run. Action IDs are strings (bare names for built-ins, namespace/name for your own Actions); praxis.ocr(...) does not exist. The return value is limited to 1 MiB: write large results to a file with call(\"write-file\", ...) and return the file ID. A call error carries errors[] (pointer, detail, hint); String(e) is only the summary. To test it, pass that source and language=ts to praxis.automation.runs.create without publishing. To publish later, use the returned draft.revision as expected_draft_revision.",
5454
5245
  "http": "POST",
5455
5246
  "path": "/automation/v1/scripts",
5456
5247
  "streaming": "no",
@@ -6399,7 +6190,7 @@ export const operations = [
6399
6190
  "resource": "automation.validate",
6400
6191
  "method": "create",
6401
6192
  "summary": "Validate a definition",
6402
- "description": "Check source without executing it when you need diagnostics, inferred schemas or references. This is optional before praxis.automation.runs.create, which also validates source before execution. Actions, scripts and workflows are supported; results include validity without saving. Invalid source is reported with valid=false. Script/action output schemas are inferred from return types: Promise unwrapping, Record, intersections and Date. Unknown types yield an empty schema and a warning in warnings. Source diagnostics use /source or /implementation/source with 1-based line/column. For kind=action the same admission checks as action creation apply (no external imports, platform operations only as direct call(praxis/<api>.<op>, input) calls, no agent or automation calls), so source that validates is not rejected at creation.",
6193
+ "description": "Check source without executing it when you need diagnostics, inferred schemas or references. This is optional before praxis.automation.runs.create, which also validates source before execution. Actions, scripts and workflows are supported; results include validity without saving. Invalid source is reported with valid=false. Script/action output schemas are inferred from return types: Promise unwrapping, Record, intersections and Date. Unknown types yield an empty schema and a warning in warnings. Source diagnostics use /source or /implementation/source with 1-based line/column. For kind=action the same admission checks as action creation apply (no external imports, platform operations only as direct call(praxis/<api>.<op>, input) calls, no agent or automation calls), so source that validates is not rejected at creation. For kind=workflow the YAML needs document (dsl, namespace, name, version) and do; each problem is one entry in errors[] (pointer, detail, hint), so read the first one. A listen outside the supported subset (to.all, inside a fork) and emit are not reported here and fail with DEFINITION_INVALID only when a run is created. Workflow syntax reference: https://deepraxis.com/docs/developers/automation/reference/workflow-syntax.",
6403
6194
  "http": "POST",
6404
6195
  "path": "/automation/v1/validate",
6405
6196
  "streaming": "no",
@@ -6506,7 +6297,7 @@ export const operations = [
6506
6297
  "resource": "automation.workflows",
6507
6298
  "method": "create",
6508
6299
  "summary": "Create a workflow",
6509
- "description": "Save a YAML workflow as an editable draft without publishing or starting a run. Choose your own namespace without registering it first; praxis is reserved for built-in Actions. To test the draft, send its source and language=yaml to praxis.automation.runs.create. Scripts and workflows share names within the tenant; a duplicate returns NAME_TAKEN. run.workflow accepts ns/name@range or {namespace, name, version, input}; run.script uses the same reference shape as a platform extension. Object namespace, name and version are required; version accepts an exact version, dist-tag or range, locked at publication. Object input defaults to {} and supports expressions; string references retain task-level with. run.await defaults to true and returns the child output. With false, the child uses detach and the task immediately returns {run_id}; parent cancellation does not cascade. Inline script.code returns DEFINITION_INVALID with a detail asking you to save a script and reference it first. raise.error retains its type URI, status, title and detail in the run error.",
6300
+ "description": "Workflow syntax reference: https://deepraxis.com/docs/developers/automation/reference/workflow-syntax. Save a YAML workflow as an editable draft; this does not validate, publish or run it, so check it with validate (kind=workflow) first. Minimal draft: document with dsl (\"1.0.3\"), namespace, name and version, plus a do list of steps, for example document: {dsl: \"1.0.3\", namespace: demo, name: add, version: \"1.0.0\"} and do: [{first: {call: demo/add-one, with: {n: \"${ .n }\"}}}]. call: <ns/name> calls an Action directly (bare name for built-ins such as ocr) and with is the Action input; the input contract is at current_revision.input_schema in the get-action response. run: starts a saved script or child workflow. The run input is . in the first step, and expressions are jq written as a whole ${ ... } string. Limits: Action 30 s (run-sandbox 10 min), workflow 24 h by default and 30 days at most, payload 1 MiB. Test the draft by sending its source and language=yaml to praxis.automation.runs.create. Guide: /docs/developers/automation/guides/write-workflow. Error details are in the errors[] of the response (pointer, detail, hint). Choose your own namespace without registering it first; praxis is reserved for built-in Actions. Scripts and workflows share names within the tenant; a duplicate returns NAME_TAKEN. run.workflow accepts ns/name@range or {namespace, name, version, input}; run.script uses the same reference shape as a platform extension. Object namespace, name and version are required; version accepts an exact version, dist-tag or range, locked at publication. Object input defaults to {} and supports expressions; string references retain task-level with. run.await defaults to true and returns the child output. With false, the child uses detach and the task immediately returns {run_id}; parent cancellation does not cascade. Inline script.code returns DEFINITION_INVALID with a detail asking you to save a script and reference it first. raise.error retains its type URI, status, title and detail in the run error.",
6510
6301
  "http": "POST",
6511
6302
  "path": "/automation/v1/workflows",
6512
6303
  "streaming": "no",
@@ -6576,7 +6367,7 @@ export const operations = [
6576
6367
  "resource": "automation.workflows",
6577
6368
  "method": "update",
6578
6369
  "summary": "Update a workflow draft",
6579
- "description": "Update description, labels or draft with the current draft revision in If-Match. Even metadata-only updates create a new draft revision.",
6370
+ "description": "Update description, labels or draft with the current draft revision in If-Match, taken from draft.revision in the get-workflow response. Even metadata-only updates create a new draft revision. A mismatch returns 412 PRECONDITION_FAILED; read the draft again, merge and retry. The draft is not validated here, so check it with validate (kind=workflow) before publishing. Error details are in errors[]. See the workflow syntax reference at https://deepraxis.com/docs/developers/automation/reference/workflow-syntax.",
6580
6371
  "http": "PATCH",
6581
6372
  "path": "/automation/v1/workflows/{ns}/{name}",
6582
6373
  "streaming": "no",
@@ -6814,7 +6605,7 @@ export const operations = [
6814
6605
  "publish"
6815
6606
  ],
6816
6607
  "summary": "Publish a workflow version",
6817
- "description": "Publish a saved definition from its draft or an ad hoc run as a reusable version for named runs or triggers, validating the definition and locking dependencies. To test unpublished code, use praxis.automation.runs.create with source and language instead. Use draft.revision from create or retrieve as expected_draft_revision. The draft must match expected_draft_revision; an ad hoc run requires from_run and expected_source_sha256. The same version and contents return the existing version; different contents return VERSION_EXISTS, prereleases require an explicit tag (not latest, URL-safe characters only, not a version or range; violations return TAG_REQUIRED or TAG_INVALID with the complete rules in hint), and invalid definitions return DEFINITION_INVALID. Stable releases automatically advance latest only above the highest existing stable version; workflows becoming latest synchronize their declared schedule. String and object run.workflow/run.script references share version resolution and dependency locking. Publishing removes +build metadata from the version number.",
6608
+ "description": "Publish a saved definition from its draft or an ad hoc run as a reusable version for named runs or triggers, validating the definition and locking dependencies. To test unpublished code, use praxis.automation.runs.create with source and language instead. Use draft.revision from create or retrieve as expected_draft_revision. The draft must match expected_draft_revision; an ad hoc run requires from_run and expected_source_sha256. The same version and contents return the existing version; different contents return VERSION_EXISTS, prereleases require an explicit tag (not latest, URL-safe characters only, not a version or range; violations return TAG_REQUIRED or TAG_INVALID with the complete rules in hint), and invalid definitions return DEFINITION_INVALID. Stable releases automatically advance latest only above the highest existing stable version; workflows becoming latest synchronize their declared schedule. String and object run.workflow/run.script references share version resolution and dependency locking. Publishing removes +build metadata from the version number. For a workflow, document namespace, name and version must equal the publish target, otherwise DEFINITION_IDENTITY_MISMATCH; where a DEFINITION_INVALID failure sits is listed in errors[] (pointer, detail, hint).",
6818
6609
  "http": "POST",
6819
6610
  "path": "/automation/v1/workflows/{ns}/{name}/versions",
6820
6611
  "streaming": "no",
@@ -8498,7 +8289,7 @@ export const operations = [
8498
8289
  "resource": "file.files",
8499
8290
  "method": "create",
8500
8291
  "summary": "Upload file",
8501
- "description": "Upload a file to reuse in conversations or attach to a knowledge base. Unlike OpenAI Files, uploads must be nonempty and at most 100000000 bytes, and only user_data, assistants and vision purposes are accepted. Send file bytes as a multipart file part, not a filename or file ID; in the SDK use a File or Blob, for example new File([\"Return within 23 days.\"], \"policy.txt\", { type: \"text/plain\" }). Content determines the MIME type. Supported uploads include PDF, DOCX/XLSX/PPTX, PNG/JPEG/GIF/WebP, MP3/WAV/FLAC/OGG/M4A, MP4/WebM, and UTF-8 JSON/NDJSON/CSV/Markdown/plain text; empty, unsupported, oversized files and unsupported purposes return 400. Use Uploads for larger files. The purpose vision accepts only PNG, JPEG, GIF and WebP, while conversation images require user_data. The returned ID belongs to your tenant; upload alone does not ingest the file into Knowledge. Knowledge attachment has a lower limit of 100000000 bytes. Optionally set expires_after[anchor]=created_at with expires_after[seconds] (3600–2592000), or praxis[expires_in_seconds] (3600–7776000), never both. Without expiry, the file persists until deleted.",
8292
+ "description": "Upload a file to reuse in conversations or attach to a knowledge base. Unlike OpenAI Files, uploads must be nonempty and at most 100000000 bytes, and only user_data and vision purposes are accepted. Send file bytes as a multipart file part, not a filename or file ID; in the SDK use a File or Blob, for example new File([\"Return within 23 days.\"], \"policy.txt\", { type: \"text/plain\" }). Content determines the MIME type. Supported uploads include PDF, DOCX/XLSX/PPTX, PNG/JPEG/GIF/WebP, MP3/WAV/FLAC/OGG/M4A, MP4/WebM, and UTF-8 JSON/NDJSON/CSV/Markdown/plain text; empty, unsupported, oversized files and unsupported purposes return 400. Use Uploads for larger files. The purpose vision accepts only PNG, JPEG, GIF and WebP, while conversation images require user_data. The returned ID belongs to your tenant; upload alone does not ingest the file into Knowledge. Knowledge attachment has a lower limit of 100000000 bytes. Optionally set expires_after[anchor]=created_at with expires_after[seconds] (3600–7776000). Without expiry, the file persists until deleted.",
8502
8293
  "http": "POST",
8503
8294
  "path": "/file/v1/files",
8504
8295
  "streaming": "no",
@@ -8520,23 +8311,16 @@ export const operations = [
8520
8311
  "type": "string",
8521
8312
  "enum": [
8522
8313
  "user_data",
8523
- "assistants",
8524
8314
  "vision"
8525
8315
  ],
8526
8316
  "required": true,
8527
- "description": "Purpose label stored with the file: user_data, assistants or vision. The vision purpose accepts only PNG, JPEG, GIF and WebP images. Conversation image references require user_data."
8317
+ "description": "Purpose label stored with the file: user_data or vision. The vision purpose accepts only PNG, JPEG, GIF and WebP images. Conversation image references require user_data."
8528
8318
  },
8529
8319
  {
8530
8320
  "name": "expires_after",
8531
8321
  "type": "object",
8532
8322
  "required": false,
8533
8323
  "description": "Optional expiry relative to created_at. Files without an expiry persist until deleted."
8534
- },
8535
- {
8536
- "name": "praxis",
8537
- "type": "object",
8538
- "required": false,
8539
- "description": "Own-face extensions. Use at most one expiry setting."
8540
8324
  }
8541
8325
  ]
8542
8326
  }
@@ -8599,7 +8383,7 @@ export const operations = [
8599
8383
  "resource": "file.uploads",
8600
8384
  "method": "create",
8601
8385
  "summary": "Create an upload",
8602
- "description": "Start a multipart upload for a file larger than the 100000000-byte direct-upload limit. Supply the exact byte length, filename, MIME type and purpose. Unlike OpenAI, uploads accept at most 2 GiB (2147483648 bytes) and only user_data, assistants and vision purposes. Add parts of at most 64000000 bytes and complete within one hour. Optional part_size enables fixed-size, retryable parts. expires_after applies to the resulting file (3600–7776000 seconds on this own face); without it the file persists until deleted.",
8386
+ "description": "Start a multipart upload for a file larger than the 100000000-byte direct-upload limit. Supply the exact byte length, filename, MIME type and purpose. Unlike OpenAI, uploads accept at most 2 GiB (2147483648 bytes) and only user_data and vision purposes. Add parts of at most 64000000 bytes and complete within one hour. Optional part_size enables fixed-size, retryable parts. expires_after applies to the resulting file (3600–7776000 seconds on this own face); without it the file persists until deleted.",
8603
8387
  "http": "POST",
8604
8388
  "path": "/file/v1/uploads",
8605
8389
  "streaming": "no",
@@ -8632,11 +8416,10 @@ export const operations = [
8632
8416
  "type": "string",
8633
8417
  "enum": [
8634
8418
  "user_data",
8635
- "assistants",
8636
8419
  "vision"
8637
8420
  ],
8638
8421
  "required": true,
8639
- "description": "Use user_data for conversation attachments, assistants for assistant files, or vision for PNG, JPEG, GIF and WebP images."
8422
+ "description": "Use user_data for conversation attachments, or vision for PNG, JPEG, GIF and WebP images."
8640
8423
  },
8641
8424
  {
8642
8425
  "name": "expires_after",
@@ -9816,7 +9599,7 @@ export const operations = [
9816
9599
  "name": "overwrite",
9817
9600
  "type": "boolean",
9818
9601
  "required": false,
9819
- "description": "Allow replacing an existing public_id, preserving its asset_id and increasing its version. False returns the existing resource without replacing it; defaults to true."
9602
+ "description": "Allow replacing an existing public_id, preserving its asset_id and increasing its version. Only the latest version is deliverable; old version URLs return 404. Create a new public_id to retain old deliveries. False returns the existing resource without replacing it; defaults to true."
9820
9603
  },
9821
9604
  {
9822
9605
  "name": "tags",
@@ -9874,7 +9657,8 @@ export const operations = [
9874
9657
  {
9875
9658
  "name": "file_id",
9876
9659
  "type": "string",
9877
- "required": true
9660
+ "required": true,
9661
+ "description": "File ID to copy into this library; passed as the upload source instead of file bytes. This creates an independent public copy readable without authentication. Deleting the source File does not delete this asset; do not import confidential content."
9878
9662
  },
9879
9663
  {
9880
9664
  "name": "public_id",
@@ -9928,7 +9712,7 @@ export const operations = [
9928
9712
  "name": "overwrite",
9929
9713
  "type": "boolean",
9930
9714
  "required": false,
9931
- "description": "Allow replacing an existing public_id, preserving its asset_id and increasing its version. False returns the existing resource without replacing it; defaults to true."
9715
+ "description": "Allow replacing an existing public_id, preserving its asset_id and increasing its version. Only the latest version is deliverable; old version URLs return 404. Create a new public_id to retain old deliveries. False returns the existing resource without replacing it; defaults to true."
9932
9716
  },
9933
9717
  {
9934
9718
  "name": "tags",
@@ -10445,7 +10229,7 @@ export const operations = [
10445
10229
  "name": "expression",
10446
10230
  "type": "string",
10447
10231
  "required": false,
10448
- "description": "Asset filter expression supporting field comparisons, AND, OR, NOT, parentheses and suffix wildcards. An empty expression matches all assets."
10232
+ "description": "Asset filter expression supporting field comparisons, AND, OR, NOT, parentheses and suffix wildcards. An empty expression matches all assets. For business metadata use context.sku=KETTLE-RED AND context.revision=2; request with_field: [\"context\"] to include context."
10449
10233
  },
10450
10234
  {
10451
10235
  "name": "sort_by",
@@ -10591,6 +10375,70 @@ export const operations = [
10591
10375
  ]
10592
10376
  }
10593
10377
  },
10378
+ {
10379
+ "resource": "meta.docs",
10380
+ "method": "search",
10381
+ "summary": "Search platform documentation",
10382
+ "description": "Find guides and references by keyword before reading them with praxis.meta.docs.retrieve. Public; no API key required. Matches documentation titles, headings and page text without case sensitivity; all query words must occur. q is required; limit defaults to 20 and accepts 1–50. lang defaults to zh or use en for English. Returns paths, page titles, canonical URLs and short matching snippets; no matches returns an empty array.",
10383
+ "http": "GET",
10384
+ "path": "/meta/v1/docs/search",
10385
+ "streaming": "no",
10386
+ "pagination": false,
10387
+ "pathParams": [],
10388
+ "query": [
10389
+ {
10390
+ "name": "q",
10391
+ "type": "string",
10392
+ "required": true,
10393
+ "description": "Keywords describing the syntax or guide needed, for example export or workflow."
10394
+ },
10395
+ {
10396
+ "name": "limit",
10397
+ "type": "integer",
10398
+ "required": false,
10399
+ "description": "Maximum number of matching pages returned; integer 1–50, default 20."
10400
+ },
10401
+ {
10402
+ "name": "lang",
10403
+ "type": "string",
10404
+ "enum": [
10405
+ "zh",
10406
+ "en"
10407
+ ],
10408
+ "required": false,
10409
+ "description": "Documentation language: zh for Chinese (default), en for English."
10410
+ }
10411
+ ]
10412
+ },
10413
+ {
10414
+ "resource": "meta.docs",
10415
+ "method": "retrieve",
10416
+ "summary": "Read documentation Markdown",
10417
+ "description": "Read a platform guide or reference before implementing an unfamiliar capability. Public; no API key required. Take path from praxis.meta.docs.search, or use developers/automation/guides/write-workflow. Append #heading-id to path to read only that section, including its subsections. Encode the hash as %23 over HTTP; SDK callers pass it in the path string. lang defaults to zh; en selects the English page. Unknown pages or anchors return DOC_NOT_FOUND; search again for a valid path.",
10418
+ "http": "GET",
10419
+ "path": "/meta/v1/docs/{path}",
10420
+ "streaming": "no",
10421
+ "pagination": false,
10422
+ "pathParams": [
10423
+ {
10424
+ "name": "path",
10425
+ "sdkName": "path",
10426
+ "description": "Slash-separated documentation path from docs.search; optionally append #heading-id to select a section."
10427
+ }
10428
+ ],
10429
+ "query": [
10430
+ {
10431
+ "name": "lang",
10432
+ "type": "string",
10433
+ "enum": [
10434
+ "zh",
10435
+ "en"
10436
+ ],
10437
+ "required": false,
10438
+ "description": "Documentation language: zh for Chinese (default), en for English."
10439
+ }
10440
+ ]
10441
+ },
10594
10442
  {
10595
10443
  "resource": "meta.health",
10596
10444
  "method": "retrieve",