@deepraxis/sdk 0.1.1-dev.124112f → 0.1.1-dev.136df1c

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.
@@ -513,6 +513,30 @@ export const computersFilesContent = (options) => (options.client ?? client).get
513
513
  url: '/agent/v1/computers/{computer_id}/files/content',
514
514
  ...options
515
515
  });
516
+ /**
517
+ * Convert a Computer Document to PDF
518
+ *
519
+ * Convert an Office document (docx, doc, ppt, pptx, rtf, odt; up to 16 MiB) to PDF inside a platform-owned ephemeral document sandbox, whatever machine family the computer itself runs on. Returns base64 PDF bytes.
520
+ *
521
+ * Praxis extension: the preview conversion endpoint. The browser never parses an untrusted document — LibreOffice runs only inside an ephemeral document-family sandbox and the converter instance is killed after use. The file stays tenant-owned; non-convertible types answer EXTENSION_NOT_CONVERTIBLE and a failed conversion answers CONVERSION_FAILED.
522
+ */
523
+ export const computersFilesConvert = (options) => (options.client ?? client).post({
524
+ security: [{
525
+ key: 'BearerAuth',
526
+ scheme: 'bearer',
527
+ type: 'http'
528
+ }, {
529
+ key: 'ApiKeyAuth',
530
+ name: 'X-API-Key',
531
+ type: 'apiKey'
532
+ }],
533
+ url: '/agent/v1/computers/{computer_id}/files/convert',
534
+ ...options,
535
+ headers: {
536
+ 'Content-Type': 'application/json',
537
+ ...options.headers
538
+ }
539
+ });
516
540
  /**
517
541
  * Connect computer
518
542
  *
@@ -1092,7 +1116,7 @@ export const fileListFiles = (options) => (options?.client ?? client).get({
1092
1116
  /**
1093
1117
  * Upload file
1094
1118
  *
1095
- * 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.
1119
+ * 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–7776000). Without expiry, the file persists until deleted.
1096
1120
  */
1097
1121
  export const fileCreateFile = (options) => (options.client ?? client).post({
1098
1122
  ...formDataBodySerializer,
@@ -1169,7 +1193,7 @@ export const fileRetrieveFileContent = (options) => (options.client ?? client).g
1169
1193
  /**
1170
1194
  * Create an upload
1171
1195
  *
1172
- * 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.
1196
+ * 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 20 GiB (21474836480 bytes) and only user_data, assistants and vision purposes. Send parts of at most 64000000 bytes; an unfinished upload waits for them for 7 days, so a client can create → send parts → query GET /file/v1/uploads/{upload_id} → resend only the missing parts → complete. Optional part_size fixes every part length and makes each numbered part retryable with identical bytes. expires_after applies to the resulting file (3600–7776000 seconds on this own face); without it the file persists until deleted.
1173
1197
  */
1174
1198
  export const fileCreateUpload = (options) => (options.client ?? client).post({
1175
1199
  security: [{
@@ -1187,7 +1211,7 @@ export const fileCreateUpload = (options) => (options.client ?? client).post({
1187
1211
  /**
1188
1212
  * Add an upload part
1189
1213
  *
1190
- * Send one nonempty part as the multipart data field, at most 64000000 bytes. Parts may arrive concurrently in any order. Use upload_id from create. For a fixed-size upload, supply part_number starting at 1 and exactly part_size bytes except for the final remainder; retry the same number with identical bytes to recover its part ID. Without part_size, each request creates a new part and part_number is ignored. Save the returned part IDs for complete.
1214
+ * Send one nonempty part as the multipart data field, at most 64000000 bytes. Parts may arrive concurrently in any order. Use upload_id from create. For a fixed-size upload, supply part_number starting at 1 and exactly part_size bytes except for the final remainder; retry the same number with identical bytes to recover its part ID, and query GET /file/v1/uploads/{upload_id} to see which numbers already arrived. Without part_size, each request creates a new part and part_number is ignored. Save the returned part IDs for complete.
1191
1215
  */
1192
1216
  export const fileAddUploadPart = (options) => (options.client ?? client).post({
1193
1217
  ...formDataBodySerializer,
@@ -1206,7 +1230,7 @@ export const fileAddUploadPart = (options) => (options.client ?? client).post({
1206
1230
  /**
1207
1231
  * Complete an upload
1208
1232
  *
1209
- * Assemble the uploaded parts into a file. Supply upload_id from create and part_ids from addPart in file byte order; their sizes must total the declared bytes. Optional md5 verifies the assembled content. Retrying identical part_ids and normalized md5 returns the same result; different inputs return 409. Unlike OpenAI, completed can contain a file still processing (status uploaded). Poll files.retrieve using file.id until status processed (own face state active); error, expiry or 404 means processing failed and the file cannot be used.
1233
+ * Assemble the uploaded parts into a file. Supply upload_id from create and part_ids from addPart in file byte order; their sizes must total the declared bytes. When parts were lost, query GET /file/v1/uploads/{upload_id} and resend them before completing. Optional md5 verifies the assembled content. Retrying identical part_ids and normalized md5 returns the same result; different inputs return 409. Unlike OpenAI, completed can contain a file still processing (status uploaded). Poll files.retrieve using file.id until status processed (own face state active); error, expiry or 404 means processing failed and the file cannot be used.
1210
1234
  */
1211
1235
  export const fileCompleteUpload = (options) => (options.client ?? client).post({
1212
1236
  security: [{
@@ -1235,10 +1259,24 @@ export const fileCancelUpload = (options) => (options.client ?? client).post({
1235
1259
  url: '/file/v1/uploads/{upload_id}/cancel',
1236
1260
  ...options
1237
1261
  });
1262
+ /**
1263
+ * Retrieve an upload
1264
+ *
1265
+ * Read the state of an unfinished upload — its status, declared bytes, fixed part_size and the parts it already holds (received_parts, each with part_number, bytes and sha256). After a break or a failed part, call it to resend only the missing numbers, then complete. A cancelled or expired upload is refused; a completed one returns its file. A missing or other-organization upload returns 404.
1266
+ */
1267
+ export const fileRetrieveUpload = (options) => (options.client ?? client).get({
1268
+ security: [{
1269
+ key: 'BearerAuth',
1270
+ scheme: 'bearer',
1271
+ type: 'http'
1272
+ }],
1273
+ url: '/file/v1/uploads/{upload_id}',
1274
+ ...options
1275
+ });
1238
1276
  /**
1239
1277
  * Create a one-time upload URL
1240
1278
  *
1241
- * Upload a local file of up to 2 GiB from a coding agent without sending bytes through the model. Provide basename, exact byte count and MIME type. Up to 104857600 bytes, PUT the file to url with curl -T photo.png -H 'Content-Type: image/png' '<url>'; success returns 201 with the file object, and reuse returns 410 CAPABILITY_USED. Above that threshold, split the file into part_size chunks (default 64000000 bytes), PUT each chunk to its numbered parts[].url in any order, then POST complete_url without a body. Part PUTs return 200; completion returns 201 with the file object, including its state, or 400 if a part is missing. A processing file can be polled with files.retrieve until active. Identical part bytes may be retried; changed bytes at the same number return 400. Completion reuse returns 410 CAPABILITY_USED. Each PUT requires the exact signed Content-Length; single-PUT Content-Type must match content_type or be omitted. Expired, revoked, invalid, wrong-action or cross-organization URLs return 404. URL lifetime defaults to 900 seconds for single PUT or 3600 for multipart, at most 604800; all multipart URLs share an expiry. Multipart creation reserves storage quota. Issuance requires the same unscoped credential as direct file creation. Each issuance creates a new upload and is not idempotent. Example body: {"filename":"photo.png","bytes":2048,"content_type":"image/png"}.
1279
+ * Upload a local file of up to 20 GiB from a coding agent without sending bytes through the model. Provide basename, exact byte count and MIME type. Up to 104857600 bytes, PUT the file to url with curl -T photo.png -H 'Content-Type: image/png' '<url>'; success returns 201 with the file object, and reuse returns 410 CAPABILITY_USED. Above that threshold, split the file into part_size chunks (default 64000000 bytes) and PUT each chunk to its numbered parts[].url in any order; an interrupted client GETs status_url to see the received parts and resends only what is missing, then POSTs complete_url without a body. Part PUTs return 200; completion returns 201 with the file object, including its state, or 400 if a part is missing. A processing file can be polled with files.retrieve until active. Identical part bytes may be retried; changed bytes at the same number return 400. Completion reuse returns 410 CAPABILITY_USED. Each PUT requires the exact signed Content-Length; single-PUT Content-Type must match content_type or be omitted. Expired, revoked, invalid, wrong-action or cross-organization URLs return 404. URL lifetime defaults to 900 seconds for single PUT or 604800 (7 days) for multipart, at most 604800; all multipart URLs, including status_url, share an expiry. Multipart creation reserves storage quota. Issuance requires the same unscoped credential as direct file creation. Each issuance creates a new upload and is not idempotent. Example body: {"filename":"photo.png","bytes":2048,"content_type":"image/png"}.
1242
1280
  */
1243
1281
  export const fileCreateSignedUpload = (options) => (options.client ?? client).post({
1244
1282
  security: [{
@@ -1257,10 +1295,32 @@ export const fileCreateSignedUpload = (options) => (options.client ?? client).po
1257
1295
  ...options.headers
1258
1296
  }
1259
1297
  });
1298
+ /**
1299
+ * Create a download URL
1300
+ *
1301
+ * Download a file's bytes to a local disk from a coding agent without sending them through the model. Use file_id from file creation or listing, then run curl -fsSL -o <filename> '<url>' locally with the returned URL; GET needs no Authorization header. The link is reusable until expiry and supports a single byte Range (for example Range: bytes=0-9 returns 206). Revoke it with files.contentLinks.revoke, passing the token after /c/ in the URL. Expired, revoked, invalid or cross-organization URLs return 404. Lifetime defaults to 900 seconds and is at most 604800 seconds. Issuance requires the same credential and file-read access as files.retrieveContent; a processing file returns 409 FILE_NOT_READY, so poll files.retrieve until active before retrying. A missing, expired or other-organization file returns 404. Each issuance creates a new link. OpenAI Files has no signed download URL; this follows S3 presigned GET semantics. Example body: {"ttl_seconds":3600}.
1302
+ */
1303
+ export const fileCreateContentUrl = (options) => (options.client ?? client).post({
1304
+ security: [{
1305
+ key: 'BearerAuth',
1306
+ scheme: 'bearer',
1307
+ type: 'http'
1308
+ }, {
1309
+ key: 'ApiKeyAuth',
1310
+ name: 'X-API-Key',
1311
+ type: 'apiKey'
1312
+ }],
1313
+ url: '/file/v1/files/{file_id}/content_url',
1314
+ ...options,
1315
+ headers: {
1316
+ 'Content-Type': 'application/json',
1317
+ ...options.headers
1318
+ }
1319
+ });
1260
1320
  /**
1261
1321
  * Revoke a file content link
1262
1322
  *
1263
- * Stop a previously issued content link from reading a file. Use file_id from file creation or listing and the token path component from a content URL (/c/<token>), not the complete URL. The caller must own the file and have write access; a read-only binding is refused. Revocation propagates through the capability deny list within 30 seconds; the file and other links remain available. Only current IAM capability tokens can be revoked; legacy content links expire at the migration deadline. Example body: {"token":"<token from /c/>"}.
1323
+ * Stop a previously issued content link from reading a file. Obtain the link with files.contentUrl.create. Use file_id from file creation or listing and the token path component from a content URL (/c/<token>), not the complete URL. The caller must own the file and have write access; a read-only binding is refused. Revocation propagates through the capability deny list within 15 minutes; the file and other links remain available. Only current IAM capability tokens can be revoked; legacy content links expire at the migration deadline. Example body: {"token":"<token from /c/>"}.
1264
1324
  */
1265
1325
  export const fileRevokeContentLink = (options) => (options.client ?? client).post({
1266
1326
  security: [{
@@ -1966,6 +2026,24 @@ export const countResponseInputTokens = (options) => (options.client ?? client).
1966
2026
  ...options.headers
1967
2027
  }
1968
2028
  });
2029
+ /**
2030
+ * List organization members
2031
+ *
2032
+ * Concepts follow GitHub org members: find a person's user id, for example to assign an approver to an approval task. Lists only members of the organization behind your API key or runtime token, ordered by joined_at ascending (membership id breaks ties). Ask the user who should approve, then use that member's id. Emails are visible only within this organization. The request cannot select another organization. Pass next_page unchanged as page; null means the end. Read-only; no usage charge. Example: GET /organization/v1/members?limit=20.
2033
+ */
2034
+ export const listOrganizationMembers = (options) => (options?.client ?? client).get({
2035
+ security: [{
2036
+ key: 'BearerAuth',
2037
+ scheme: 'bearer',
2038
+ type: 'http'
2039
+ }, {
2040
+ key: 'ApiKeyAuth',
2041
+ name: 'X-API-Key',
2042
+ type: 'apiKey'
2043
+ }],
2044
+ url: '/organization/v1/members',
2045
+ ...options
2046
+ });
1969
2047
  /**
1970
2048
  * List your organization's feedback
1971
2049
  *
@@ -2450,7 +2528,7 @@ export const makeSandboxDirectory = (options) => (options.client ?? client).post
2450
2528
  /**
2451
2529
  * Run a command in the sandbox
2452
2530
  *
2453
- * Execute a shell command and wait for stdout, stderr and exitCode. Supply cmd, optional cwd and envs, and timeoutMs (1–60000 milliseconds, default 60000). Unlike E2B, this endpoint is synchronous only: no background mode, callbacks or unlimited timeout; output is bounded to 1 MiB including stream framing. Nonzero exit codes return 200 with the result. A timeout returns COMMAND_TIMEOUT (504); transport timeout does not confirm process termination, so do not blindly retry commands with side effects. Example body: {"cmd":"echo hi"}.
2531
+ * Execute a shell command and wait for stdout, stderr and exitCode. Supply cmd, optional cwd and envs, and timeoutMs (1–3600000 milliseconds, default 600000, that is 10 minutes; E2B defaults to 60000). Unlike E2B, this endpoint is synchronous only: no background mode, callbacks or unlimited timeout (timeoutMs 0); output is bounded to 1 MiB including stream framing. Nonzero exit codes return 200 with the result. A timeout returns COMMAND_TIMEOUT (504); transport timeout does not confirm process termination, so do not blindly retry commands with side effects. Example body: {"cmd":"echo hi"}.
2454
2532
  */
2455
2533
  export const runSandboxCommand = (options) => (options.client ?? client).post({
2456
2534
  security: [{
@@ -3835,7 +3913,7 @@ export const automationActionsGet = (options) => (options.client ?? client).get(
3835
3913
  /**
3836
3914
  * Update an action
3837
3915
  *
3838
- * Update after checking compatibility against the current and five recent revisions. Widening inputs and narrowing outputs are compatible, including length, item count, property count, type (integer/number), and multipleOf (the new input factor divides the old one; the reverse holds for outputs). dry_run=true returns only CompatResult and may omit If-Match; a supplied header is still checked, and * matches any existing representation. Normal updates require If-Match and return ActionDef with ETag; previews return no ETag. Omitted optional fields retain their existing values only for description and labels; when constructing a new revision, errors defaults to [], omitted annotations keys to false, timeout_ms to 30000, and message to null. Incompatible normal updates return 422 SCHEMA_INCOMPATIBLE with issues; unchanged contents retain the existing revision.
3916
+ * Update after checking compatibility against the current and five recent revisions. Widening inputs and narrowing outputs are compatible, including length, item count, property count, type (integer/number), and multipleOf (the new input factor divides the old one; the reverse holds for outputs). dry_run=true returns only CompatResult and may omit If-Match; a supplied header is still checked, and * matches any existing representation. Normal updates require If-Match and return ActionDef with ETag; previews return no ETag. Omitted optional fields retain their existing values only for description and labels; when constructing a new revision, errors defaults to [], omitted annotations keys to false, timeout_ms to 300000, and message to null. Incompatible normal updates return 422 SCHEMA_INCOMPATIBLE with issues; unchanged contents retain the existing revision.
3839
3917
  */
3840
3918
  export const automationActionsUpdate = (options) => (options.client ?? client).put({
3841
3919
  security: [{
@@ -4278,7 +4356,7 @@ export const automationWorkflowsList = (options) => (options?.client ?? client).
4278
4356
  /**
4279
4357
  * Create a workflow
4280
4358
  *
4281
- * 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. To pause for a person, call praxis/approval (it opens a human task; the step output is the decision); agents answer with praxis.automation.humanTasks.respond on behalf of their user. Guide: /docs/developers/automation/guides/approvals 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.
4359
+ * 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 5 min (run-sandbox 6 h), 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. To pause for a person, call praxis/approval (it opens a human task; the step output is the decision); agents answer with praxis.automation.humanTasks.respond on behalf of their user. Guide: /docs/developers/automation/guides/approvals 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.
4282
4360
  */
4283
4361
  export const automationWorkflowsCreate = (options) => (options.client ?? client).post({
4284
4362
  security: [{
@@ -4610,7 +4688,7 @@ export const automationRunsList = (options) => (options?.client ?? client).get({
4610
4688
  /**
4611
4689
  * Run a published target or execute draft source
4612
4690
  *
4613
- * 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.
4691
+ * 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 5 min (run-sandbox after 6 h); scripts have a 30 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 1,000 child runs, with at most 100 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.
4614
4692
  */
4615
4693
  export const automationRunsCreate = (options) => (options.client ?? client).post({
4616
4694
  security: [{
@@ -5392,6 +5470,28 @@ export const canvasRetrieveCanvas = (options) => (options.client ?? client).get(
5392
5470
  url: '/canvas/v1/canvases/{canvas_id}',
5393
5471
  ...options
5394
5472
  });
5473
+ /**
5474
+ * Update canvas
5475
+ *
5476
+ * Rename a canvas or move it to a collection without editing its design content. Use a canvas id from canvases.list and a collection id from collections.list. Send collection_id=null to make it uncategorized; omit either field to preserve its current value. A canvas belongs to at most one collection. The destination must belong to your organization. Renaming keeps the canvas version unchanged.
5477
+ */
5478
+ export const canvasUpdateCanvas = (options) => (options.client ?? client).patch({
5479
+ security: [{
5480
+ key: 'BearerAuth',
5481
+ scheme: 'bearer',
5482
+ type: 'http'
5483
+ }, {
5484
+ key: 'ApiKeyAuth',
5485
+ name: 'X-API-Key',
5486
+ type: 'apiKey'
5487
+ }],
5488
+ url: '/canvas/v1/canvases/{canvas_id}',
5489
+ ...options,
5490
+ headers: {
5491
+ 'Content-Type': 'application/json',
5492
+ ...options.headers
5493
+ }
5494
+ });
5395
5495
  /**
5396
5496
  * Read canvas nodes
5397
5497
  *
@@ -5431,10 +5531,21 @@ export const canvasListImages = (options) => (options.client ?? client).get({
5431
5531
  * const f = Insert(document, { type: "frame", name: "Hero", width: 1200, layout: "vertical", padding: 48, fill: "#FFFFFF" }); Insert(f, { type: "text", content: "Hello", fontSize: 32, fill: "#111111" }); Print(f)
5432
5532
  * ```
5433
5533
  *
5534
+ * Insert/Copy return the new node id; read the copy with Get(id) — copied descendants get new ids, so change them through Copy's third argument `descendants` keyed by the source node ids. To copy a page and change its title in the same script:
5535
+ *
5536
+ * ```js canvas-example="copy-page"
5537
+ * const page = Insert(document, {type:"frame",name:"Original",width:320,height:160,layout:"vertical",padding:16});
5538
+ * const title = Insert(page, {type:"text",name:"Title",content:"Original",fontSize:24});
5539
+ * const copy = Copy(page, document, {name:"Copy",x:360,descendants:{[title]:{content:"Updated"}}});
5540
+ * Print(copy); Print(Get(copy).children[0].content);
5541
+ * ```
5542
+ *
5434
5543
  * Use viewer_url to watch the result in Console. TakeScreenshot records node ids in screenshots; call images.list with those ids to fetch PNG data URLs. See the [Canvas execute reference](https://deepraxis.com/en/docs/api/native/canvas/execute) for request fields and results, and the [Canvas node reference](https://deepraxis.com/en/docs/developers/canvas/nodes) for node content.
5435
5544
  *
5436
5545
  * A successful write increments version by one. Optionally set expected_version to the version from retrieve or nodes.list; on 409 REVISION_CONFLICT read again, merge your intent and retry with the current version. Every script failure rolls back all writes. On 400 SCRIPT_ERROR, SCRIPT_LIMIT or OPS_REJECTED, use error.details.edit_id plus edits to repair and rerun the stored source without resending the entire script; details may include line, column and rejection. On 400 EDIT_EXPIRED the saved script is older than ten minutes: submit a corrected new script. On 429 CANVAS_BUSY, more than four calls are queued for this canvas: wait for pending calls before retrying.
5437
5546
  *
5547
+ * Execution errors include error.details.prints containing output printed before failure, with the same string-array shape and output limit as successful prints; rolled-back writes still create no version.
5548
+ *
5438
5549
  */
5439
5550
  export const canvasExecute = (options) => (options.client ?? client).post({
5440
5551
  security: [{
@@ -5450,11 +5561,11 @@ export const canvasExecute = (options) => (options.client ?? client).post({
5450
5561
  }
5451
5562
  });
5452
5563
  /**
5453
- * List projects
5564
+ * List collections
5454
5565
  *
5455
- * Discover projects owned by the API key organization and obtain project_id values. Results default to active projects ordered by updateTime descending; use filter state = "deleted" to find retained deleted projects for undelete. Continue with next_page_token as page_token until the token is absent.
5566
+ * Find collections and ids for filtering or moving canvases. All organization collections are returned in name order in one response; next_cursor is always null. canvas_count excludes deleted canvases. total_count counts all live canvases, rather than collections, and uncategorized_count counts live canvases without a collection. Use canvases.list with collection_id to read a collection or none to read uncategorized canvases.
5456
5567
  */
5457
- export const cutListProjects = (options) => (options?.client ?? client).get({
5568
+ export const canvasListCollections = (options) => (options?.client ?? client).get({
5458
5569
  security: [{
5459
5570
  key: 'BearerAuth',
5460
5571
  scheme: 'bearer',
@@ -5464,15 +5575,15 @@ export const cutListProjects = (options) => (options?.client ?? client).get({
5464
5575
  name: 'X-API-Key',
5465
5576
  type: 'apiKey'
5466
5577
  }],
5467
- url: '/cut/v1/projects',
5578
+ url: '/canvas/v1/collections',
5468
5579
  ...options
5469
5580
  });
5470
5581
  /**
5471
- * Create project
5582
+ * Create collection
5472
5583
  *
5473
- * Create a blank editing project in the API key organization before writing a script. First obtain accessible library ids from praxis.media; bindings must include exactly one read_write library with default_upload true. Each call creates a new project and returns HTTP 201; save its id for execute, state and timeline calls. All editing positions use seconds.
5584
+ * Organize canvases by creating a one-level collection in your organization. Send a name of 1–100 characters after trimming; duplicate names are allowed. Each call creates a new collection, initially containing no canvases. Use canvases.update with its id as collection_id to move existing canvases into it. Collections cannot be nested and an organization can have at most 200.
5474
5585
  */
5475
- export const cutCreateProject = (options) => (options.client ?? client).post({
5586
+ export const canvasCreateCollection = (options) => (options.client ?? client).post({
5476
5587
  security: [{
5477
5588
  key: 'BearerAuth',
5478
5589
  scheme: 'bearer',
@@ -5482,7 +5593,7 @@ export const cutCreateProject = (options) => (options.client ?? client).post({
5482
5593
  name: 'X-API-Key',
5483
5594
  type: 'apiKey'
5484
5595
  }],
5485
- url: '/cut/v1/projects',
5596
+ url: '/canvas/v1/collections',
5486
5597
  ...options,
5487
5598
  headers: {
5488
5599
  'Content-Type': 'application/json',
@@ -5490,11 +5601,11 @@ export const cutCreateProject = (options) => (options.client ?? client).post({
5490
5601
  }
5491
5602
  });
5492
5603
  /**
5493
- * Delete project
5604
+ * Delete collection
5494
5605
  *
5495
- * Soft-delete a project selected from projects.list. The project is retained for seven days until purge_time and can be restored with undelete before that deadline. Deleted projects cannot be edited; list with filter state = "deleted" to locate retained projects.
5606
+ * Remove a collection using an id from collections.list. All its canvases are preserved and become uncategorized, with collection_id set to null; read them using canvases.list with collection_id=none. The removed collection cannot be retrieved again, and repeating deletion returns COLLECTION_NOT_FOUND.
5496
5607
  */
5497
- export const cutDeleteProject = (options) => (options.client ?? client).delete({
5608
+ export const canvasDeleteCollection = (options) => (options.client ?? client).delete({
5498
5609
  security: [{
5499
5610
  key: 'BearerAuth',
5500
5611
  scheme: 'bearer',
@@ -5504,15 +5615,15 @@ export const cutDeleteProject = (options) => (options.client ?? client).delete({
5504
5615
  name: 'X-API-Key',
5505
5616
  type: 'apiKey'
5506
5617
  }],
5507
- url: '/cut/v1/projects/{project_id}',
5618
+ url: '/canvas/v1/collections/{collection_id}',
5508
5619
  ...options
5509
5620
  });
5510
5621
  /**
5511
- * Retrieve project
5622
+ * Retrieve collection
5512
5623
  *
5513
- * Inspect project metadata, settings and library bindings before editing. Copy id from projects.create or list; expand=timeline,exports,versions includes selected related resources. The expanded timeline uses seconds and the returned revision can guard a later execute call with expected_revision.
5624
+ * Inspect one collection and its current live canvas count using an id from collections.list or collections.create. The collection must belong to the API key organization. To read its canvases, pass the same id as collection_id to canvases.list; this response contains collection metadata only.
5514
5625
  */
5515
- export const cutRetrieveProject = (options) => (options.client ?? client).get({
5626
+ export const canvasRetrieveCollection = (options) => (options.client ?? client).get({
5516
5627
  security: [{
5517
5628
  key: 'BearerAuth',
5518
5629
  scheme: 'bearer',
@@ -5522,15 +5633,15 @@ export const cutRetrieveProject = (options) => (options.client ?? client).get({
5522
5633
  name: 'X-API-Key',
5523
5634
  type: 'apiKey'
5524
5635
  }],
5525
- url: '/cut/v1/projects/{project_id}',
5636
+ url: '/canvas/v1/collections/{collection_id}',
5526
5637
  ...options
5527
5638
  });
5528
5639
  /**
5529
- * Update project metadata
5640
+ * Rename collection
5530
5641
  *
5531
- * Change the project display name or replace its labels by naming those fields in update_mask. Use execute for clip or track edits. Each successful update commits a new revision; labels are replaced as a whole when selected, so read and merge existing labels before overwriting them.
5642
+ * Change the display name of a collection from collections.list without changing its id or canvas assignments. Names contain 1–100 characters after trimming and may match another collection name. This operation does not move canvases; use canvases.update with collection_id for that.
5532
5643
  */
5533
- export const cutUpdateProject = (options) => (options.client ?? client).patch({
5644
+ export const canvasUpdateCollection = (options) => (options.client ?? client).patch({
5534
5645
  security: [{
5535
5646
  key: 'BearerAuth',
5536
5647
  scheme: 'bearer',
@@ -5540,7 +5651,7 @@ export const cutUpdateProject = (options) => (options.client ?? client).patch({
5540
5651
  name: 'X-API-Key',
5541
5652
  type: 'apiKey'
5542
5653
  }],
5543
- url: '/cut/v1/projects/{project_id}',
5654
+ url: '/canvas/v1/collections/{collection_id}',
5544
5655
  ...options,
5545
5656
  headers: {
5546
5657
  'Content-Type': 'application/json',
@@ -5548,11 +5659,11 @@ export const cutUpdateProject = (options) => (options.client ?? client).patch({
5548
5659
  }
5549
5660
  });
5550
5661
  /**
5551
- * Restore deleted project
5662
+ * List canvas versions
5552
5663
  *
5553
- * Return a retained deleted project to active state before its purge_time. Obtain project_id from projects.list filtered to deleted projects. This restores the project, not an older timeline revision; use versions.restore when reverting editing content.
5664
+ * Inspect retained edits before restoring a canvas or reading historical nodes and images. Supply a canvas_id from canvases.list or create. Results include successful execute, import and restore commits since history was enabled, newest first. limit is 1–100 and defaults to 30; pass next_cursor as cursor until it is null. All versions from the last 30 days are retained unless the 256 MiB history budget requires pruning; the newest 100 versions are always retained regardless of age or size. earliest_restorable_version is the oldest readable and restorable version, including the state immediately before the first retained commit; null means no history has been recorded. Listing does not change the canvas.
5554
5665
  */
5555
- export const cutUndeleteProject = (options) => (options.client ?? client).post({
5666
+ export const canvasListVersions = (options) => (options.client ?? client).get({
5556
5667
  security: [{
5557
5668
  key: 'BearerAuth',
5558
5669
  scheme: 'bearer',
@@ -5562,21 +5673,15 @@ export const cutUndeleteProject = (options) => (options.client ?? client).post({
5562
5673
  name: 'X-API-Key',
5563
5674
  type: 'apiKey'
5564
5675
  }],
5565
- url: '/cut/v1/projects/{project_id}:undelete',
5676
+ url: '/canvas/v1/canvases/{canvas_id}/versions',
5566
5677
  ...options
5567
5678
  });
5568
5679
  /**
5569
- * Execute editing script
5570
- *
5571
- * Edit the current timeline atomically using synchronous JavaScript source. Read state or timeline first, then pass its revision as expected_revision to detect concurrent changes. Use AddTrack, Insert, Update, Delete, Split, Trim, Move, RippleDeleteRange, UpdateTrack, DeleteTrack, SetSettings, AddCaptionsFromTranscript and SetMarker for writes; GetTimeline, GetItem, FindItems, GetMedia, GetTranscript and GetAnalysis read editing context; Print emits text and Preview requests frame previews. All script times are seconds; script object fields use camelCase, for example `media: {libraryId, assetId}`. Unlike Shotstack, execute applies script edits to a persistent project in one transaction. Provide script or a saved edit_id with literal edits, never both; failures roll back writes. A revision conflict while preparing the response may follow a committed edit: retrieve state before retrying. Minimal script after creating a project:
5680
+ * Restore canvas version
5572
5681
  *
5573
- * ```js
5574
- * const t = AddTrack("video");
5575
- * Insert(t, {type: "color", color: "#123456", start: 0, length: 3});
5576
- * Print(t);
5577
- * ```
5682
+ * Recover a canvas after an unwanted edit by restoring a retained version from versions.list or its earliest_restorable_version. This replaces current nodes, variables and themes with the target state and creates one new version; history remains available, so restoring can itself be undone with another restore. Restoring the current version succeeds without creating a version. Optionally guard the write with expected_version from retrieve or nodes.list; if it is stale, inspect current state and retry with the new value. Repeating an unguarded request after another edit can create another restore version. Versions from before history was enabled or outside retention cannot be recovered. Connected viewers resync after a successful restore.
5578
5683
  */
5579
- export const cutExecute = (options) => (options.client ?? client).post({
5684
+ export const canvasRestoreCanvas = (options) => (options.client ?? client).post({
5580
5685
  security: [{
5581
5686
  key: 'BearerAuth',
5582
5687
  scheme: 'bearer',
@@ -5586,7 +5691,7 @@ export const cutExecute = (options) => (options.client ?? client).post({
5586
5691
  name: 'X-API-Key',
5587
5692
  type: 'apiKey'
5588
5693
  }],
5589
- url: '/cut/v1/projects/{project_id}:execute',
5694
+ url: '/canvas/v1/canvases/{canvas_id}:restore',
5590
5695
  ...options,
5591
5696
  headers: {
5592
5697
  'Content-Type': 'application/json',
@@ -5594,75 +5699,87 @@ export const cutExecute = (options) => (options.client ?? client).post({
5594
5699
  }
5595
5700
  });
5596
5701
  /**
5597
- * Read editing state
5702
+ * List records
5598
5703
  *
5599
- * Read lightweight project context before composing an execute script. Returns current revision, rendering settings, track counts, library bindings and offline media count without individual clips. For complete clip documents or a selected time range, read timeline instead.
5704
+ * Browse records of one object type and obtain ids for retrieval or edits. Discover objectType with schemas.list; select properties by internal names from properties.list. Omit after for the first page, then copy paging.next.after until no next page is returned. archived defaults to false; use objects.search for property filters.
5600
5705
  */
5601
- export const cutRetrieveState = (options) => (options.client ?? client).get({
5706
+ export const crmObjectsList = (options) => (options.client ?? client).get({
5707
+ querySerializer: { parameters: {
5708
+ associations: { array: { explode: false } },
5709
+ properties: { array: { explode: false } },
5710
+ propertiesWithHistory: { array: { explode: false } }
5711
+ } },
5602
5712
  security: [{
5603
- key: 'BearerAuth',
5713
+ key: 'crm-bearerAuth',
5604
5714
  scheme: 'bearer',
5605
5715
  type: 'http'
5606
- }, {
5607
- key: 'ApiKeyAuth',
5608
- name: 'X-API-Key',
5609
- type: 'apiKey'
5610
5716
  }],
5611
- url: '/cut/v1/projects/{project_id}/state',
5717
+ url: '/crm/v1/objects/{objectType}',
5612
5718
  ...options
5613
5719
  });
5614
5720
  /**
5615
- * Read project timeline
5721
+ * Create record
5616
5722
  *
5617
- * Inspect clips and markers in a selected project range before editing. view=full returns structured tracks with all timeline positions in seconds; view=compact returns compact text for script context. from and to are seconds and tracks limits the selection to comma-separated track ids from state. Concurrent changes while preparing a full timeline return 409; retrieve the latest state and try the read again.
5723
+ * Create a customer record with property values and optional initial associations. Discover objectType with schemas.list and allowed property names with properties.list; save the returned id for subsequent calls. Each call creates a record. Example for contacts: {"properties":{"email":"person@example.com"}}. Writes return refs (ResourceRef[]) for entity cards and optional property changes in conversations.
5618
5724
  */
5619
- export const cutRetrieveTimeline = (options) => (options.client ?? client).get({
5725
+ export const crmObjectsCreate = (options) => (options.client ?? client).post({
5620
5726
  security: [{
5621
- key: 'BearerAuth',
5727
+ key: 'crm-bearerAuth',
5622
5728
  scheme: 'bearer',
5623
5729
  type: 'http'
5624
- }, {
5625
- key: 'ApiKeyAuth',
5626
- name: 'X-API-Key',
5627
- type: 'apiKey'
5628
5730
  }],
5629
- url: '/cut/v1/projects/{project_id}/timeline',
5731
+ url: '/crm/v1/objects/{objectType}',
5732
+ ...options,
5733
+ headers: {
5734
+ 'Content-Type': 'application/json',
5735
+ ...options.headers
5736
+ }
5737
+ });
5738
+ /**
5739
+ * Archive record
5740
+ *
5741
+ * Archive a record selected from objects.list or objects.search when it should leave active results. This removes it from normal lists without deleting its history; archived=true can be used to read archived records. Confirm objectType and objectId before calling. Writes return refs (ResourceRef[]) for entity cards and optional property changes in conversations. Unlike HubSpot, this own-face archive returns HTTP 200 with a JSON refs body instead of HTTP 204.
5742
+ */
5743
+ export const crmObjectsArchive = (options) => (options.client ?? client).delete({
5744
+ security: [{
5745
+ key: 'crm-bearerAuth',
5746
+ scheme: 'bearer',
5747
+ type: 'http'
5748
+ }],
5749
+ url: '/crm/v1/objects/{objectType}/{objectId}',
5630
5750
  ...options
5631
5751
  });
5632
5752
  /**
5633
- * Render preview frames
5753
+ * Retrieve record
5634
5754
  *
5635
- * Review the visual result at one or more project times without creating an export. Pass comma-separated seconds in at, such as 12,15.5; scale changes preview size and revision selects a committed project revision. Fetch the returned image URLs before expires_at; render again when they expire.
5755
+ * Read one record by id from objects.list, objects.search or objects.create. Select property names with properties and associated object types with associations; use idProperty only when objectId is a value of that unique property. Use archived=true to inspect an archived record.
5636
5756
  */
5637
- export const cutListFrames = (options) => (options.client ?? client).get({
5757
+ export const crmObjectsRetrieve = (options) => (options.client ?? client).get({
5758
+ querySerializer: { parameters: {
5759
+ associations: { array: { explode: false } },
5760
+ properties: { array: { explode: false } },
5761
+ propertiesWithHistory: { array: { explode: false } }
5762
+ } },
5638
5763
  security: [{
5639
- key: 'BearerAuth',
5764
+ key: 'crm-bearerAuth',
5640
5765
  scheme: 'bearer',
5641
5766
  type: 'http'
5642
- }, {
5643
- key: 'ApiKeyAuth',
5644
- name: 'X-API-Key',
5645
- type: 'apiKey'
5646
5767
  }],
5647
- url: '/cut/v1/projects/{project_id}/frames',
5768
+ url: '/crm/v1/objects/{objectType}/{objectId}',
5648
5769
  ...options
5649
5770
  });
5650
5771
  /**
5651
- * Analyze project media
5772
+ * Update record
5652
5773
  *
5653
- * Request silence, filler-word or scene analysis for selected bound assets before editing. Omit media to select project sources; ranges returned in segments use source seconds. A pending result is not completion: use retry_after_sec before checking again, and inspect failed or unsupported asset results before deciding which edits are possible.
5774
+ * Change only the supplied properties of a record selected from objects.list or objects.search. Omitted properties retain their values. Use property names from properties.list and valid stage ids from pipelines.retrieve. Stage-entry requirements must be satisfied by the resulting record; inspect 400 errors before retrying. Writes return refs (ResourceRef[]) for entity cards and optional property changes in conversations.
5654
5775
  */
5655
- export const cutCreateAnalysis = (options) => (options.client ?? client).post({
5776
+ export const crmObjectsUpdate = (options) => (options.client ?? client).patch({
5656
5777
  security: [{
5657
- key: 'BearerAuth',
5778
+ key: 'crm-bearerAuth',
5658
5779
  scheme: 'bearer',
5659
5780
  type: 'http'
5660
- }, {
5661
- key: 'ApiKeyAuth',
5662
- name: 'X-API-Key',
5663
- type: 'apiKey'
5664
5781
  }],
5665
- url: '/cut/v1/projects/{project_id}/analysis',
5782
+ url: '/crm/v1/objects/{objectType}/{objectId}',
5666
5783
  ...options,
5667
5784
  headers: {
5668
5785
  'Content-Type': 'application/json',
@@ -5670,39 +5787,35 @@ export const cutCreateAnalysis = (options) => (options.client ?? client).post({
5670
5787
  }
5671
5788
  });
5672
5789
  /**
5673
- * List library bindings
5790
+ * Search records
5674
5791
  *
5675
- * Discover the named media libraries available to this project before selecting source assets or an import/export destination. read bindings supply source assets; read_write bindings also accept uploads. Exactly one writable binding supplies the default upload destination.
5792
+ * Find records using text query, property filters and sort order rather than scanning a list. Obtain objectType from schemas.list and filter propertyName values from properties.list. Supply filterGroups, sorts, properties, limit and after; use empty arrays for no filters, sorts or property selection, and an empty after for the first page. Copy paging.next.after with the same query to continue. This operation reads records without changing them.
5676
5793
  */
5677
- export const cutListBindings = (options) => (options.client ?? client).get({
5794
+ export const crmObjectsSearch = (options) => (options.client ?? client).post({
5678
5795
  security: [{
5679
- key: 'BearerAuth',
5796
+ key: 'crm-bearerAuth',
5680
5797
  scheme: 'bearer',
5681
5798
  type: 'http'
5682
- }, {
5683
- key: 'ApiKeyAuth',
5684
- name: 'X-API-Key',
5685
- type: 'apiKey'
5686
5799
  }],
5687
- url: '/cut/v1/projects/{project_id}/bindings',
5688
- ...options
5800
+ url: '/crm/v1/objects/{objectType}/search',
5801
+ ...options,
5802
+ headers: {
5803
+ 'Content-Type': 'application/json',
5804
+ ...options.headers
5805
+ }
5689
5806
  });
5690
5807
  /**
5691
- * Bind media library
5808
+ * Batch read records
5692
5809
  *
5693
- * Attach an accessible media library to an existing project under a unique name. Obtain library_id from praxis.media and choose read for source-only access or read_write for imports and exports. The project must retain exactly one read_write binding with default_upload true after the change.
5810
+ * Read a set of known record ids in one call; use objects.search to discover ids first. Supply inputs with ids plus requested properties; set idProperty only when the inputs use unique-property values rather than record ids.
5694
5811
  */
5695
- export const cutCreateBinding = (options) => (options.client ?? client).post({
5812
+ export const crmObjectsBatchRead = (options) => (options.client ?? client).post({
5696
5813
  security: [{
5697
- key: 'BearerAuth',
5814
+ key: 'crm-bearerAuth',
5698
5815
  scheme: 'bearer',
5699
5816
  type: 'http'
5700
- }, {
5701
- key: 'ApiKeyAuth',
5702
- name: 'X-API-Key',
5703
- type: 'apiKey'
5704
5817
  }],
5705
- url: '/cut/v1/projects/{project_id}/bindings',
5818
+ url: '/crm/v1/objects/{objectType}/batch/read',
5706
5819
  ...options,
5707
5820
  headers: {
5708
5821
  'Content-Type': 'application/json',
@@ -5710,39 +5823,35 @@ export const cutCreateBinding = (options) => (options.client ?? client).post({
5710
5823
  }
5711
5824
  });
5712
5825
  /**
5713
- * Remove library binding
5826
+ * Batch create records
5714
5827
  *
5715
- * Detach a library alias obtained from bindings.list after removing all timeline clips that reference its library. BINDING_IN_USE returns 409 while references remain; inspect timeline and edit those clips first. Removal must preserve the one writable default upload binding.
5828
+ * Create several records of one object type using inputs with properties and optional associations. Obtain property names from properties.list; each successful input creates a record, so inspect per-item errors before resubmitting failed inputs. Writes return refs (ResourceRef[]) for entity cards and optional property changes in conversations.
5716
5829
  */
5717
- export const cutDeleteBinding = (options) => (options.client ?? client).delete({
5830
+ export const crmObjectsBatchCreate = (options) => (options.client ?? client).post({
5718
5831
  security: [{
5719
- key: 'BearerAuth',
5832
+ key: 'crm-bearerAuth',
5720
5833
  scheme: 'bearer',
5721
5834
  type: 'http'
5722
- }, {
5723
- key: 'ApiKeyAuth',
5724
- name: 'X-API-Key',
5725
- type: 'apiKey'
5726
5835
  }],
5727
- url: '/cut/v1/projects/{project_id}/bindings/{name}',
5728
- ...options
5836
+ url: '/crm/v1/objects/{objectType}/batch/create',
5837
+ ...options,
5838
+ headers: {
5839
+ 'Content-Type': 'application/json',
5840
+ ...options.headers
5841
+ }
5729
5842
  });
5730
5843
  /**
5731
- * Import project media
5844
+ * Batch update records
5732
5845
  *
5733
- * Import a URL, data URI or existing file into a writable project media library. Select binding from bindings.list or omit it to use default_upload. Save library_id and asset_id from the result and use them as libraryId and assetId inside execute script media references; overwrites follow the source asset latest version.
5846
+ * Apply distinct property patches to existing records identified by inputs[].id. Obtain ids from objects.list or objects.search and property names from properties.list. Omitted properties retain their values; inspect results and errors for each input. Writes return refs (ResourceRef[]) for entity cards and optional property changes in conversations.
5734
5847
  */
5735
- export const cutImportMedia = (options) => (options.client ?? client).post({
5848
+ export const crmObjectsBatchUpdate = (options) => (options.client ?? client).post({
5736
5849
  security: [{
5737
- key: 'BearerAuth',
5850
+ key: 'crm-bearerAuth',
5738
5851
  scheme: 'bearer',
5739
5852
  type: 'http'
5740
- }, {
5741
- key: 'ApiKeyAuth',
5742
- name: 'X-API-Key',
5743
- type: 'apiKey'
5744
5853
  }],
5745
- url: '/cut/v1/projects/{project_id}/media:import',
5854
+ url: '/crm/v1/objects/{objectType}/batch/update',
5746
5855
  ...options,
5747
5856
  headers: {
5748
5857
  'Content-Type': 'application/json',
@@ -5750,39 +5859,35 @@ export const cutImportMedia = (options) => (options.client ?? client).post({
5750
5859
  }
5751
5860
  });
5752
5861
  /**
5753
- * List project exports
5862
+ * Batch upsert records
5754
5863
  *
5755
- * Find export jobs associated with this project before polling or canceling a render. Copy an export id into praxis.cut.exports.retrieve or cancel. Continue with next_page_token as page_token when present; queued or in-progress jobs have not produced a final media asset.
5864
+ * Create records that do not yet exist or update matches using a unique property. Provide idProperty and its value in each input, plus properties; choose a property with hasUniqueValue from properties.list. Inspect each result to determine whether it was newly created. Writes return refs (ResourceRef[]) for entity cards and optional property changes in conversations.
5756
5865
  */
5757
- export const cutListExports = (options) => (options.client ?? client).get({
5866
+ export const crmObjectsBatchUpsert = (options) => (options.client ?? client).post({
5758
5867
  security: [{
5759
- key: 'BearerAuth',
5868
+ key: 'crm-bearerAuth',
5760
5869
  scheme: 'bearer',
5761
5870
  type: 'http'
5762
- }, {
5763
- key: 'ApiKeyAuth',
5764
- name: 'X-API-Key',
5765
- type: 'apiKey'
5766
5871
  }],
5767
- url: '/cut/v1/projects/{project_id}/exports',
5768
- ...options
5872
+ url: '/crm/v1/objects/{objectType}/batch/upsert',
5873
+ ...options,
5874
+ headers: {
5875
+ 'Content-Type': 'application/json',
5876
+ ...options.headers
5877
+ }
5769
5878
  });
5770
5879
  /**
5771
- * Create video export
5880
+ * Batch archive records
5772
5881
  *
5773
- * Start an asynchronous video export from the project into a writable bound media library. Choose binding from bindings.list or omit it for default_upload, and optionally select revision and output settings. HTTP 202 only accepts the job; poll praxis.cut.exports.retrieve using the returned id until status is done, failed or canceled. On done, asset identifies the video written back to praxis.media. Each call starts a job, so retrieve a known job before retrying a submission.
5882
+ * Archive known records of one object type using inputs[].id from objects.list or objects.search. Archived records leave active lists but retain their history; confirm all ids before calling. Writes return refs (ResourceRef[]) for entity cards and optional property changes in conversations. Unlike HubSpot, this own-face archive returns HTTP 200 with a JSON refs body instead of HTTP 204.
5774
5883
  */
5775
- export const cutCreateExport = (options) => (options.client ?? client).post({
5884
+ export const crmObjectsBatchArchive = (options) => (options.client ?? client).post({
5776
5885
  security: [{
5777
- key: 'BearerAuth',
5886
+ key: 'crm-bearerAuth',
5778
5887
  scheme: 'bearer',
5779
5888
  type: 'http'
5780
- }, {
5781
- key: 'ApiKeyAuth',
5782
- name: 'X-API-Key',
5783
- type: 'apiKey'
5784
5889
  }],
5785
- url: '/cut/v1/projects/{project_id}/exports',
5890
+ url: '/crm/v1/objects/{objectType}/batch/archive',
5786
5891
  ...options,
5787
5892
  headers: {
5788
5893
  'Content-Type': 'application/json',
@@ -5790,75 +5895,31 @@ export const cutCreateExport = (options) => (options.client ?? client).post({
5790
5895
  }
5791
5896
  });
5792
5897
  /**
5793
- * Retrieve video export
5898
+ * List properties
5794
5899
  *
5795
- * Poll an export id returned by projects.exports.create or list to observe render progress. queued, fetching, rendering, stitching and saving are in progress; done provides asset in the target library, failed provides error, and canceled means the job stopped. Only done confirms a usable output asset.
5900
+ * Inspect the property definitions available for an object type before writing or filtering records. Obtain objectType from schemas.list; reuse each immutable name in record properties and filters. archived defaults to false.
5796
5901
  */
5797
- export const cutRetrieveExport = (options) => (options.client ?? client).get({
5902
+ export const crmPropertiesList = (options) => (options.client ?? client).get({
5798
5903
  security: [{
5799
- key: 'BearerAuth',
5904
+ key: 'crm-bearerAuth',
5800
5905
  scheme: 'bearer',
5801
5906
  type: 'http'
5802
- }, {
5803
- key: 'ApiKeyAuth',
5804
- name: 'X-API-Key',
5805
- type: 'apiKey'
5806
5907
  }],
5807
- url: '/cut/v1/exports/{export_id}',
5908
+ url: '/crm/v1/properties/{objectType}',
5808
5909
  ...options
5809
5910
  });
5810
5911
  /**
5811
- * Cancel video export
5912
+ * Create property
5812
5913
  *
5813
- * Request cancellation of an export obtained from projects.exports.create or list when its output is no longer needed. Read the returned job status and retrieve it to confirm the terminal outcome; do not interpret a cancellation request as successful rendering.
5914
+ * Define a property before setting its values on records. Choose objectType from schemas.list and groupName from properties.groups.list; provide an immutable internal name, display label, type and fieldType. Enumeration properties require their valid options. Writes return refs (ResourceRef[]) for entity cards and optional property changes in conversations.
5814
5915
  */
5815
- export const cutCancelExport = (options) => (options.client ?? client).post({
5916
+ export const crmPropertiesCreate = (options) => (options.client ?? client).post({
5816
5917
  security: [{
5817
- key: 'BearerAuth',
5918
+ key: 'crm-bearerAuth',
5818
5919
  scheme: 'bearer',
5819
5920
  type: 'http'
5820
- }, {
5821
- key: 'ApiKeyAuth',
5822
- name: 'X-API-Key',
5823
- type: 'apiKey'
5824
5921
  }],
5825
- url: '/cut/v1/exports/{export_id}:cancel',
5826
- ...options
5827
- });
5828
- /**
5829
- * List saved versions
5830
- *
5831
- * Find saved timeline snapshots for this project and obtain version_id values for restore. A saved version records its original revision; restoring it creates a new current revision rather than rewinding the revision counter. Continue with next_page_token as page_token until absent.
5832
- */
5833
- export const cutListVersions = (options) => (options.client ?? client).get({
5834
- security: [{
5835
- key: 'BearerAuth',
5836
- scheme: 'bearer',
5837
- type: 'http'
5838
- }, {
5839
- key: 'ApiKeyAuth',
5840
- name: 'X-API-Key',
5841
- type: 'apiKey'
5842
- }],
5843
- url: '/cut/v1/projects/{project_id}/versions',
5844
- ...options
5845
- });
5846
- /**
5847
- * Save project version
5848
- *
5849
- * Save the current project timeline as a named recovery point before a substantial edit. Supply an optional label or send an empty object; keep the returned version id for versions.restore. Saving a version does not publish a rendered asset; use projects.exports.create for video output.
5850
- */
5851
- export const cutCreateVersion = (options) => (options.client ?? client).post({
5852
- security: [{
5853
- key: 'BearerAuth',
5854
- scheme: 'bearer',
5855
- type: 'http'
5856
- }, {
5857
- key: 'ApiKeyAuth',
5858
- name: 'X-API-Key',
5859
- type: 'apiKey'
5860
- }],
5861
- url: '/cut/v1/projects/{project_id}/versions',
5922
+ url: '/crm/v1/properties/{objectType}',
5862
5923
  ...options,
5863
5924
  headers: {
5864
5925
  'Content-Type': 'application/json',
@@ -5866,49 +5927,45 @@ export const cutCreateVersion = (options) => (options.client ?? client).post({
5866
5927
  }
5867
5928
  });
5868
5929
  /**
5869
- * Restore saved version
5930
+ * Archive property
5870
5931
  *
5871
- * Replace current editing content with a saved project snapshot selected from projects.versions.list. The restore commits a new transaction and revision while preserving the saved version for future use. Inspect the returned summary and timeline before further editing; a response revision conflict can follow a committed restore, so retrieve current state before retrying.
5932
+ * Archive a property definition selected by internal name from properties.list. Confirm that record entry and search flows no longer depend on it; archived definitions are excluded from normal property lists. Writes return refs (ResourceRef[]) for entity cards and optional property changes in conversations. Unlike HubSpot, this own-face archive returns HTTP 200 with a JSON refs body instead of HTTP 204.
5872
5933
  */
5873
- export const cutRestoreVersion = (options) => (options.client ?? client).post({
5934
+ export const crmPropertiesArchive = (options) => (options.client ?? client).delete({
5874
5935
  security: [{
5875
- key: 'BearerAuth',
5936
+ key: 'crm-bearerAuth',
5876
5937
  scheme: 'bearer',
5877
5938
  type: 'http'
5878
- }, {
5879
- key: 'ApiKeyAuth',
5880
- name: 'X-API-Key',
5881
- type: 'apiKey'
5882
5939
  }],
5883
- url: '/cut/v1/versions/{version_id}:restore',
5940
+ url: '/crm/v1/properties/{objectType}/{propertyName}',
5884
5941
  ...options
5885
5942
  });
5886
5943
  /**
5887
- * List databases
5944
+ * Retrieve property
5888
5945
  *
5889
- * Find databases owned by your tenant and obtain their ids for schema or row operations. Excludes deleting by default. status=active or status=deleting selects that state; invalid values return 400 INVALID_PARAMS.
5946
+ * Inspect the type, options and modification restrictions of a property before changing its definition or record values. Obtain propertyName from properties.list; it is the immutable internal name rather than the label.
5890
5947
  */
5891
- export const databaseListDatabases = (options) => (options?.client ?? client).get({
5948
+ export const crmPropertiesRetrieve = (options) => (options.client ?? client).get({
5892
5949
  security: [{
5893
- key: 'database-bearerAuth',
5950
+ key: 'crm-bearerAuth',
5894
5951
  scheme: 'bearer',
5895
5952
  type: 'http'
5896
5953
  }],
5897
- url: '/database/v1/databases',
5954
+ url: '/crm/v1/properties/{objectType}/{propertyName}',
5898
5955
  ...options
5899
5956
  });
5900
5957
  /**
5901
- * Create database
5958
+ * Update property
5902
5959
  *
5903
- * Creates an empty database for the caller and returns it with status active (HTTP 201); add tables next with praxis.database.databases.tables.create. name is required and is 1–64 visible characters after trimming. labels are optional string tags (at most 64; each key starts with a lowercase letter and uses up to 63 characters of a-z 0-9 _ -; each value is up to 63 characters of a-z 0-9 _ -) that databaseListDatabases can filter on. If initialization fails the call returns 503 CAPACITY and the half-created database is left with status failed; retry by calling create again, which makes a new database. Unlike Supabase, this creates a SQLite-backed database without a PostgreSQL connection or SQL execution endpoint. Use a Praxis credential; access is scoped to its tenant, not to Supabase Auth users or RLS policies.
5960
+ * Change editable settings of a property selected from properties.list, such as its label, group or options. Preserve the immutable internal name; inspect modificationMetadata before editing system-managed definitions. Writes return refs (ResourceRef[]) for entity cards and optional property changes in conversations.
5904
5961
  */
5905
- export const databaseCreateDatabase = (options) => (options.client ?? client).post({
5962
+ export const crmPropertiesUpdate = (options) => (options.client ?? client).patch({
5906
5963
  security: [{
5907
- key: 'database-bearerAuth',
5964
+ key: 'crm-bearerAuth',
5908
5965
  scheme: 'bearer',
5909
5966
  type: 'http'
5910
5967
  }],
5911
- url: '/database/v1/databases',
5968
+ url: '/crm/v1/properties/{objectType}/{propertyName}',
5912
5969
  ...options,
5913
5970
  headers: {
5914
5971
  'Content-Type': 'application/json',
@@ -5916,45 +5973,31 @@ export const databaseCreateDatabase = (options) => (options.client ?? client).po
5916
5973
  }
5917
5974
  });
5918
5975
  /**
5919
- * Delete database
5920
- *
5921
- * Soft-delete a database when it should stop accepting schema and row operations. Idempotently enters deleting with a seven-day purge_at. GET remains available; child operations return 409 until restored.
5922
- */
5923
- export const databaseDeleteDatabase = (options) => (options.client ?? client).delete({
5924
- security: [{
5925
- key: 'database-bearerAuth',
5926
- scheme: 'bearer',
5927
- type: 'http'
5928
- }],
5929
- url: '/database/v1/databases/{database_id}',
5930
- ...options
5931
- });
5932
- /**
5933
- * Get database
5976
+ * List property groups
5934
5977
  *
5935
- * Returns one database by id, including a database in the deleting state (purge_at then shows when it will be permanently removed). Call it before table or row operations to confirm status is active: schema and row calls on a deleting database return 409 DATABASE_INVALID_STATE. size_bytes is refreshed from live storage at most once every five seconds. A purged or unknown id returns 404 DATABASE_NOT_FOUND.
5978
+ * Discover property groups for an object type before creating or organizing property definitions. Obtain objectType from schemas.list and reuse a group name as groupName in properties.create or properties.update.
5936
5979
  */
5937
- export const databaseGetDatabase = (options) => (options.client ?? client).get({
5980
+ export const crmPropertiesGroupsList = (options) => (options.client ?? client).get({
5938
5981
  security: [{
5939
- key: 'database-bearerAuth',
5982
+ key: 'crm-bearerAuth',
5940
5983
  scheme: 'bearer',
5941
5984
  type: 'http'
5942
5985
  }],
5943
- url: '/database/v1/databases/{database_id}',
5986
+ url: '/crm/v1/properties/{objectType}/groups',
5944
5987
  ...options
5945
5988
  });
5946
5989
  /**
5947
- * Update database
5990
+ * Create property group
5948
5991
  *
5949
- * Renames an active database and/or replaces its labels; send only the keys you want to change. labels is replaced as a whole, not merged, so include every label you want to keep. A body without name or labels, or with values equal to the current ones, changes nothing and leaves updated_at as is. A database in the deleting state returns 409 DATABASE_INVALID_STATE; restore it first with databaseRestoreDatabase.
5992
+ * Create a named group for related property definitions of one object type. Obtain objectType from schemas.list; choose a unique internal name and display label, then reuse the returned name as groupName when creating properties. Writes return refs (ResourceRef[]) for entity cards and optional property changes in conversations.
5950
5993
  */
5951
- export const databaseUpdateDatabase = (options) => (options.client ?? client).patch({
5994
+ export const crmPropertiesGroupsCreate = (options) => (options.client ?? client).post({
5952
5995
  security: [{
5953
- key: 'database-bearerAuth',
5996
+ key: 'crm-bearerAuth',
5954
5997
  scheme: 'bearer',
5955
5998
  type: 'http'
5956
5999
  }],
5957
- url: '/database/v1/databases/{database_id}',
6000
+ url: '/crm/v1/properties/{objectType}/groups',
5958
6001
  ...options,
5959
6002
  headers: {
5960
6003
  'Content-Type': 'application/json',
@@ -5962,59 +6005,31 @@ export const databaseUpdateDatabase = (options) => (options.client ?? client).pa
5962
6005
  }
5963
6006
  });
5964
6007
  /**
5965
- * Restore database
5966
- *
5967
- * Recover a soft-deleted database within its seven-day recovery window. Restore before purge_at. An empty body is accepted. Active databases return 409; purged databases return 404.
5968
- */
5969
- export const databaseRestoreDatabase = (options) => (options.client ?? client).post({
5970
- security: [{
5971
- key: 'database-bearerAuth',
5972
- scheme: 'bearer',
5973
- type: 'http'
5974
- }],
5975
- url: '/database/v1/databases/{database_id}/restore',
5976
- ...options
5977
- });
5978
- /**
5979
- * Permanently purge database
5980
- *
5981
- * Immediately and irreversibly purges a deleting database. Active databases return 409; absent or already purged databases return 404.
5982
- */
5983
- export const databasePurgeDatabase = (options) => (options.client ?? client).post({
5984
- security: [{
5985
- key: 'database-bearerAuth',
5986
- scheme: 'bearer',
5987
- type: 'http'
5988
- }],
5989
- url: '/database/v1/databases/{database_id}/purge',
5990
- ...options
5991
- });
5992
- /**
5993
- * List tables
6008
+ * List pipelines
5994
6009
  *
5995
- * Lists every table of an active database with its field definitions. A database holds at most 50 tables, so the single page contains all of them and next_cursor is always null. Use databaseGetTable instead when you also need row_count for one table.
6010
+ * Discover pipelines and stage ids for records of one object type from schemas.list. Reuse pipeline and stage ids in record property updates or lead qualification. Stage rules are string values in stage.metadata: praxis_category is open (active), won (successful) or lost (unsuccessful); praxis_terminal is "true" (no further transition) or "false" (transitions allowed); praxis_allowed_next is a JSON-encoded array string of permitted next stage ids, with the string "null" meaning unrestricted; praxis_required is a JSON-encoded array string of property names ("[]" means none) that must be non-empty on entry (boolean properties must be "true"). Rule violations return HTTP 400 VALIDATION_ERROR; errors[0].context.properties lists missing required property names. Correct those values or choose an allowed stage before retrying. Example metadata: {"praxis_category":"open","praxis_terminal":"false","praxis_allowed_next":"[\"proposal\",\"lost\"]","praxis_required":"[\"budget\",\"decision_maker\"]"}.
5996
6011
  */
5997
- export const databaseListTables = (options) => (options.client ?? client).get({
6012
+ export const crmPipelinesList = (options) => (options.client ?? client).get({
5998
6013
  security: [{
5999
- key: 'database-bearerAuth',
6014
+ key: 'crm-bearerAuth',
6000
6015
  scheme: 'bearer',
6001
6016
  type: 'http'
6002
6017
  }],
6003
- url: '/database/v1/databases/{database_id}/tables',
6018
+ url: '/crm/v1/pipelines/{objectType}',
6004
6019
  ...options
6005
6020
  });
6006
6021
  /**
6007
- * Create table
6022
+ * Create pipeline
6008
6023
  *
6009
- * Creates a table together with its initial fields in one call and returns it (HTTP 201) with generated tbl_ and fld_ ids. name must match ^[a-z_][a-z0-9_]{0,62}$ and be unused in this database (duplicate: 409 UNIQUE_VIOLATION). fields is required and may be an empty array; fields can also be added later with databaseAddField. Limits: 50 tables per database, 64 fields per table, and 16 indexed or unique fields per table; exceeding one returns 400 LIMIT_EXCEEDED. Fields default to indexed:false. Set indexed:true explicitly for fields used in filters or ordering. Only indexed:true or unique:true consumes one of the 16 indexed-or-unique field slots; a field with both consumes one slot. Unique fields still consume a slot even with indexed:false. Existing fields are unchanged. Minimal field example: {"name":"notes","type":"string","indexed":false}. Every row also has a system id column, which is not declared as a field. Insert data afterwards with databaseInsert. Unlike Supabase, define schema with this table API and the field APIs; PostgreSQL DDL and SQL migration files cannot be submitted. Each table supports up to 1,000,000 rows.
6024
+ * Create a pipeline with its ordered stages for an object type from schemas.list. Provide a display label, displayOrder and initial stages, then use the returned ids when assigning records. Stage rules are string values in stage.metadata: praxis_category is open (active), won (successful) or lost (unsuccessful); praxis_terminal is "true" (no further transition) or "false" (transitions allowed); praxis_allowed_next is a JSON-encoded array string of permitted next stage ids, with the string "null" meaning unrestricted; praxis_required is a JSON-encoded array string of property names ("[]" means none) that must be non-empty on entry (boolean properties must be "true"). Rule violations return HTTP 400 VALIDATION_ERROR; errors[0].context.properties lists missing required property names. Correct those values or choose an allowed stage before retrying. Writes return refs (ResourceRef[]) for entity cards and optional property changes in conversations. Example metadata: {"praxis_category":"open","praxis_terminal":"false","praxis_allowed_next":"[\"proposal\",\"lost\"]","praxis_required":"[\"budget\",\"decision_maker\"]"}.
6010
6025
  */
6011
- export const databaseCreateTable = (options) => (options.client ?? client).post({
6026
+ export const crmPipelinesCreate = (options) => (options.client ?? client).post({
6012
6027
  security: [{
6013
- key: 'database-bearerAuth',
6028
+ key: 'crm-bearerAuth',
6014
6029
  scheme: 'bearer',
6015
6030
  type: 'http'
6016
6031
  }],
6017
- url: '/database/v1/databases/{database_id}/tables',
6032
+ url: '/crm/v1/pipelines/{objectType}',
6018
6033
  ...options,
6019
6034
  headers: {
6020
6035
  'Content-Type': 'application/json',
@@ -6022,45 +6037,45 @@ export const databaseCreateTable = (options) => (options.client ?? client).post(
6022
6037
  }
6023
6038
  });
6024
6039
  /**
6025
- * Delete table
6040
+ * Archive pipeline
6026
6041
  *
6027
- * Permanently drops a table with all of its rows; the deletion is immediate and has no recovery window or undo. Refused with 409 REFERENCE_RESTRICT while a link field of another table points at this table, so delete or change those fields first. Returns {deleted: true}. A table name can be reused afterwards.
6042
+ * Archive a pipeline selected from pipelines.list when records no longer depend on it. Check current records and stage usage first; resolve references reported by validation before retrying. Stage rules are string values in stage.metadata: praxis_category is open (active), won (successful) or lost (unsuccessful); praxis_terminal is "true" (no further transition) or "false" (transitions allowed); praxis_allowed_next is a JSON-encoded array string of permitted next stage ids, with the string "null" meaning unrestricted; praxis_required is a JSON-encoded array string of property names ("[]" means none) that must be non-empty on entry (boolean properties must be "true"). Rule violations return HTTP 400 VALIDATION_ERROR; errors[0].context.properties lists missing required property names. Correct those values or choose an allowed stage before retrying. Writes return refs (ResourceRef[]) for entity cards and optional property changes in conversations. Unlike HubSpot, this own-face archive returns HTTP 200 with a JSON refs body instead of HTTP 204. Example metadata: {"praxis_category":"open","praxis_terminal":"false","praxis_allowed_next":"[\"proposal\",\"lost\"]","praxis_required":"[\"budget\",\"decision_maker\"]"}.
6028
6043
  */
6029
- export const databaseDeleteTable = (options) => (options.client ?? client).delete({
6044
+ export const crmPipelinesArchive = (options) => (options.client ?? client).delete({
6030
6045
  security: [{
6031
- key: 'database-bearerAuth',
6046
+ key: 'crm-bearerAuth',
6032
6047
  scheme: 'bearer',
6033
6048
  type: 'http'
6034
6049
  }],
6035
- url: '/database/v1/databases/{database_id}/tables/{table}',
6050
+ url: '/crm/v1/pipelines/{objectType}/{pipelineId}',
6036
6051
  ...options
6037
6052
  });
6038
6053
  /**
6039
- * Get table
6054
+ * Retrieve pipeline
6040
6055
  *
6041
- * Returns one table by id or name with its field definitions, schema_revision and row_count. row_count is only returned by this operation, not by list or create. Use field ids from this response for stable references because field names can be renamed; an unknown table returns 404 TABLE_NOT_FOUND.
6056
+ * Inspect the stage ids and metadata of a pipeline before moving a record or editing its workflow. Obtain pipelineId from pipelines.list and use the returned stages array to select a destination. Stage rules are string values in stage.metadata: praxis_category is open (active), won (successful) or lost (unsuccessful); praxis_terminal is "true" (no further transition) or "false" (transitions allowed); praxis_allowed_next is a JSON-encoded array string of permitted next stage ids, with the string "null" meaning unrestricted; praxis_required is a JSON-encoded array string of property names ("[]" means none) that must be non-empty on entry (boolean properties must be "true"). Rule violations return HTTP 400 VALIDATION_ERROR; errors[0].context.properties lists missing required property names. Correct those values or choose an allowed stage before retrying. Example metadata: {"praxis_category":"open","praxis_terminal":"false","praxis_allowed_next":"[\"proposal\",\"lost\"]","praxis_required":"[\"budget\",\"decision_maker\"]"}.
6042
6057
  */
6043
- export const databaseGetTable = (options) => (options.client ?? client).get({
6058
+ export const crmPipelinesRetrieve = (options) => (options.client ?? client).get({
6044
6059
  security: [{
6045
- key: 'database-bearerAuth',
6060
+ key: 'crm-bearerAuth',
6046
6061
  scheme: 'bearer',
6047
6062
  type: 'http'
6048
6063
  }],
6049
- url: '/database/v1/databases/{database_id}/tables/{table}',
6064
+ url: '/crm/v1/pipelines/{objectType}/{pipelineId}',
6050
6065
  ...options
6051
6066
  });
6052
6067
  /**
6053
- * Update table
6068
+ * Update pipeline
6054
6069
  *
6055
- * Renames a table and/or changes its description; send only the keys to change, and send description null to clear it. The new name must follow ^[a-z_][a-z0-9_]{0,62}$ and be unused (409 UNIQUE_VIOLATION); ids are stable, so renaming never rewrites row data. A body with no changes or values equal to the current ones does not bump schema_revision. Fields cannot be changed here; use databaseAddField, databaseUpdateField and databaseDeleteField.
6070
+ * Change editable pipeline settings selected by pipelineId from pipelines.list. Omit settings that should remain unchanged and inspect current stages with pipelines.retrieve before modifying the workflow. Stage rules are string values in stage.metadata: praxis_category is open (active), won (successful) or lost (unsuccessful); praxis_terminal is "true" (no further transition) or "false" (transitions allowed); praxis_allowed_next is a JSON-encoded array string of permitted next stage ids, with the string "null" meaning unrestricted; praxis_required is a JSON-encoded array string of property names ("[]" means none) that must be non-empty on entry (boolean properties must be "true"). Rule violations return HTTP 400 VALIDATION_ERROR; errors[0].context.properties lists missing required property names. Correct those values or choose an allowed stage before retrying. Writes return refs (ResourceRef[]) for entity cards and optional property changes in conversations. Example metadata: {"praxis_category":"open","praxis_terminal":"false","praxis_allowed_next":"[\"proposal\",\"lost\"]","praxis_required":"[\"budget\",\"decision_maker\"]"}.
6056
6071
  */
6057
- export const databaseUpdateTable = (options) => (options.client ?? client).patch({
6072
+ export const crmPipelinesUpdate = (options) => (options.client ?? client).patch({
6058
6073
  security: [{
6059
- key: 'database-bearerAuth',
6074
+ key: 'crm-bearerAuth',
6060
6075
  scheme: 'bearer',
6061
6076
  type: 'http'
6062
6077
  }],
6063
- url: '/database/v1/databases/{database_id}/tables/{table}',
6078
+ url: '/crm/v1/pipelines/{objectType}/{pipelineId}',
6064
6079
  ...options,
6065
6080
  headers: {
6066
6081
  'Content-Type': 'application/json',
@@ -6068,17 +6083,17 @@ export const databaseUpdateTable = (options) => (options.client ?? client).patch
6068
6083
  }
6069
6084
  });
6070
6085
  /**
6071
- * Add field
6086
+ * Create pipeline stage
6072
6087
  *
6073
- * Adds one field to an existing table and returns the updated table (HTTP 201). Required inputs are name (lowercase letters, digits and underscores; id and names starting with _ are reserved) and type (string, integer, number, boolean, datetime, json or link); json needs options.schema and link needs options.linked_table_id and options.multiple. Adding a required field to a table that already has rows needs a default, otherwise the call fails with 400 VALIDATION_FAILED; a default is written into every existing row. Fields default to indexed:false. Set indexed:true explicitly for fields used in filters or ordering. Only indexed:true or unique:true consumes one of the 16 indexed-or-unique field slots; a field with both consumes one slot. Unique fields still consume a slot even with indexed:false. Existing fields are unchanged. Minimal field example: {"name":"notes","type":"string","indexed":false}. JSON and link fields cannot be indexed. Limits: 64 fields and 16 indexed or unique fields per table (400 LIMIT_EXCEEDED). Unlike Supabase, schema evolution uses field definitions rather than ALTER TABLE statements or SQL migrations.
6088
+ * Add an ordered stage to a pipeline from pipelines.list. Provide its display label, displayOrder and metadata; save the returned stage id for record updates. Stage rules are string values in stage.metadata: praxis_category is open (active), won (successful) or lost (unsuccessful); praxis_terminal is "true" (no further transition) or "false" (transitions allowed); praxis_allowed_next is a JSON-encoded array string of permitted next stage ids, with the string "null" meaning unrestricted; praxis_required is a JSON-encoded array string of property names ("[]" means none) that must be non-empty on entry (boolean properties must be "true"). Rule violations return HTTP 400 VALIDATION_ERROR; errors[0].context.properties lists missing required property names. Correct those values or choose an allowed stage before retrying. Writes return refs (ResourceRef[]) for entity cards and optional property changes in conversations. Example metadata: {"praxis_category":"open","praxis_terminal":"false","praxis_allowed_next":"[\"proposal\",\"lost\"]","praxis_required":"[\"budget\",\"decision_maker\"]"}.
6074
6089
  */
6075
- export const databaseAddField = (options) => (options.client ?? client).post({
6090
+ export const crmPipelinesStagesCreate = (options) => (options.client ?? client).post({
6076
6091
  security: [{
6077
- key: 'database-bearerAuth',
6092
+ key: 'crm-bearerAuth',
6078
6093
  scheme: 'bearer',
6079
6094
  type: 'http'
6080
6095
  }],
6081
- url: '/database/v1/databases/{database_id}/tables/{table}/fields',
6096
+ url: '/crm/v1/pipelines/{objectType}/{pipelineId}/stages',
6082
6097
  ...options,
6083
6098
  headers: {
6084
6099
  'Content-Type': 'application/json',
@@ -6086,31 +6101,31 @@ export const databaseAddField = (options) => (options.client ?? client).post({
6086
6101
  }
6087
6102
  });
6088
6103
  /**
6089
- * Delete field
6104
+ * Archive pipeline stage
6090
6105
  *
6091
- * Deletes one field definition from a table and returns the updated table; the deletion is immediate and has no recovery window. Look the field up by id or name. The field's index, if any, is dropped with it, and the name can be reused afterwards. Unknown fields return 400 FIELD_NOT_FOUND.
6106
+ * Archive a stage selected from pipelines.retrieve after checking record usage. A stage that still has records cannot be archived without resolving their assignment; move those records to an allowed stage first. Stage rules are string values in stage.metadata: praxis_category is open (active), won (successful) or lost (unsuccessful); praxis_terminal is "true" (no further transition) or "false" (transitions allowed); praxis_allowed_next is a JSON-encoded array string of permitted next stage ids, with the string "null" meaning unrestricted; praxis_required is a JSON-encoded array string of property names ("[]" means none) that must be non-empty on entry (boolean properties must be "true"). Rule violations return HTTP 400 VALIDATION_ERROR; errors[0].context.properties lists missing required property names. Correct those values or choose an allowed stage before retrying. Writes return refs (ResourceRef[]) for entity cards and optional property changes in conversations. Unlike HubSpot, this own-face archive returns HTTP 200 with a JSON refs body instead of HTTP 204. Example metadata: {"praxis_category":"open","praxis_terminal":"false","praxis_allowed_next":"[\"proposal\",\"lost\"]","praxis_required":"[\"budget\",\"decision_maker\"]"}.
6092
6107
  */
6093
- export const databaseDeleteField = (options) => (options.client ?? client).delete({
6108
+ export const crmPipelinesStagesArchive = (options) => (options.client ?? client).delete({
6094
6109
  security: [{
6095
- key: 'database-bearerAuth',
6110
+ key: 'crm-bearerAuth',
6096
6111
  scheme: 'bearer',
6097
6112
  type: 'http'
6098
6113
  }],
6099
- url: '/database/v1/databases/{database_id}/tables/{table}/fields/{field}',
6114
+ url: '/crm/v1/pipelines/{objectType}/{pipelineId}/stages/{stageId}',
6100
6115
  ...options
6101
6116
  });
6102
6117
  /**
6103
- * Update field
6118
+ * Update pipeline stage
6104
6119
  *
6105
- * Changes a field's name, description, required flag, indexed flag, default or json options.schema and returns the updated table. The field type, a link field's linked_table_id and the unique flag cannot be changed (400 FIELD_TYPE_IMMUTABLE or INVALID_PARAMS). Setting required to true fails with 400 VALIDATION_FAILED while existing rows hold null for the field. A new json schema constrains only later writes; existing rows are not revalidated. Renaming never rewrites row data, and a request that changes nothing does not bump schema_revision. Unlike Supabase, field types and uniqueness cannot be altered through SQL migrations; use the supported field settings described here.
6120
+ * Change the label, order or metadata of a stage selected from pipelines.retrieve. Existing records must satisfy entry rules when subsequently moved; omitted settings retain their values. Stage rules are string values in stage.metadata: praxis_category is open (active), won (successful) or lost (unsuccessful); praxis_terminal is "true" (no further transition) or "false" (transitions allowed); praxis_allowed_next is a JSON-encoded array string of permitted next stage ids, with the string "null" meaning unrestricted; praxis_required is a JSON-encoded array string of property names ("[]" means none) that must be non-empty on entry (boolean properties must be "true"). Rule violations return HTTP 400 VALIDATION_ERROR; errors[0].context.properties lists missing required property names. Correct those values or choose an allowed stage before retrying. Writes return refs (ResourceRef[]) for entity cards and optional property changes in conversations. Example metadata: {"praxis_category":"open","praxis_terminal":"false","praxis_allowed_next":"[\"proposal\",\"lost\"]","praxis_required":"[\"budget\",\"decision_maker\"]"}.
6106
6121
  */
6107
- export const databaseUpdateField = (options) => (options.client ?? client).patch({
6122
+ export const crmPipelinesStagesUpdate = (options) => (options.client ?? client).patch({
6108
6123
  security: [{
6109
- key: 'database-bearerAuth',
6124
+ key: 'crm-bearerAuth',
6110
6125
  scheme: 'bearer',
6111
6126
  type: 'http'
6112
6127
  }],
6113
- url: '/database/v1/databases/{database_id}/tables/{table}/fields/{field}',
6128
+ url: '/crm/v1/pipelines/{objectType}/{pipelineId}/stages/{stageId}',
6114
6129
  ...options,
6115
6130
  headers: {
6116
6131
  'Content-Type': 'application/json',
@@ -6118,93 +6133,91 @@ export const databaseUpdateField = (options) => (options.client ?? client).patch
6118
6133
  }
6119
6134
  });
6120
6135
  /**
6121
- * List events
6136
+ * List record associations
6122
6137
  *
6123
- * Read lifecycle and schema events, including while the database is deleting. next_cursor is an opaque string cursor (do not do arithmetic on it): pass it as after_seq for asc or before_seq for desc. Supplying both cursors returns 400 INVALID_PARAMS. Unlike Supabase Realtime, this is paged lifecycle and schema history, not a subscription or a row-change feed; row inserts, updates and deletes do not appear here.
6138
+ * Read records linked to a source record, including association labels and type ids. Obtain source and destination object types from schemas.list and objectId from objects.list or objects.search. Follow paging.next.after to continue reading associated records.
6124
6139
  */
6125
- export const databaseListEvents = (options) => (options.client ?? client).get({
6140
+ export const crmAssociationsList = (options) => (options.client ?? client).get({
6126
6141
  security: [{
6127
- key: 'database-bearerAuth',
6142
+ key: 'crm-bearerAuth',
6128
6143
  scheme: 'bearer',
6129
6144
  type: 'http'
6130
6145
  }],
6131
- url: '/database/v1/databases/{database_id}/events',
6146
+ url: '/crm/v1/objects/{objectType}/{objectId}/associations/{toObjectType}',
6132
6147
  ...options
6133
6148
  });
6134
6149
  /**
6135
- * Delete rows
6150
+ * Remove association
6136
6151
  *
6137
- * Deletes the rows matched by the filter query parameters (the same filters as databaseSelect); with no filter every row of the table matches. Deletion is immediate and cannot be undone. A row that a link field of another table still references makes the whole call fail with 409 REFERENCE_RESTRICT and nothing is deleted. The default response is 204 with no body; send Prefer: return=representation to get HTTP 200 with the deleted rows.
6152
+ * Remove the association between two existing records without archiving either record. Obtain the linked destination id from associations.list and confirm the source and destination object types before calling. Writes return refs (ResourceRef[]) for entity cards and optional property changes in conversations. Unlike HubSpot, this own-face archive returns HTTP 200 with a JSON refs body instead of HTTP 204.
6138
6153
  */
6139
- export const databaseDelete = (options) => (options.client ?? client).delete({
6154
+ export const crmAssociationsRemove = (options) => (options.client ?? client).delete({
6140
6155
  security: [{
6141
- key: 'database-bearerAuth',
6156
+ key: 'crm-bearerAuth',
6142
6157
  scheme: 'bearer',
6143
6158
  type: 'http'
6144
6159
  }],
6145
- url: '/database/v1/databases/{database_id}/rest/{table}',
6160
+ url: '/crm/v1/objects/{objectType}/{objectId}/associations/{toObjectType}/{toObjectId}',
6146
6161
  ...options
6147
6162
  });
6148
6163
  /**
6149
- * Select rows
6164
+ * Create labelled association
6150
6165
  *
6151
- * Read matching rows with filters, selected columns and ordering. Returns at most 1000 rows per request, including when limit is omitted. Content-Range reports the actual returned interval and the total when count is requested. PATCH and DELETE are not subject to this read cap. Unlike Supabase, casts, aggregates, spread and join modifiers are unsupported. Each table supports up to 1,000,000 rows. Query budget: 8,000 ms with a shared 3,000,000-row safety ceiling. Create indexes on filtered or sorted fields, or narrow the request when it exceeds its budget. Synchronous SQLite aggregates use candidate-row throughput estimates before execution; deployed Workers freeze clocks during synchronous CPU work, so the timer is not a guaranteed server-side interrupt. Count preferences: without filters, exact, planned and estimated all use SQLite's exact b-tree count. With filters, exact counts within budget; planned skips counting and reports an unknown total (Content-Range: 0-24*); estimated attempts exact counting only when the preflight budget allows it, otherwise reports an unknown total. Preference-Applied echoes the requested count mode. Error table: QUERY_CANCELED / PostgREST 57014 is HTTP 500, retryable=false: Query timed out: index filtered or sorted fields, or narrow the range. DATABASE_INVALID_STATE is HTTP 409 for operations on a deleting database. Cleared or nonexistent databases return DATABASE_NOT_FOUND / HTTP 404. The count is an HTTP Content-Range response header, not a JSON property. Use praxis.database.count in the SDK or codemode to return { count: number | null }; a page length is not a total unless you know all matches fit in that page.
6166
+ * Associate two existing records using the requested association category and type id. Obtain record ids from objects.list or objects.search; reuse known association type ids from associations.list. Send the association-spec array as the body; use associations.createDefault when no label is needed. Writes return refs (ResourceRef[]) for entity cards and optional property changes in conversations.
6152
6167
  */
6153
- export const databaseSelect = (options) => (options.client ?? client).get({
6168
+ export const crmAssociationsCreate = (options) => (options.client ?? client).put({
6154
6169
  security: [{
6155
- key: 'database-bearerAuth',
6170
+ key: 'crm-bearerAuth',
6156
6171
  scheme: 'bearer',
6157
6172
  type: 'http'
6158
6173
  }],
6159
- url: '/database/v1/databases/{database_id}/rest/{table}',
6160
- ...options
6174
+ url: '/crm/v1/objects/{objectType}/{objectId}/associations/{toObjectType}/{toObjectId}',
6175
+ ...options,
6176
+ headers: {
6177
+ 'Content-Type': 'application/json',
6178
+ ...options.headers
6179
+ }
6161
6180
  });
6162
6181
  /**
6163
- * Count rows
6182
+ * Create default association
6164
6183
  *
6165
- * Inspect the HTTP row count and range without retrieving row data; send Prefer: count=exact for a filtered count. Returns no body and does not fetch or serialize row data. A known count determines the interval using limit/offset or Range with a default and maximum page size of 1000. Without a count preference, or when the selected count mode cannot supply a total, Content-Range is **. Singular Accept still validates page cardinality. Unlike Supabase, planned and estimated counts do not use PostgreSQL planner estimates. Count preferences: without filters, exact, planned and estimated all use SQLite's exact b-tree count. With filters, exact counts within budget; planned skips counting and reports an unknown total (Content-Range: 0-24*); estimated attempts exact counting only when the preflight budget allows it, otherwise reports an unknown total. Preference-Applied echoes the requested count mode. Use praxis.database.count in the SDK or codemode to return { count: number | null } from this header without retrieving rows.
6184
+ * Link two existing records with the default unlabelled association. Obtain each record id from objects.list or objects.search for its type. No request body is required; use associations.create to choose explicit association labels. Writes return refs (ResourceRef[]) for entity cards and optional property changes in conversations.
6166
6185
  */
6167
- export const databaseHead = (options) => (options.client ?? client).head({
6186
+ export const crmAssociationsCreateDefault = (options) => (options.client ?? client).put({
6168
6187
  security: [{
6169
- key: 'database-bearerAuth',
6188
+ key: 'crm-bearerAuth',
6170
6189
  scheme: 'bearer',
6171
6190
  type: 'http'
6172
6191
  }],
6173
- url: '/database/v1/databases/{database_id}/rest/{table}',
6192
+ url: '/crm/v1/objects/{objectType}/{objectId}/associations/default/{toObjectType}/{toObjectId}',
6174
6193
  ...options
6175
6194
  });
6176
6195
  /**
6177
- * Update rows
6196
+ * List object schemas
6178
6197
  *
6179
- * Updates the rows matched by the filter query parameters (the same filters as databaseSelect); with no filter every row of the table matches. The JSON object body lists only the fields to change, other fields keep their values, and id cannot be changed. Values are validated against the field types and the required and unique settings (400 VALIDATION_FAILED, 409 UNIQUE_VIOLATION). The default response is 204 with no body; send Prefer: return=representation to get HTTP 200 with the updated rows. Each changed row's _version increases by one.
6198
+ * Discover available object schemas, display labels, property definitions and association definitions. Reuse the object type identifier or name in record, property and pipeline operations. archived defaults to false; the include parameters control the definition and audit details returned.
6180
6199
  */
6181
- export const databaseUpdate = (options) => (options.client ?? client).patch({
6200
+ export const crmSchemasList = (options) => (options?.client ?? client).get({
6182
6201
  security: [{
6183
- key: 'database-bearerAuth',
6202
+ key: 'crm-bearerAuth',
6184
6203
  scheme: 'bearer',
6185
6204
  type: 'http'
6186
6205
  }],
6187
- url: '/database/v1/databases/{database_id}/rest/{table}',
6188
- ...options,
6189
- headers: {
6190
- 'Content-Type': 'application/json',
6191
- ...options.headers
6192
- }
6206
+ url: '/crm/v1/schemas',
6207
+ ...options
6193
6208
  });
6194
6209
  /**
6195
- * Insert rows
6210
+ * Create object schema
6196
6211
  *
6197
- * Insert rows into an existing table after defining its fields; at most 500 rows per request. Each request is atomic: any failure rolls back the entire batch. There are no transactions across requests.
6198
- * Rows are filled to the union of their keys with null; send Prefer: missing=default to use field defaults for missing keys.
6199
- * The default is return=minimal: success returns HTTP 201 with an empty body. Send Prefer: return=representation to return the inserted rows. With resolution=merge-duplicates, a conflicting row keeps columns omitted from the request; supplied values replace the whole field value (including JSON objects), and explicit null clears a nullable field. With resolution=ignore-duplicates, a conflicting row is left unchanged. Without a conflict, both modes insert a new row using field defaults for omitted fields. In a batch, a key present in another row is filled with null when omitted in this row unless missing=default is set; that null can overwrite a value during merge. With missing=default, omitted keys stay omitted for conflict merges (existing values are preserved); new rows use defaults, or null when no default exists. Explicit null never invokes a default. Unlike Supabase, upsert conflicts can target only id or one unique field, not a composite key. Each table supports up to 1,000,000 rows.
6212
+ * Define a custom CRM object type before creating its records. Provide its immutable name, singular and plural labels, primaryDisplayProperty, properties and associated object types. Save the returned object type identifier for subsequent record and property operations. Writes return refs (ResourceRef[]) for entity cards and optional property changes in conversations.
6200
6213
  */
6201
- export const databaseInsert = (options) => (options.client ?? client).post({
6214
+ export const crmSchemasCreate = (options) => (options.client ?? client).post({
6202
6215
  security: [{
6203
- key: 'database-bearerAuth',
6216
+ key: 'crm-bearerAuth',
6204
6217
  scheme: 'bearer',
6205
6218
  type: 'http'
6206
6219
  }],
6207
- url: '/database/v1/databases/{database_id}/rest/{table}',
6220
+ url: '/crm/v1/schemas',
6208
6221
  ...options,
6209
6222
  headers: {
6210
6223
  'Content-Type': 'application/json',
@@ -6212,31 +6225,17 @@ export const databaseInsert = (options) => (options.client ?? client).post({
6212
6225
  }
6213
6226
  });
6214
6227
  /**
6215
- * List knowledge bases
6216
- *
6217
- * Lists knowledge bases visible to the caller, newest first by default. Use last_id as after to read the next page; for example, ?limit=20.
6218
- */
6219
- export const knowledgeListVectorStores = (options) => (options?.client ?? client).get({
6220
- security: [{
6221
- key: 'knowledge-bearerAuth',
6222
- scheme: 'bearer',
6223
- type: 'http'
6224
- }],
6225
- url: '/knowledge/v1/vector_stores',
6226
- ...options
6227
- });
6228
- /**
6229
- * Create knowledge base
6228
+ * Qualify lead
6230
6229
  *
6231
- * Create a knowledge base, optionally starting ingestion of uploaded file_ids in the same call; no separate attachment or batch is needed for those files. Use the returned id with vectorStores.files.retrieve to poll each attachment until completed, failed or cancelled; store status=completed alone does not mean every file succeeded. Unlike OpenAI vector stores, each file is limited to 100000000 bytes and each account to 100 active/nondeleted stores. Minimal body: {"name":"Refund policies"}.
6230
+ * Qualify a lead with explicit contact, company and optional deal choices in one operation. Unlike HubSpot, CRM exposes these decisions as a single action because qualification coordinates several related record edits rather than editing only the lead stage. Obtain leadId from objects.list for leads and qualifiedStageId from its pipeline; choose a won stage and satisfy its required properties. Writes return refs (ResourceRef[]) for entity cards and optional property changes in conversations.
6232
6231
  */
6233
- export const knowledgeCreateVectorStore = (options) => (options.client ?? client).post({
6232
+ export const crmLeadsQualify = (options) => (options.client ?? client).post({
6234
6233
  security: [{
6235
- key: 'knowledge-bearerAuth',
6234
+ key: 'crm-bearerAuth',
6236
6235
  scheme: 'bearer',
6237
6236
  type: 'http'
6238
6237
  }],
6239
- url: '/knowledge/v1/vector_stores',
6238
+ url: '/crm/v1/leads/{leadId}:qualify',
6240
6239
  ...options,
6241
6240
  headers: {
6242
6241
  'Content-Type': 'application/json',
@@ -6244,45 +6243,45 @@ export const knowledgeCreateVectorStore = (options) => (options.client ?? client
6244
6243
  }
6245
6244
  });
6246
6245
  /**
6247
- * Delete knowledge base
6246
+ * Revert change set
6248
6247
  *
6249
- * Remove a knowledge base from active use while keeping a recovery window. Unlike OpenAI vector stores, native DELETE returns the store with status=deleting and ISO purge_at, retains it for 7 days and is idempotent on repeat. Retrieve remains 200; object operations return 409. Use restore before purge_at to recover it, or purge to remove it irreversibly.
6248
+ * Reverse property changes made by one earlier request. Unlike HubSpot, CRM exposes change-set reversal because agents need to undo a whole recorded action rather than manually reconstructing individual values. Supply the changeSetId recorded in property history. A later conflicting value prevents reversal with HTTP 409 CONFLICT; inspect current records before resolving the conflict. Writes return refs (ResourceRef[]) for entity cards and optional property changes in conversations.
6250
6249
  */
6251
- export const knowledgeDeleteVectorStore = (options) => (options.client ?? client).delete({
6250
+ export const crmChangesRevert = (options) => (options.client ?? client).post({
6252
6251
  security: [{
6253
- key: 'knowledge-bearerAuth',
6252
+ key: 'crm-bearerAuth',
6254
6253
  scheme: 'bearer',
6255
6254
  type: 'http'
6256
6255
  }],
6257
- url: '/knowledge/v1/vector_stores/{vector_store_id}',
6256
+ url: '/crm/v1/changes/{changeSetId}:revert',
6258
6257
  ...options
6259
6258
  });
6260
6259
  /**
6261
- * Retrieve knowledge base
6260
+ * Retrieve record layout
6262
6261
  *
6263
- * Retrieves a knowledge base using an id returned by create or list. Add ?expand=files to include the first page of attached files. Soft-deleted stores remain readable with status=deleting until purged.
6262
+ * Read the shared record-page layout for an object type from schemas.list. Unlike HubSpot, CRM exposes this presentation as an API resource so people and agents can share the same record layout instead of relying on interface-only settings. The response orders summary tiles, sidebar properties and main-column sections.
6264
6263
  */
6265
- export const knowledgeRetrieveVectorStore = (options) => (options.client ?? client).get({
6264
+ export const crmLayoutsRetrieve = (options) => (options.client ?? client).get({
6266
6265
  security: [{
6267
- key: 'knowledge-bearerAuth',
6266
+ key: 'crm-bearerAuth',
6268
6267
  scheme: 'bearer',
6269
6268
  type: 'http'
6270
6269
  }],
6271
- url: '/knowledge/v1/vector_stores/{vector_store_id}',
6270
+ url: '/crm/v1/layouts/{objectType}',
6272
6271
  ...options
6273
6272
  });
6274
6273
  /**
6275
- * Update knowledge base
6274
+ * Update record layout
6276
6275
  *
6277
- * Updates an active knowledge base using its returned id. Omitted fields stay unchanged; metadata replaces the whole map. Example body: {"name":"Refund policies"}.
6276
+ * Replace the shared record-page layout for an object type from schemas.list. Unlike HubSpot, CRM exposes this presentation as an API resource so agents can configure the same record view used by people. Send the complete layout with at most three summary tiles and property names from properties.list; omitted prior sections are removed. Writes return refs (ResourceRef[]) for entity cards and optional property changes in conversations.
6278
6277
  */
6279
- export const knowledgeUpdateVectorStore = (options) => (options.client ?? client).post({
6278
+ export const crmLayoutsUpdate = (options) => (options.client ?? client).put({
6280
6279
  security: [{
6281
- key: 'knowledge-bearerAuth',
6280
+ key: 'crm-bearerAuth',
6282
6281
  scheme: 'bearer',
6283
6282
  type: 'http'
6284
6283
  }],
6285
- url: '/knowledge/v1/vector_stores/{vector_store_id}',
6284
+ url: '/crm/v1/layouts/{objectType}',
6286
6285
  ...options,
6287
6286
  headers: {
6288
6287
  'Content-Type': 'application/json',
@@ -6290,49 +6289,39 @@ export const knowledgeUpdateVectorStore = (options) => (options.client ?? client
6290
6289
  }
6291
6290
  });
6292
6291
  /**
6293
- * Search knowledge base
6292
+ * List projects
6294
6293
  *
6295
- * Search ingested text to answer a question or find supporting passages. Native results contain one chunk each, so file_id can repeat; max_num_results counts chunks (1–50, default 10), while the compatible URL groups results by file. Unlike OpenAI vector stores, next_page is always null even when has_more is true. Only completed attachments are searchable. For keyword-only retrieval set ranking_options.hybrid_search to {"embedding_weight":0,"text_weight":1}; omit rewrite_query or set it to false to avoid query rewriting. Unlike OpenAI, ranker auto does not rerank; only default-2024-11-15 requests reranking. Set praxis.explain=true to inspect scores and use returned content[].chunk_id to retrieve a segment.
6294
+ * Discover projects owned by the API key organization and obtain project_id values. Results default to active projects ordered by updateTime descending; use filter state = "deleted" to find retained deleted projects for undelete. Continue with next_page_token as page_token until the token is absent.
6296
6295
  */
6297
- export const knowledgeSearchVectorStore = (options) => (options.client ?? client).post({
6296
+ export const cutListProjects = (options) => (options?.client ?? client).get({
6298
6297
  security: [{
6299
- key: 'knowledge-bearerAuth',
6298
+ key: 'BearerAuth',
6300
6299
  scheme: 'bearer',
6301
6300
  type: 'http'
6301
+ }, {
6302
+ key: 'ApiKeyAuth',
6303
+ name: 'X-API-Key',
6304
+ type: 'apiKey'
6302
6305
  }],
6303
- url: '/knowledge/v1/vector_stores/{vector_store_id}/search',
6304
- ...options,
6305
- headers: {
6306
- 'Content-Type': 'application/json',
6307
- ...options.headers
6308
- }
6306
+ url: '/cut/v1/projects',
6307
+ ...options
6309
6308
  });
6310
6309
  /**
6311
- * List files
6310
+ * Create project
6312
6311
  *
6313
- * Lists attached files and their ingestion status, newest attachment first by default. Use last_id as after to continue; ?filter=failed selects files that can be retried.
6312
+ * Create a blank editing project in the API key organization before writing a script. First obtain accessible library ids from praxis.media; bindings must include exactly one read_write library with default_upload true. Each call creates a new project and returns HTTP 201; save its id for execute, state and timeline calls. All editing positions use seconds.
6314
6313
  */
6315
- export const knowledgeListFiles = (options) => (options.client ?? client).get({
6314
+ export const cutCreateProject = (options) => (options.client ?? client).post({
6316
6315
  security: [{
6317
- key: 'knowledge-bearerAuth',
6316
+ key: 'BearerAuth',
6318
6317
  scheme: 'bearer',
6319
6318
  type: 'http'
6319
+ }, {
6320
+ key: 'ApiKeyAuth',
6321
+ name: 'X-API-Key',
6322
+ type: 'apiKey'
6320
6323
  }],
6321
- url: '/knowledge/v1/vector_stores/{vector_store_id}/files',
6322
- ...options
6323
- });
6324
- /**
6325
- * Add file
6326
- *
6327
- * Attach an uploaded File for asynchronous ingestion, then poll this attachment until status is completed, failed or cancelled before searching. Unlike OpenAI vector stores, the file limit is 100000000 bytes; chunk sizes use estimated tokens rather than a model tokenizer. Text, Markdown, CSV, JSON, HTML, PDF, DOCX, PPTX, XLSX and PNG/JPEG/GIF/WebP images can be extracted; audio and video uploads are not knowledge documents. Images may yield generated descriptions rather than verbatim OCR. auto chunking resolves to static 800/400; explicit sizes are 100–4096 with overlap at most half the size. Each store holds at most 10000 attached files. Reattaching the same file returns its existing record without applying new attributes or chunking; inspect last_error after failure.
6328
- */
6329
- export const knowledgeAttachFile = (options) => (options.client ?? client).post({
6330
- security: [{
6331
- key: 'knowledge-bearerAuth',
6332
- scheme: 'bearer',
6333
- type: 'http'
6334
- }],
6335
- url: '/knowledge/v1/vector_stores/{vector_store_id}/files',
6324
+ url: '/cut/v1/projects',
6336
6325
  ...options,
6337
6326
  headers: {
6338
6327
  'Content-Type': 'application/json',
@@ -6340,45 +6329,57 @@ export const knowledgeAttachFile = (options) => (options.client ?? client).post(
6340
6329
  }
6341
6330
  });
6342
6331
  /**
6343
- * Remove file
6332
+ * Delete project
6344
6333
  *
6345
- * Removes the file from search immediately; does not delete the original File.
6334
+ * Soft-delete a project selected from projects.list. The project is retained for seven days until purge_time and can be restored with undelete before that deadline. Deleted projects cannot be edited; list with filter state = "deleted" to locate retained projects.
6346
6335
  */
6347
- export const knowledgeRemoveFile = (options) => (options.client ?? client).delete({
6336
+ export const cutDeleteProject = (options) => (options.client ?? client).delete({
6348
6337
  security: [{
6349
- key: 'knowledge-bearerAuth',
6338
+ key: 'BearerAuth',
6350
6339
  scheme: 'bearer',
6351
6340
  type: 'http'
6341
+ }, {
6342
+ key: 'ApiKeyAuth',
6343
+ name: 'X-API-Key',
6344
+ type: 'apiKey'
6352
6345
  }],
6353
- url: '/knowledge/v1/vector_stores/{vector_store_id}/files/{file_id}',
6346
+ url: '/cut/v1/projects/{project_id}',
6354
6347
  ...options
6355
6348
  });
6356
6349
  /**
6357
- * Retrieve file
6350
+ * Retrieve project
6358
6351
  *
6359
- * Retrieves an attached file using the id returned by attachment or file listing. Poll this operation until status leaves in_progress to observe the ingestion outcome.
6352
+ * Inspect project metadata, settings and library bindings before editing. Copy id from projects.create or list; expand=timeline,exports,versions includes selected related resources. The expanded timeline uses seconds and the returned revision can guard a later execute call with expected_revision.
6360
6353
  */
6361
- export const knowledgeRetrieveFile = (options) => (options.client ?? client).get({
6354
+ export const cutRetrieveProject = (options) => (options.client ?? client).get({
6362
6355
  security: [{
6363
- key: 'knowledge-bearerAuth',
6356
+ key: 'BearerAuth',
6364
6357
  scheme: 'bearer',
6365
6358
  type: 'http'
6359
+ }, {
6360
+ key: 'ApiKeyAuth',
6361
+ name: 'X-API-Key',
6362
+ type: 'apiKey'
6366
6363
  }],
6367
- url: '/knowledge/v1/vector_stores/{vector_store_id}/files/{file_id}',
6364
+ url: '/cut/v1/projects/{project_id}',
6368
6365
  ...options
6369
6366
  });
6370
6367
  /**
6371
- * Update file attributes
6368
+ * Update project metadata
6372
6369
  *
6373
- * Replaces search-filter attributes of an existing attachment without reingesting its content. Use an attached file id. Example body: {"attributes":{"category":"refund"}}; null clears the attributes.
6370
+ * Change the project display name or replace its labels by naming those fields in update_mask. Use execute for clip or track edits. Each successful update commits a new revision; labels are replaced as a whole when selected, so read and merge existing labels before overwriting them.
6374
6371
  */
6375
- export const knowledgeUpdateFile = (options) => (options.client ?? client).post({
6372
+ export const cutUpdateProject = (options) => (options.client ?? client).patch({
6376
6373
  security: [{
6377
- key: 'knowledge-bearerAuth',
6374
+ key: 'BearerAuth',
6378
6375
  scheme: 'bearer',
6379
6376
  type: 'http'
6377
+ }, {
6378
+ key: 'ApiKeyAuth',
6379
+ name: 'X-API-Key',
6380
+ type: 'apiKey'
6380
6381
  }],
6381
- url: '/knowledge/v1/vector_stores/{vector_store_id}/files/{file_id}',
6382
+ url: '/cut/v1/projects/{project_id}',
6382
6383
  ...options,
6383
6384
  headers: {
6384
6385
  'Content-Type': 'application/json',
@@ -6386,31 +6387,190 @@ export const knowledgeUpdateFile = (options) => (options.client ?? client).post(
6386
6387
  }
6387
6388
  });
6388
6389
  /**
6389
- * Read extracted content
6390
+ * Restore deleted project
6390
6391
  *
6391
- * Extracted text chunks may overlap. Image content can be a generated description rather than verbatim OCR.
6392
+ * Return a retained deleted project to active state before its purge_time. Obtain project_id from projects.list filtered to deleted projects. This restores the project, not an older timeline revision; use versions.restore when reverting editing content.
6392
6393
  */
6393
- export const knowledgeRetrieveFileContent = (options) => (options.client ?? client).get({
6394
+ export const cutUndeleteProject = (options) => (options.client ?? client).post({
6394
6395
  security: [{
6395
- key: 'knowledge-bearerAuth',
6396
+ key: 'BearerAuth',
6396
6397
  scheme: 'bearer',
6397
6398
  type: 'http'
6399
+ }, {
6400
+ key: 'ApiKeyAuth',
6401
+ name: 'X-API-Key',
6402
+ type: 'apiKey'
6398
6403
  }],
6399
- url: '/knowledge/v1/vector_stores/{vector_store_id}/files/{file_id}/content',
6404
+ url: '/cut/v1/projects/{project_id}:undelete',
6400
6405
  ...options
6401
6406
  });
6402
6407
  /**
6403
- * Create file batch
6408
+ * Execute editing script
6409
+ *
6410
+ * Edit the current timeline atomically using synchronous JavaScript source. Read state or timeline first, then pass its revision as expected_revision to detect concurrent changes. Unlike Shotstack, execute applies script edits to a persistent project in one transaction. Provide script or a saved edit_id with literal edits, never both; failures roll back writes. A revision conflict while preparing the response may follow a committed edit: retrieve state before retrying. Minimal script after creating a project: `const t = AddTrack("video"); Insert(t, {type: "color", color: "#123456", start: 0, length: 3}); Print(t);`
6411
+ *
6412
+ * <!-- cut-reference:start -->
6413
+ * ### Script function, field and error reference
6414
+ *
6415
+ * Every script function, clip field and error code has its own section, read one at a time:
6416
+ *
6417
+ * ```
6418
+ * codemode.describe("praxis.cut.script.<Name>") // one function: signature, arguments, return, errors, example
6419
+ * codemode.describe("praxis.cut.fields.<name>") // one field: type, unit, range, default, where writable
6420
+ * codemode.describe("praxis.cut.errors.<CODE>") // one code: meaning, causes, fix
6421
+ * codemode.describe("praxis.cut.script") // names, one page at a time
6422
+ * ```
6423
+ *
6424
+ * Published at https://docs.deepraxis.com/docs/developers/cut/script-reference with one anchor per entry. Names below omit the `praxis.cut.<kind>.` prefix.
6425
+ *
6426
+ * #### Script functions (script)
6427
+ *
6428
+ * - `GetTimeline` — Duration, tracks, joins; clips are under `items`.
6429
+ * - `GetItem` — One clip's compact view, by id.
6430
+ * - `FindItems` — Visit every clip with its track; collect results.
6431
+ * - `GetMedia` — Media metadata; `durationUs` is microseconds.
6432
+ * - `GetTranscript` — Transcript words in source microseconds.
6433
+ * - `GetAnalysis` — Silence, filler or scene segments.
6434
+ * - `ListTransitions` — Join transition kinds and parameters.
6435
+ * - `ListEffects` — Visual-effect catalog and parameters.
6436
+ * - `ListAnimations` — Animation presets by phase and target.
6437
+ * - `ListFonts` — Font families, weights and scripts.
6438
+ * - `ListTextStyles` — Text style presets for `style.preset`.
6439
+ * - `ListTextTemplates` — Multi-layer templates and their slots.
6440
+ * - `Insert` — Add a clip; a track never overlaps itself.
6441
+ * - `Append` — Add a clip at the end of a track.
6442
+ * - `Update` — Change named fields; the rest stay.
6443
+ * - `SetSpeed` — Change rate, keeping source or duration.
6444
+ * - `Delete` — Remove a clip. There is no `Remove`.
6445
+ * - `Join` — Overlap clips; followers shift, track shortens.
6446
+ * - `UpdateJoin` — Change a join's length or effect.
6447
+ * - `DeleteJoin` — Remove a join; restore the butt cut.
6448
+ * - `Split` — Cut a clip in two at a time.
6449
+ * - `Trim` — Move one clip edge by seconds.
6450
+ * - `Move` — Set a clip's start or track.
6451
+ * - `RippleDeleteRange` — Cut a time range and close the gap.
6452
+ * - `AddTrack` — Add a video, audio or caption track.
6453
+ * - `UpdateTrack` — Change a track's name, lock, gain or role.
6454
+ * - `DeleteTrack` — Remove a track and its clips.
6455
+ * - `SetSettings` — Change canvas, frame rate or background.
6456
+ * - `AddCaptionsFromTranscript` — Captions from a clip's kept words.
6457
+ * - `InsertTemplate` — Insert a template and fill its slots.
6458
+ * - `AlignCaptions` — Rebuild captions from text punctuation.
6459
+ * - `ImportCaptions` — Import SRT or WebVTT onto captions.
6460
+ * - `ExportCaptions` — Export captions as SRT or WebVTT.
6461
+ * - `SetMarker` — Label a timeline position.
6462
+ * - `Print` — Append values to the result's `prints`.
6463
+ * - `Preview` — Up to 8 frames as inline PNG data URLs.
6464
+ *
6465
+ * #### Fields (fields)
6466
+ *
6467
+ * - `type` — Clip kind; decides which fields apply.
6468
+ * - `start` — Clip start in seconds; snaps to frames.
6469
+ * - `length` — Duration; optional for video and audio.
6470
+ * - `media` — Source `{ libraryId, assetId }`.
6471
+ * - `sourceIn` — First source second kept; default 0.
6472
+ * - `sourceOut` — Exclusive source end; read-only.
6473
+ * - `text` — Text of a text or caption clip.
6474
+ * - `color` — Solid colour of a color clip.
6475
+ * - `shape` — Shape clip kind: `rect` or `ellipse`.
6476
+ * - `width` — Shape width, a fraction of canvas width.
6477
+ * - `height` — Shape height, a fraction of canvas height.
6478
+ * - `radius` — Rect corner rounding, in 1080-height px.
6479
+ * - `fill` — Shape or text paint: colour or gradient.
6480
+ * - `stroke` — Shape outline: colour and width.
6481
+ * - `transform` — Position, scale, rotation, opacity, crop, blur.
6482
+ * - `fit` — contain, cover, fill or none.
6483
+ * - `blend` — Layer blend mode; null clears.
6484
+ * - `style` — Text styling: font, fill, strokes, glow, position.
6485
+ * - `style.position` — top, middle or bottom; omit it, never null.
6486
+ * - `playback` — Rate, direction, audio policy, or freeze.
6487
+ * - `volumeDb` — Audio level in dB; 0 is source level.
6488
+ * - `gain` — Keyframed audio level in dB.
6489
+ * - `fadeIn` — Fade-in seconds at the clip's start.
6490
+ * - `fadeOut` — Fade-out seconds at the clip's end.
6491
+ * - `duck` — Lower this clip while another track plays.
6492
+ * - `animate` — Transform keyframes; `at` is clip-relative seconds.
6493
+ * - `reveal` — Per-character, word or line reveal timing.
6494
+ * - `animation` — Preset slots `{ in, out, loop }`; null clears.
6495
+ * - `effects` — Effect stack, at most 8; null clears.
6496
+ * - `transitionIn` — Entrance effect: kind plus seconds.
6497
+ * - `transitionOut` — Exit effect: kind plus seconds.
6498
+ * - `mask` — Shape, path or track matte.
6499
+ * - `words` — Caption words with clip-local times.
6500
+ *
6501
+ * #### Error codes (errors)
6502
+ *
6503
+ * - `JOIN_CONFLICT` — A join is invalid or blocks this edit.
6504
+ * - `INVALID_TRANSITION` — Bad transition kind, parameter or length.
6505
+ * - `INVALID_STYLE` — A style value is out of range.
6506
+ * - `INVALID_MASK` — A mask definition is malformed.
6507
+ * - `MASK_IN_USE` — The edit would break a live mask.
6508
+ * - `TOO_MANY_MASKS` — At most 16 masks per project.
6509
+ * - `RATE_OUT_OF_RANGE` — A rate is outside 0.25-4.
6510
+ * - `UNSUPPORTED_PLAYBACK` — Reverse without an explicit mute.
6511
+ * - `INVALID_PLAYBACK` — A playback object is partial or malformed.
6512
+ * - `UNKNOWN_FONT` — The family is not in `ListFonts()`.
6513
+ * - `UNKNOWN_FIELD` — The field name is not accepted here.
6514
+ * - `UNKNOWN_TEXT_STYLE` — `style.preset` is not in the catalog.
6515
+ * - `TEXT_STYLE_TARGET_MISMATCH` — Preset on the wrong clip type.
6516
+ * - `CAPTION_ALIGN_LOW_CONFIDENCE` — Alignment confidence too low; nothing changed.
6517
+ * - `OVERLAP` — Two clips on one track would share time.
6518
+ * - `OUT_OF_SOURCE` — The clip would read past its source.
6519
+ * - `LOCKED_TRACK` — The edit targets a locked track.
6520
+ * - `UNBOUND_LIBRARY` — The library is not bound to the project.
6521
+ * - `TRACK_KIND_MISMATCH` — The clip type does not fit the track.
6522
+ * - `NOT_FOUND` — The named id is not in this project.
6523
+ * - `TOO_SHORT` — The result would be under one frame.
6524
+ * - `INVALID_DUCK` — Bad `duck` level or a missing track.
6525
+ * - `UNKNOWN_ANIMATION` — The preset is not in `ListAnimations()`.
6526
+ * - `INVALID_ANIMATION_PARAM` — Bad slot, parameter or keyframe limit.
6527
+ * - `ANIMATION_TOO_LONG` — In plus out exceed the clip length.
6528
+ * - `ANIMATION_TARGET_MISMATCH` — The preset does not match the clip type.
6529
+ * - `ANIMATION_PHASE_MISMATCH` — The preset is in the wrong slot.
6530
+ * - `UNKNOWN_EFFECT` — The effect is not in `ListEffects()`.
6531
+ * - `INVALID_EFFECT_PARAM` — Bad effect parameter or keyframe.
6532
+ * - `TOO_MANY_EFFECTS` — More than 8 effects on one clip.
6533
+ * - `PROJECT_NOT_FOUND` — No visible project has this id.
6534
+ * - `EXPORT_NOT_FOUND` — No such export in this project.
6535
+ * - `VERSION_NOT_FOUND` — No saved version has this revision.
6536
+ * - `LIBRARY_NOT_FOUND` — The library is missing or invisible.
6537
+ * - `BINDING_INVALID` — The binding request is malformed.
6538
+ * - `BINDING_IN_USE` — Clips still use this library's assets.
6539
+ * - `NOTHING_TO_UNDO` — No earlier revision to return to.
6540
+ * - `NOTHING_TO_REDO` — No undone revision is waiting.
6541
+ * - `UNDO_CONFLICT` — The revision to undo is no longer head.
6542
+ * - `REVISION_CONFLICT` — The project moved; your revision is stale.
6543
+ * - `CUT_BUSY` — The project is busy; retry.
6544
+ * - `INVALID_CAPTION_FILE` — The subtitle file is malformed or too big.
6545
+ * - `SCRIPT_ERROR` — The script threw or did not parse.
6546
+ * - `SCRIPT_LIMIT` — An execute budget was exceeded.
6547
+ * - `OPS_REJECTED` — An op failed; the whole edit rolled back.
6548
+ * - `EDIT_EXPIRED` — The saved edit id is over ten minutes old.
6549
+ * - `MEDIA_OFFLINE` — The asset cannot be fetched right now.
6550
+ * - `MEDIA_UNAVAILABLE` — The asset is not usable for rendering.
6551
+ * - `MEDIA_IMPORT_FAILED` — Importing media failed.
6552
+ * - `FRAME_OUT_OF_RANGE` — The preview time is outside the project.
6553
+ * - `PROJECT_TOO_LARGE` — The project exceeds the size limit.
6554
+ * - `RESPONSE_TOO_LARGE` — The response would exceed its budget.
6555
+ * - `EXPORT_FAILED` — The render failed; read `error.cause`.
6556
+ * - `INVALID_PARAMS` — The request is malformed.
6557
+ * - `PERMISSION_DENIED` — This credential may not do that here.
6558
+ * - `NOT_IMPLEMENTED` — Not available on this platform yet.
6559
+ * - `INTERNAL` — Unexpected failure; retry with the request id.
6560
+ * <!-- cut-reference:end -->
6404
6561
  *
6405
- * Attaches existing Files as a batch for asynchronous ingestion. Supply exactly one of file_ids or files; files allows per-file settings. Existing attachments are reused. Read the returned batch id to monitor status.
6406
6562
  */
6407
- export const knowledgeCreateFileBatch = (options) => (options.client ?? client).post({
6563
+ export const cutExecute = (options) => (options.client ?? client).post({
6408
6564
  security: [{
6409
- key: 'knowledge-bearerAuth',
6565
+ key: 'BearerAuth',
6410
6566
  scheme: 'bearer',
6411
6567
  type: 'http'
6568
+ }, {
6569
+ key: 'ApiKeyAuth',
6570
+ name: 'X-API-Key',
6571
+ type: 'apiKey'
6412
6572
  }],
6413
- url: '/knowledge/v1/vector_stores/{vector_store_id}/file_batches',
6573
+ url: '/cut/v1/projects/{project_id}:execute',
6414
6574
  ...options,
6415
6575
  headers: {
6416
6576
  'Content-Type': 'application/json',
@@ -6418,203 +6578,271 @@ export const knowledgeCreateFileBatch = (options) => (options.client ?? client).
6418
6578
  }
6419
6579
  });
6420
6580
  /**
6421
- * Retrieve file batch
6581
+ * Read editing state
6422
6582
  *
6423
- * Retrieves a batch created in this knowledge base, including current status and file counts. Use the batch id returned by batch creation to monitor ingestion.
6583
+ * Read lightweight project context before composing an execute script. Returns current revision, rendering settings, track counts, library bindings and offline media count without individual clips. For complete clip documents or a selected time range, read timeline instead.
6424
6584
  */
6425
- export const knowledgeRetrieveFileBatch = (options) => (options.client ?? client).get({
6585
+ export const cutRetrieveState = (options) => (options.client ?? client).get({
6426
6586
  security: [{
6427
- key: 'knowledge-bearerAuth',
6587
+ key: 'BearerAuth',
6428
6588
  scheme: 'bearer',
6429
6589
  type: 'http'
6590
+ }, {
6591
+ key: 'ApiKeyAuth',
6592
+ name: 'X-API-Key',
6593
+ type: 'apiKey'
6430
6594
  }],
6431
- url: '/knowledge/v1/vector_stores/{vector_store_id}/file_batches/{batch_id}',
6595
+ url: '/cut/v1/projects/{project_id}/state',
6432
6596
  ...options
6433
6597
  });
6434
6598
  /**
6435
- * Cancel file batch
6599
+ * Read project timeline
6436
6600
  *
6437
- * Cancels only in-progress batches and pending files. Completed, failed and cancelled batches return unchanged (200, idempotent).
6601
+ * Inspect clips and markers in a selected project range before editing. view=full returns structured tracks with all timeline positions in seconds; view=compact returns compact text for script context. from and to are seconds and tracks limits the selection to comma-separated track ids from state. Concurrent changes while preparing a full timeline return 409; retrieve the latest state and try the read again.
6438
6602
  */
6439
- export const knowledgeCancelFileBatch = (options) => (options.client ?? client).post({
6603
+ export const cutRetrieveTimeline = (options) => (options.client ?? client).get({
6440
6604
  security: [{
6441
- key: 'knowledge-bearerAuth',
6605
+ key: 'BearerAuth',
6442
6606
  scheme: 'bearer',
6443
6607
  type: 'http'
6608
+ }, {
6609
+ key: 'ApiKeyAuth',
6610
+ name: 'X-API-Key',
6611
+ type: 'apiKey'
6444
6612
  }],
6445
- url: '/knowledge/v1/vector_stores/{vector_store_id}/file_batches/{batch_id}/cancel',
6613
+ url: '/cut/v1/projects/{project_id}/timeline',
6446
6614
  ...options
6447
6615
  });
6448
6616
  /**
6449
- * List batch files
6617
+ * Render preview frames
6450
6618
  *
6451
- * Lists files still attached from the identified batch, newest attachment first by default. Use the batch creation id and ?filter=failed to inspect failures; last_id is the next after cursor.
6619
+ * Review the visual result at one or more project times without creating an export. Pass comma-separated seconds in at, such as 12,15.5; scale changes preview size and revision selects a committed project revision. Request at most eight times. Each returned url is an inline PNG data URL (data:image/png;base64,...), not a hosted HTTP image link. The default scale is 0.25; use 0.5 for subtitle layout inspection (1080×1920 renders at 540×960). The maximum is 0.5; values above it return INVALID_PARAMS. Actual width and height are returned per frame. PNGs above 2 MiB or responses above 4 MiB return RESPONSE_TOO_LARGE without silently lowering resolution. The response always includes warnings; FRAME_UNAVAILABLE means a source preview could not be obtained and an offline tile was drawn. Its message identifies a timeout, delivery capacity limit, or unavailable source and contains no source URL. Decode each image's base64 payload to save it. Codemode returns at most four images per call, so request at most four times when reviewing there.
6452
6620
  */
6453
- export const knowledgeListBatchFiles = (options) => (options.client ?? client).get({
6621
+ export const cutListFrames = (options) => (options.client ?? client).get({
6454
6622
  security: [{
6455
- key: 'knowledge-bearerAuth',
6623
+ key: 'BearerAuth',
6456
6624
  scheme: 'bearer',
6457
6625
  type: 'http'
6626
+ }, {
6627
+ key: 'ApiKeyAuth',
6628
+ name: 'X-API-Key',
6629
+ type: 'apiKey'
6458
6630
  }],
6459
- url: '/knowledge/v1/vector_stores/{vector_store_id}/file_batches/{batch_id}/files',
6631
+ url: '/cut/v1/projects/{project_id}/frames',
6460
6632
  ...options
6461
6633
  });
6462
6634
  /**
6463
- * Restore knowledge base
6635
+ * Analyze project media
6464
6636
  *
6465
- * Restores a deleting store within 7 days. Active stores return 409 VECTOR_STORE_INVALID_STATE; absent stores return 404. Empty body is allowed.
6637
+ * Request silence, filler-word or scene analysis for selected bound assets before editing. Omit media to select project sources; ranges returned in segments use source seconds. A pending result is not completion: use retry_after_sec before checking again, and inspect failed or unsupported asset results before deciding which edits are possible. Silence measures transcript-based speech pauses, not music or loudness. A completed transcript without words returns ready with empty segments and reason no_speech; no completed transcript returns unsupported with reason no_transcript. A failed transcription remains failed.
6466
6638
  */
6467
- export const knowledgeRestoreVectorStore = (options) => (options.client ?? client).post({
6639
+ export const cutCreateAnalysis = (options) => (options.client ?? client).post({
6468
6640
  security: [{
6469
- key: 'knowledge-bearerAuth',
6641
+ key: 'BearerAuth',
6470
6642
  scheme: 'bearer',
6471
6643
  type: 'http'
6644
+ }, {
6645
+ key: 'ApiKeyAuth',
6646
+ name: 'X-API-Key',
6647
+ type: 'apiKey'
6472
6648
  }],
6473
- url: '/knowledge/v1/vector_stores/{vector_store_id}/restore',
6474
- ...options
6649
+ url: '/cut/v1/projects/{project_id}/analysis',
6650
+ ...options,
6651
+ headers: {
6652
+ 'Content-Type': 'application/json',
6653
+ ...options.headers
6654
+ }
6475
6655
  });
6476
6656
  /**
6477
- * Permanently purge knowledge base
6657
+ * List library bindings
6478
6658
  *
6479
- * Immediately and irreversibly clears a deleting store using the retention cleanup path. Active stores return 409; absent stores return 404. Empty body is allowed.
6659
+ * Discover the named media libraries available to this project before selecting source assets or an import/export destination. read bindings supply source assets; read_write bindings also accept uploads. Exactly one writable binding supplies the default upload destination.
6480
6660
  */
6481
- export const knowledgePurgeVectorStore = (options) => (options.client ?? client).post({
6661
+ export const cutListBindings = (options) => (options.client ?? client).get({
6482
6662
  security: [{
6483
- key: 'knowledge-bearerAuth',
6663
+ key: 'BearerAuth',
6484
6664
  scheme: 'bearer',
6485
6665
  type: 'http'
6666
+ }, {
6667
+ key: 'ApiKeyAuth',
6668
+ name: 'X-API-Key',
6669
+ type: 'apiKey'
6486
6670
  }],
6487
- url: '/knowledge/v1/vector_stores/{vector_store_id}/purge',
6671
+ url: '/cut/v1/projects/{project_id}/bindings',
6488
6672
  ...options
6489
6673
  });
6490
6674
  /**
6491
- * Retry failed file
6675
+ * Bind media library
6492
6676
  *
6493
- * Retries only failed files; other states return 409 FILE_INVALID_STATE. Retry after failure has not yet been observed in the documented run.
6677
+ * Attach an accessible media library to an existing project under a unique name. Obtain library_id from praxis.media and choose read for source-only access or read_write for imports and exports. The project must retain exactly one read_write binding with default_upload true after the change.
6494
6678
  */
6495
- export const knowledgeRetryFile = (options) => (options.client ?? client).post({
6679
+ export const cutCreateBinding = (options) => (options.client ?? client).post({
6496
6680
  security: [{
6497
- key: 'knowledge-bearerAuth',
6681
+ key: 'BearerAuth',
6498
6682
  scheme: 'bearer',
6499
6683
  type: 'http'
6684
+ }, {
6685
+ key: 'ApiKeyAuth',
6686
+ name: 'X-API-Key',
6687
+ type: 'apiKey'
6500
6688
  }],
6501
- url: '/knowledge/v1/vector_stores/{vector_store_id}/files/{file_id}/retry',
6502
- ...options
6689
+ url: '/cut/v1/projects/{project_id}/bindings',
6690
+ ...options,
6691
+ headers: {
6692
+ 'Content-Type': 'application/json',
6693
+ ...options.headers
6694
+ }
6503
6695
  });
6504
6696
  /**
6505
- * List file segments
6697
+ * Remove library binding
6506
6698
  *
6507
- * Lists the stored chunks of an attached file, ordered by increasing segment index by default. Use the attachment id and last_id as after to continue; returned chunk ids can be retrieved individually.
6699
+ * Detach a library alias obtained from bindings.list after removing all timeline clips that reference its library. BINDING_IN_USE returns 409 while references remain; inspect timeline and edit those clips first. Removal must preserve the one writable default upload binding.
6508
6700
  */
6509
- export const knowledgeListSegments = (options) => (options.client ?? client).get({
6701
+ export const cutDeleteBinding = (options) => (options.client ?? client).delete({
6510
6702
  security: [{
6511
- key: 'knowledge-bearerAuth',
6703
+ key: 'BearerAuth',
6512
6704
  scheme: 'bearer',
6513
6705
  type: 'http'
6706
+ }, {
6707
+ key: 'ApiKeyAuth',
6708
+ name: 'X-API-Key',
6709
+ type: 'apiKey'
6514
6710
  }],
6515
- url: '/knowledge/v1/vector_stores/{vector_store_id}/files/{file_id}/segments',
6711
+ url: '/cut/v1/projects/{project_id}/bindings/{name}',
6516
6712
  ...options
6517
6713
  });
6518
6714
  /**
6519
- * Retrieve segment
6715
+ * Import project media
6520
6716
  *
6521
- * Retrieves one chunk and its term statistics. Take chunk_id from segment listing or native search content; the chunk must belong to this knowledge base.
6717
+ * Import a URL, data URI or existing file into a writable project media library. Select binding from bindings.list or omit it to use default_upload. Save library_id and asset_id from the result and use them as libraryId and assetId inside execute script media references; overwrites follow the source asset latest version.
6522
6718
  */
6523
- export const knowledgeRetrieveSegment = (options) => (options.client ?? client).get({
6719
+ export const cutImportMedia = (options) => (options.client ?? client).post({
6524
6720
  security: [{
6525
- key: 'knowledge-bearerAuth',
6721
+ key: 'BearerAuth',
6526
6722
  scheme: 'bearer',
6527
6723
  type: 'http'
6724
+ }, {
6725
+ key: 'ApiKeyAuth',
6726
+ name: 'X-API-Key',
6727
+ type: 'apiKey'
6528
6728
  }],
6529
- url: '/knowledge/v1/vector_stores/{vector_store_id}/segments/{chunk_id}',
6530
- ...options
6729
+ url: '/cut/v1/projects/{project_id}/media:import',
6730
+ ...options,
6731
+ headers: {
6732
+ 'Content-Type': 'application/json',
6733
+ ...options.headers
6734
+ }
6531
6735
  });
6532
6736
  /**
6533
- * List events
6737
+ * List project exports
6534
6738
  *
6535
- * Reads events for this knowledge base in increasing sequence order, including while soft-deleted. Pass next_seq as after_seq to continue; null next_seq marks the current end. Example: ?after_seq=0&limit=20.
6739
+ * Find export jobs associated with this project before polling or canceling a render. Copy an export id into praxis.cut.exports.retrieve or cancel. Continue with next_page_token as page_token when present; queued or in-progress jobs have not produced a final media asset.
6536
6740
  */
6537
- export const knowledgeListEvents = (options) => (options.client ?? client).get({
6741
+ export const cutListExports = (options) => (options.client ?? client).get({
6538
6742
  security: [{
6539
- key: 'knowledge-bearerAuth',
6743
+ key: 'BearerAuth',
6540
6744
  scheme: 'bearer',
6541
6745
  type: 'http'
6746
+ }, {
6747
+ key: 'ApiKeyAuth',
6748
+ name: 'X-API-Key',
6749
+ type: 'apiKey'
6542
6750
  }],
6543
- url: '/knowledge/v1/vector_stores/{vector_store_id}/events',
6751
+ url: '/cut/v1/projects/{project_id}/exports',
6544
6752
  ...options
6545
6753
  });
6546
6754
  /**
6547
- * List libraries
6755
+ * Create video export
6548
6756
  *
6549
- * List libraries owned by the caller, newest first. By default, deleting and deleted libraries are excluded; use status=deleting to find libraries awaiting purge. All supplied label pairs must match.
6757
+ * Start an asynchronous video export from the project into a writable bound media library. Choose binding from bindings.list or omit it for default_upload, and optionally select revision and output settings. HTTP 202 only accepts the job; poll praxis.cut.exports.retrieve using the returned id until status is done, failed or canceled. On done, asset identifies the video written back to praxis.media. Each call starts a job, so retrieve a known job before retrying a submission.
6550
6758
  */
6551
- export const mediaListLibraries = (options) => (options?.client ?? client).get({
6759
+ export const cutCreateExport = (options) => (options.client ?? client).post({
6552
6760
  security: [{
6553
- key: 'media-BearerAuth',
6761
+ key: 'BearerAuth',
6554
6762
  scheme: 'bearer',
6555
6763
  type: 'http'
6764
+ }, {
6765
+ key: 'ApiKeyAuth',
6766
+ name: 'X-API-Key',
6767
+ type: 'apiKey'
6556
6768
  }],
6557
- url: '/media/v1/libraries',
6558
- ...options
6769
+ url: '/cut/v1/projects/{project_id}/exports',
6770
+ ...options,
6771
+ headers: {
6772
+ 'Content-Type': 'application/json',
6773
+ ...options.headers
6774
+ }
6559
6775
  });
6560
6776
  /**
6561
- * Create library
6777
+ * Retrieve video export
6562
6778
  *
6563
- * Create a library owned by the caller with a name, optional labels and understanding settings. Understanding is enabled by default; the returned id is used for subsequent asset operations.
6779
+ * Poll an export id returned by projects.exports.create or list to observe render progress. queued, fetching, rendering, stitching and saving are in progress; done provides asset in the target library, failed provides error, and canceled means the job stopped. Only done confirms a usable output asset.
6564
6780
  */
6565
- export const mediaCreateLibrary = (options) => (options.client ?? client).post({
6781
+ export const cutRetrieveExport = (options) => (options.client ?? client).get({
6566
6782
  security: [{
6567
- key: 'media-BearerAuth',
6783
+ key: 'BearerAuth',
6568
6784
  scheme: 'bearer',
6569
6785
  type: 'http'
6786
+ }, {
6787
+ key: 'ApiKeyAuth',
6788
+ name: 'X-API-Key',
6789
+ type: 'apiKey'
6570
6790
  }],
6571
- url: '/media/v1/libraries',
6572
- ...options,
6573
- headers: {
6574
- 'Content-Type': 'application/json',
6575
- ...options.headers
6576
- }
6791
+ url: '/cut/v1/exports/{export_id}',
6792
+ ...options
6577
6793
  });
6578
6794
  /**
6579
- * Delete library
6795
+ * Cancel video export
6580
6796
  *
6581
- * Soft-delete an active library, returning its deleting status and purge_at deadline. Asset operations and delivery become unavailable; the library can be restored before purge_at. Repeated deletion while deleting returns the current library.
6797
+ * Request cancellation of an export obtained from projects.exports.create or list when its output is no longer needed. Read the returned job status and retrieve it to confirm the terminal outcome; do not interpret a cancellation request as successful rendering.
6582
6798
  */
6583
- export const mediaDeleteLibrary = (options) => (options.client ?? client).delete({
6799
+ export const cutCancelExport = (options) => (options.client ?? client).post({
6584
6800
  security: [{
6585
- key: 'media-BearerAuth',
6801
+ key: 'BearerAuth',
6586
6802
  scheme: 'bearer',
6587
6803
  type: 'http'
6804
+ }, {
6805
+ key: 'ApiKeyAuth',
6806
+ name: 'X-API-Key',
6807
+ type: 'apiKey'
6588
6808
  }],
6589
- url: '/media/v1/libraries/{library_id}',
6809
+ url: '/cut/v1/exports/{export_id}:cancel',
6590
6810
  ...options
6591
6811
  });
6592
6812
  /**
6593
- * Get library
6813
+ * List saved versions
6594
6814
  *
6595
- * Read a caller-owned library’s current settings, usage and lifecycle status. A deleting library remains readable; missing, foreign or purged libraries return LIBRARY_NOT_FOUND.
6815
+ * Find saved timeline snapshots for this project and obtain version_id values for restore. A saved version records its original revision; restoring it creates a new current revision rather than rewinding the revision counter. Continue with next_page_token as page_token until absent.
6596
6816
  */
6597
- export const mediaGetLibrary = (options) => (options.client ?? client).get({
6817
+ export const cutListVersions = (options) => (options.client ?? client).get({
6598
6818
  security: [{
6599
- key: 'media-BearerAuth',
6819
+ key: 'BearerAuth',
6600
6820
  scheme: 'bearer',
6601
6821
  type: 'http'
6822
+ }, {
6823
+ key: 'ApiKeyAuth',
6824
+ name: 'X-API-Key',
6825
+ type: 'apiKey'
6602
6826
  }],
6603
- url: '/media/v1/libraries/{library_id}',
6827
+ url: '/cut/v1/projects/{project_id}/versions',
6604
6828
  ...options
6605
6829
  });
6606
6830
  /**
6607
- * Update library
6831
+ * Save project version
6608
6832
  *
6609
- * Update an active library’s supplied settings. Labels replace the complete map; understanding settings and model roles merge with current values. Changing the embedding model is rejected while assets exist.
6833
+ * Save the current project timeline as a named recovery point before a substantial edit. Supply an optional label or send an empty object; keep the returned version id for versions.restore. Saving a version does not publish a rendered asset; use projects.exports.create for video output.
6610
6834
  */
6611
- export const mediaUpdateLibrary = (options) => (options.client ?? client).patch({
6835
+ export const cutCreateVersion = (options) => (options.client ?? client).post({
6612
6836
  security: [{
6613
- key: 'media-BearerAuth',
6837
+ key: 'BearerAuth',
6614
6838
  scheme: 'bearer',
6615
6839
  type: 'http'
6840
+ }, {
6841
+ key: 'ApiKeyAuth',
6842
+ name: 'X-API-Key',
6843
+ type: 'apiKey'
6616
6844
  }],
6617
- url: '/media/v1/libraries/{library_id}',
6845
+ url: '/cut/v1/projects/{project_id}/versions',
6618
6846
  ...options,
6619
6847
  headers: {
6620
6848
  'Content-Type': 'application/json',
@@ -6622,77 +6850,95 @@ export const mediaUpdateLibrary = (options) => (options.client ?? client).patch(
6622
6850
  }
6623
6851
  });
6624
6852
  /**
6625
- * Restore library
6853
+ * Restore saved version
6626
6854
  *
6627
- * Restore a deleting library before its purge_at deadline. The library becomes active again and deleted_at and purge_at are cleared; expired or non-deleting libraries cannot be restored.
6855
+ * Replace current editing content with a saved project snapshot selected from projects.versions.list. The restore commits a new transaction and revision while preserving the saved version for future use. Inspect the returned summary and timeline before further editing; a response revision conflict can follow a committed restore, so retrieve current state before retrying.
6628
6856
  */
6629
- export const mediaRestoreLibrary = (options) => (options.client ?? client).post({
6857
+ export const cutRestoreVersion = (options) => (options.client ?? client).post({
6630
6858
  security: [{
6631
- key: 'media-BearerAuth',
6859
+ key: 'BearerAuth',
6632
6860
  scheme: 'bearer',
6633
6861
  type: 'http'
6862
+ }, {
6863
+ key: 'ApiKeyAuth',
6864
+ name: 'X-API-Key',
6865
+ type: 'apiKey'
6634
6866
  }],
6635
- url: '/media/v1/libraries/{library_id}/restore',
6867
+ url: '/cut/v1/versions/{version_id}:restore',
6636
6868
  ...options
6637
6869
  });
6638
6870
  /**
6639
- * Purge library
6871
+ * List databases
6640
6872
  *
6641
- * Permanently remove a library that is already deleting, without waiting for purge_at. Its assets and related resources are removed and cannot be restored; first soft-delete an active library.
6873
+ * Find databases owned by your tenant and obtain their ids for schema or row operations. Excludes deleting by default. status=active or status=deleting selects that state; invalid values return 400 INVALID_PARAMS.
6642
6874
  */
6643
- export const mediaPurgeLibrary = (options) => (options.client ?? client).post({
6875
+ export const databaseListDatabases = (options) => (options?.client ?? client).get({
6644
6876
  security: [{
6645
- key: 'media-BearerAuth',
6877
+ key: 'database-bearerAuth',
6646
6878
  scheme: 'bearer',
6647
6879
  type: 'http'
6648
6880
  }],
6649
- url: '/media/v1/libraries/{library_id}/purge',
6881
+ url: '/database/v1/databases',
6650
6882
  ...options
6651
6883
  });
6652
6884
  /**
6653
- * List assets
6885
+ * Create database
6654
6886
  *
6655
- * List assets in an active library, newest first, optionally filtering by exact folder and stored resource type. Continue using next_cursor; video includes audio-only assets.
6887
+ * Creates an empty database for the caller and returns it with status active (HTTP 201); add tables next with praxis.database.databases.tables.create. name is required and is 1–64 visible characters after trimming. labels are optional string tags (at most 64; each key starts with a lowercase letter and uses up to 63 characters of a-z 0-9 _ -; each value is up to 63 characters of a-z 0-9 _ -) that databaseListDatabases can filter on. If initialization fails the call returns 503 CAPACITY and the half-created database is left with status failed; retry by calling create again, which makes a new database. Unlike Supabase, this creates a SQLite-backed database without a PostgreSQL connection or SQL execution endpoint. Use a Praxis credential; access is scoped to its tenant, not to Supabase Auth users or RLS policies.
6656
6888
  */
6657
- export const mediaListAssets = (options) => (options.client ?? client).get({
6889
+ export const databaseCreateDatabase = (options) => (options.client ?? client).post({
6658
6890
  security: [{
6659
- key: 'media-BearerAuth',
6891
+ key: 'database-bearerAuth',
6660
6892
  scheme: 'bearer',
6661
6893
  type: 'http'
6662
6894
  }],
6663
- url: '/media/v1/libraries/{library_id}/assets',
6895
+ url: '/database/v1/databases',
6896
+ ...options,
6897
+ headers: {
6898
+ 'Content-Type': 'application/json',
6899
+ ...options.headers
6900
+ }
6901
+ });
6902
+ /**
6903
+ * Delete database
6904
+ *
6905
+ * Soft-delete a database when it should stop accepting schema and row operations. Idempotently enters deleting with a seven-day purge_at. GET remains available; child operations return 409 until restored.
6906
+ */
6907
+ export const databaseDeleteDatabase = (options) => (options.client ?? client).delete({
6908
+ security: [{
6909
+ key: 'database-bearerAuth',
6910
+ scheme: 'bearer',
6911
+ type: 'http'
6912
+ }],
6913
+ url: '/database/v1/databases/{database_id}',
6664
6914
  ...options
6665
6915
  });
6666
6916
  /**
6667
- * Upload asset
6917
+ * Get database
6668
6918
  *
6669
- * Upload content into an active library and return a Cloudinary-compatible resource. Use file for a multipart file, data URI, public HTTPS URL or same-owner file identifier. Reusing public_id overwrites by default; overwrite=false returns the existing resource. Chunk uploads require both chunk headers.
6919
+ * Returns one database by id, including a database in the deleting state (purge_at then shows when it will be permanently removed). Call it before table or row operations to confirm status is active: schema and row calls on a deleting database return 409 DATABASE_INVALID_STATE. size_bytes is refreshed from live storage at most once every five seconds. A purged or unknown id returns 404 DATABASE_NOT_FOUND.
6670
6920
  */
6671
- export const mediaUploadAsset = (options) => (options.client ?? client).post({
6921
+ export const databaseGetDatabase = (options) => (options.client ?? client).get({
6672
6922
  security: [{
6673
- key: 'media-BearerAuth',
6923
+ key: 'database-bearerAuth',
6674
6924
  scheme: 'bearer',
6675
6925
  type: 'http'
6676
6926
  }],
6677
- url: '/media/v1/libraries/{library_id}/assets',
6678
- ...options,
6679
- headers: {
6680
- 'Content-Type': 'application/json',
6681
- ...options.headers
6682
- }
6927
+ url: '/database/v1/databases/{database_id}',
6928
+ ...options
6683
6929
  });
6684
6930
  /**
6685
- * Import file
6931
+ * Update database
6686
6932
  *
6687
- * Copy source content into an active library using upload options and return the full native Asset. The imported asset is independent of the source after copying. Reusing public_id follows overwrite semantics.
6933
+ * Renames an active database and/or replaces its labels; send only the keys you want to change. labels is replaced as a whole, not merged, so include every label you want to keep. A body without name or labels, or with values equal to the current ones, changes nothing and leaves updated_at as is. A database in the deleting state returns 409 DATABASE_INVALID_STATE; restore it first with databaseRestoreDatabase.
6688
6934
  */
6689
- export const mediaImportAsset = (options) => (options.client ?? client).post({
6935
+ export const databaseUpdateDatabase = (options) => (options.client ?? client).patch({
6690
6936
  security: [{
6691
- key: 'media-BearerAuth',
6937
+ key: 'database-bearerAuth',
6692
6938
  scheme: 'bearer',
6693
6939
  type: 'http'
6694
6940
  }],
6695
- url: '/media/v1/libraries/{library_id}/assets/import',
6941
+ url: '/database/v1/databases/{database_id}',
6696
6942
  ...options,
6697
6943
  headers: {
6698
6944
  'Content-Type': 'application/json',
@@ -6700,63 +6946,59 @@ export const mediaImportAsset = (options) => (options.client ?? client).post({
6700
6946
  }
6701
6947
  });
6702
6948
  /**
6703
- * Delete asset
6949
+ * Restore database
6704
6950
  *
6705
- * Delete an asset from the library so it is no longer readable, searchable or deliverable. This removes the asset rather than placing it in the library’s restoration window; a missing asset returns ASSET_NOT_FOUND.
6951
+ * Recover a soft-deleted database within its seven-day recovery window. Restore before purge_at. An empty body is accepted. Active databases return 409; purged databases return 404.
6706
6952
  */
6707
- export const mediaDeleteAsset = (options) => (options.client ?? client).delete({
6953
+ export const databaseRestoreDatabase = (options) => (options.client ?? client).post({
6708
6954
  security: [{
6709
- key: 'media-BearerAuth',
6955
+ key: 'database-bearerAuth',
6710
6956
  scheme: 'bearer',
6711
6957
  type: 'http'
6712
6958
  }],
6713
- url: '/media/v1/libraries/{library_id}/assets/{asset_id}',
6959
+ url: '/database/v1/databases/{database_id}/restore',
6714
6960
  ...options
6715
6961
  });
6716
6962
  /**
6717
- * Get asset
6963
+ * Permanently purge database
6718
6964
  *
6719
- * Read a non-deleted asset by its asset_id in an active library, including content hashes, processing progress and available previews. Missing or deleted assets return ASSET_NOT_FOUND.
6965
+ * Immediately and irreversibly purges a deleting database. Active databases return 409; absent or already purged databases return 404.
6720
6966
  */
6721
- export const mediaGetAsset = (options) => (options.client ?? client).get({
6967
+ export const databasePurgeDatabase = (options) => (options.client ?? client).post({
6722
6968
  security: [{
6723
- key: 'media-BearerAuth',
6969
+ key: 'database-bearerAuth',
6724
6970
  scheme: 'bearer',
6725
6971
  type: 'http'
6726
6972
  }],
6727
- url: '/media/v1/libraries/{library_id}/assets/{asset_id}',
6973
+ url: '/database/v1/databases/{database_id}/purge',
6728
6974
  ...options
6729
6975
  });
6730
6976
  /**
6731
- * Update asset
6977
+ * List tables
6732
6978
  *
6733
- * Update an asset’s supplied metadata fields. Tags and context replace their current collections; an empty collection clears them. Moving asset_folder or changing display_name preserves public_id and delivery URLs.
6979
+ * Lists every table of an active database with its field definitions. A database holds at most 50 tables, so the single page contains all of them and next_cursor is always null. Use databaseGetTable instead when you also need row_count for one table.
6734
6980
  */
6735
- export const mediaUpdateAsset = (options) => (options.client ?? client).patch({
6981
+ export const databaseListTables = (options) => (options.client ?? client).get({
6736
6982
  security: [{
6737
- key: 'media-BearerAuth',
6983
+ key: 'database-bearerAuth',
6738
6984
  scheme: 'bearer',
6739
6985
  type: 'http'
6740
6986
  }],
6741
- url: '/media/v1/libraries/{library_id}/assets/{asset_id}',
6742
- ...options,
6743
- headers: {
6744
- 'Content-Type': 'application/json',
6745
- ...options.headers
6746
- }
6987
+ url: '/database/v1/databases/{database_id}/tables',
6988
+ ...options
6747
6989
  });
6748
6990
  /**
6749
- * Reprocess asset
6991
+ * Create table
6750
6992
  *
6751
- * Queue reprocessing of the asset’s current version and return its updated state immediately. Omit kinds to retry failed tasks; explicit kinds rerun applicable completed tasks. Replaced understandings become superseded, and processing finishes asynchronously.
6993
+ * Creates a table together with its initial fields in one call and returns it (HTTP 201) with generated tbl_ and fld_ ids. name must match ^[a-z_][a-z0-9_]{0,62}$ and be unused in this database (duplicate: 409 UNIQUE_VIOLATION). fields is required and may be an empty array; fields can also be added later with databaseAddField. Limits: 50 tables per database, 64 fields per table, and 16 indexed or unique fields per table; exceeding one returns 400 LIMIT_EXCEEDED. Fields default to indexed:false. Set indexed:true explicitly for fields used in filters or ordering. Only indexed:true or unique:true consumes one of the 16 indexed-or-unique field slots; a field with both consumes one slot. Unique fields still consume a slot even with indexed:false. Existing fields are unchanged. Minimal field example: {"name":"notes","type":"string","indexed":false}. Every row also has a system id column, which is not declared as a field. Insert data afterwards with databaseInsert. Unlike Supabase, define schema with this table API and the field APIs; PostgreSQL DDL and SQL migration files cannot be submitted. Each table supports up to 1,000,000 rows.
6752
6994
  */
6753
- export const mediaReprocessAsset = (options) => (options.client ?? client).post({
6995
+ export const databaseCreateTable = (options) => (options.client ?? client).post({
6754
6996
  security: [{
6755
- key: 'media-BearerAuth',
6997
+ key: 'database-bearerAuth',
6756
6998
  scheme: 'bearer',
6757
6999
  type: 'http'
6758
7000
  }],
6759
- url: '/media/v1/libraries/{library_id}/assets/{asset_id}/reprocess',
7001
+ url: '/database/v1/databases/{database_id}/tables',
6760
7002
  ...options,
6761
7003
  headers: {
6762
7004
  'Content-Type': 'application/json',
@@ -6764,49 +7006,45 @@ export const mediaReprocessAsset = (options) => (options.client ?? client).post(
6764
7006
  }
6765
7007
  });
6766
7008
  /**
6767
- * List understandings
7009
+ * Delete table
6768
7010
  *
6769
- * List an asset’s understanding results in creation order. By default only current, non-superseded results are returned; use include_superseded=true for history or kind to select an output type.
7011
+ * Permanently drops a table with all of its rows; the deletion is immediate and has no recovery window or undo. Refused with 409 REFERENCE_RESTRICT while a link field of another table points at this table, so delete or change those fields first. Returns {deleted: true}. A table name can be reused afterwards.
6770
7012
  */
6771
- export const mediaListUnderstandings = (options) => (options.client ?? client).get({
7013
+ export const databaseDeleteTable = (options) => (options.client ?? client).delete({
6772
7014
  security: [{
6773
- key: 'media-BearerAuth',
7015
+ key: 'database-bearerAuth',
6774
7016
  scheme: 'bearer',
6775
7017
  type: 'http'
6776
7018
  }],
6777
- url: '/media/v1/libraries/{library_id}/assets/{asset_id}/understandings',
7019
+ url: '/database/v1/databases/{database_id}/tables/{table}',
6778
7020
  ...options
6779
7021
  });
6780
7022
  /**
6781
- * Expression search
7023
+ * Get table
6782
7024
  *
6783
- * Search active assets using the supported filter-expression syntax, sorting and cursor pagination. Empty expression matches all assets. Tags and context require with_field; inspect the exactness flags before treating counts as complete.
7025
+ * Returns one table by id or name with its field definitions, schema_revision and row_count. row_count is only returned by this operation, not by list or create. Use field ids from this response for stable references because field names can be renamed; an unknown table returns 404 TABLE_NOT_FOUND.
6784
7026
  */
6785
- export const mediaExpressionSearch = (options) => (options.client ?? client).post({
7027
+ export const databaseGetTable = (options) => (options.client ?? client).get({
6786
7028
  security: [{
6787
- key: 'media-BearerAuth',
7029
+ key: 'database-bearerAuth',
6788
7030
  scheme: 'bearer',
6789
7031
  type: 'http'
6790
7032
  }],
6791
- url: '/media/v1/libraries/{library_id}/search/expression',
6792
- ...options,
6793
- headers: {
6794
- 'Content-Type': 'application/json',
6795
- ...options.headers
6796
- }
7033
+ url: '/database/v1/databases/{database_id}/tables/{table}',
7034
+ ...options
6797
7035
  });
6798
7036
  /**
6799
- * Visual search
7037
+ * Update table
6800
7038
  *
6801
- * Find visually similar assets using exactly one of asset_id or an inline base64 image. The library must support image search; an asset query needs a current image embedding and excludes that source asset from results.
7039
+ * Renames a table and/or changes its description; send only the keys to change, and send description null to clear it. The new name must follow ^[a-z_][a-z0-9_]{0,62}$ and be unused (409 UNIQUE_VIOLATION); ids are stable, so renaming never rewrites row data. A body with no changes or values equal to the current ones does not bump schema_revision. Fields cannot be changed here; use databaseAddField, databaseUpdateField and databaseDeleteField.
6802
7040
  */
6803
- export const mediaVisualSearch = (options) => (options.client ?? client).post({
7041
+ export const databaseUpdateTable = (options) => (options.client ?? client).patch({
6804
7042
  security: [{
6805
- key: 'media-BearerAuth',
7043
+ key: 'database-bearerAuth',
6806
7044
  scheme: 'bearer',
6807
7045
  type: 'http'
6808
7046
  }],
6809
- url: '/media/v1/libraries/{library_id}/search/visual',
7047
+ url: '/database/v1/databases/{database_id}/tables/{table}',
6810
7048
  ...options,
6811
7049
  headers: {
6812
7050
  'Content-Type': 'application/json',
@@ -6814,17 +7052,17 @@ export const mediaVisualSearch = (options) => (options.client ?? client).post({
6814
7052
  }
6815
7053
  });
6816
7054
  /**
6817
- * Semantic search
7055
+ * Add field
6818
7056
  *
6819
- * Search assets with a nonblank text query and optional expression filter. Hybrid mode combines semantic and keyword matches; semantic mode uses vector similarity only. Results are ranked and limited by top_k.
7057
+ * Adds one field to an existing table and returns the updated table (HTTP 201). Required inputs are name (lowercase letters, digits and underscores; id and names starting with _ are reserved) and type (string, integer, number, boolean, datetime, json or link); json needs options.schema and link needs options.linked_table_id and options.multiple. Adding a required field to a table that already has rows needs a default, otherwise the call fails with 400 VALIDATION_FAILED; a default is written into every existing row. Fields default to indexed:false. Set indexed:true explicitly for fields used in filters or ordering. Only indexed:true or unique:true consumes one of the 16 indexed-or-unique field slots; a field with both consumes one slot. Unique fields still consume a slot even with indexed:false. Existing fields are unchanged. Minimal field example: {"name":"notes","type":"string","indexed":false}. JSON and link fields cannot be indexed. Limits: 64 fields and 16 indexed or unique fields per table (400 LIMIT_EXCEEDED). Unlike Supabase, schema evolution uses field definitions rather than ALTER TABLE statements or SQL migrations.
6820
7058
  */
6821
- export const mediaSemanticSearch = (options) => (options.client ?? client).post({
7059
+ export const databaseAddField = (options) => (options.client ?? client).post({
6822
7060
  security: [{
6823
- key: 'media-BearerAuth',
7061
+ key: 'database-bearerAuth',
6824
7062
  scheme: 'bearer',
6825
7063
  type: 'http'
6826
7064
  }],
6827
- url: '/media/v1/libraries/{library_id}/search/semantic',
7065
+ url: '/database/v1/databases/{database_id}/tables/{table}/fields',
6828
7066
  ...options,
6829
7067
  headers: {
6830
7068
  'Content-Type': 'application/json',
@@ -6832,17 +7070,31 @@ export const mediaSemanticSearch = (options) => (options.client ?? client).post(
6832
7070
  }
6833
7071
  });
6834
7072
  /**
6835
- * Semantic search alias
7073
+ * Delete field
6836
7074
  *
6837
- * Alias of semantic search. Search assets with a nonblank text query, optional expression filter and top_k; hybrid combines semantic and keyword matches, while semantic uses vector similarity only.
7075
+ * Deletes one field definition from a table and returns the updated table; the deletion is immediate and has no recovery window. Look the field up by id or name. The field's index, if any, is dropped with it, and the name can be reused afterwards. Unknown fields return 400 FIELD_NOT_FOUND.
6838
7076
  */
6839
- export const mediaSearch = (options) => (options.client ?? client).post({
7077
+ export const databaseDeleteField = (options) => (options.client ?? client).delete({
6840
7078
  security: [{
6841
- key: 'media-BearerAuth',
7079
+ key: 'database-bearerAuth',
6842
7080
  scheme: 'bearer',
6843
7081
  type: 'http'
6844
7082
  }],
6845
- url: '/media/v1/libraries/{library_id}/search',
7083
+ url: '/database/v1/databases/{database_id}/tables/{table}/fields/{field}',
7084
+ ...options
7085
+ });
7086
+ /**
7087
+ * Update field
7088
+ *
7089
+ * Changes a field's name, description, required flag, indexed flag, default or json options.schema and returns the updated table. The field type, a link field's linked_table_id and the unique flag cannot be changed (400 FIELD_TYPE_IMMUTABLE or INVALID_PARAMS). Setting required to true fails with 400 VALIDATION_FAILED while existing rows hold null for the field. A new json schema constrains only later writes; existing rows are not revalidated. Renaming never rewrites row data, and a request that changes nothing does not bump schema_revision. Unlike Supabase, field types and uniqueness cannot be altered through SQL migrations; use the supported field settings described here.
7090
+ */
7091
+ export const databaseUpdateField = (options) => (options.client ?? client).patch({
7092
+ security: [{
7093
+ key: 'database-bearerAuth',
7094
+ scheme: 'bearer',
7095
+ type: 'http'
7096
+ }],
7097
+ url: '/database/v1/databases/{database_id}/tables/{table}/fields/{field}',
6846
7098
  ...options,
6847
7099
  headers: {
6848
7100
  'Content-Type': 'application/json',
@@ -6850,31 +7102,73 @@ export const mediaSearch = (options) => (options.client ?? client).post({
6850
7102
  }
6851
7103
  });
6852
7104
  /**
6853
- * List folders
7105
+ * List events
6854
7106
  *
6855
- * List all immediate child folders under parent, or under the root when parent is omitted. Counts include descendant assets. The result is unpaginated; limit and cursor are rejected.
7107
+ * Read lifecycle and schema events, including while the database is deleting. next_cursor is an opaque string cursor (do not do arithmetic on it): pass it as after_seq for asc or before_seq for desc. Supplying both cursors returns 400 INVALID_PARAMS. Unlike Supabase Realtime, this is paged lifecycle and schema history, not a subscription or a row-change feed; row inserts, updates and deletes do not appear here.
6856
7108
  */
6857
- export const mediaListFolders = (options) => (options.client ?? client).get({
7109
+ export const databaseListEvents = (options) => (options.client ?? client).get({
6858
7110
  security: [{
6859
- key: 'media-BearerAuth',
7111
+ key: 'database-bearerAuth',
6860
7112
  scheme: 'bearer',
6861
7113
  type: 'http'
6862
7114
  }],
6863
- url: '/media/v1/libraries/{library_id}/folders',
7115
+ url: '/database/v1/databases/{database_id}/events',
6864
7116
  ...options
6865
7117
  });
6866
7118
  /**
6867
- * Create batch
7119
+ * Delete rows
6868
7120
  *
6869
- * Create an asynchronous batch for tagging, untagging, replacing context, moving or deleting assets. Select ids or an expression; selection is frozen at creation. Poll the returned job id for completion and per-item failures.
7121
+ * Deletes the rows matched by the filter query parameters (the same filters as databaseSelect); with no filter every row of the table matches. Deletion is immediate and cannot be undone. A row that a link field of another table still references makes the whole call fail with 409 REFERENCE_RESTRICT and nothing is deleted. The default response is 204 with no body; send Prefer: return=representation to get HTTP 200 with the deleted rows.
6870
7122
  */
6871
- export const mediaCreateBatch = (options) => (options.client ?? client).post({
7123
+ export const databaseDelete = (options) => (options.client ?? client).delete({
6872
7124
  security: [{
6873
- key: 'media-BearerAuth',
7125
+ key: 'database-bearerAuth',
6874
7126
  scheme: 'bearer',
6875
7127
  type: 'http'
6876
7128
  }],
6877
- url: '/media/v1/libraries/{library_id}/batches',
7129
+ url: '/database/v1/databases/{database_id}/rest/{table}',
7130
+ ...options
7131
+ });
7132
+ /**
7133
+ * Select rows
7134
+ *
7135
+ * Read matching rows with filters, selected columns and ordering. Returns at most 1000 rows per request, including when limit is omitted. Content-Range reports the actual returned interval and the total when count is requested. PATCH and DELETE are not subject to this read cap. Unlike Supabase, casts, aggregates, spread and join modifiers are unsupported. Each table supports up to 1,000,000 rows. Query budget: 8,000 ms with a shared 3,000,000-row safety ceiling. Create indexes on filtered or sorted fields, or narrow the request when it exceeds its budget. Synchronous SQLite aggregates use candidate-row throughput estimates before execution; deployed Workers freeze clocks during synchronous CPU work, so the timer is not a guaranteed server-side interrupt. Count preferences: without filters, exact, planned and estimated all use SQLite's exact b-tree count. With filters, exact counts within budget; planned skips counting and reports an unknown total (Content-Range: 0-24*); estimated attempts exact counting only when the preflight budget allows it, otherwise reports an unknown total. Preference-Applied echoes the requested count mode. Error table: QUERY_CANCELED / PostgREST 57014 is HTTP 500, retryable=false: Query timed out: index filtered or sorted fields, or narrow the range. DATABASE_INVALID_STATE is HTTP 409 for operations on a deleting database. Cleared or nonexistent databases return DATABASE_NOT_FOUND / HTTP 404. The count is an HTTP Content-Range response header, not a JSON property. Use praxis.database.count in the SDK or codemode to return { count: number | null }; a page length is not a total unless you know all matches fit in that page.
7136
+ */
7137
+ export const databaseSelect = (options) => (options.client ?? client).get({
7138
+ security: [{
7139
+ key: 'database-bearerAuth',
7140
+ scheme: 'bearer',
7141
+ type: 'http'
7142
+ }],
7143
+ url: '/database/v1/databases/{database_id}/rest/{table}',
7144
+ ...options
7145
+ });
7146
+ /**
7147
+ * Count rows
7148
+ *
7149
+ * Inspect the HTTP row count and range without retrieving row data; send Prefer: count=exact for a filtered count. Returns no body and does not fetch or serialize row data. A known count determines the interval using limit/offset or Range with a default and maximum page size of 1000. Without a count preference, or when the selected count mode cannot supply a total, Content-Range is **. Singular Accept still validates page cardinality. Unlike Supabase, planned and estimated counts do not use PostgreSQL planner estimates. Count preferences: without filters, exact, planned and estimated all use SQLite's exact b-tree count. With filters, exact counts within budget; planned skips counting and reports an unknown total (Content-Range: 0-24*); estimated attempts exact counting only when the preflight budget allows it, otherwise reports an unknown total. Preference-Applied echoes the requested count mode. Use praxis.database.count in the SDK or codemode to return { count: number | null } from this header without retrieving rows.
7150
+ */
7151
+ export const databaseHead = (options) => (options.client ?? client).head({
7152
+ security: [{
7153
+ key: 'database-bearerAuth',
7154
+ scheme: 'bearer',
7155
+ type: 'http'
7156
+ }],
7157
+ url: '/database/v1/databases/{database_id}/rest/{table}',
7158
+ ...options
7159
+ });
7160
+ /**
7161
+ * Update rows
7162
+ *
7163
+ * Updates the rows matched by the filter query parameters (the same filters as databaseSelect); with no filter every row of the table matches. The JSON object body lists only the fields to change, other fields keep their values, and id cannot be changed. Values are validated against the field types and the required and unique settings (400 VALIDATION_FAILED, 409 UNIQUE_VIOLATION). The default response is 204 with no body; send Prefer: return=representation to get HTTP 200 with the updated rows. Each changed row's _version increases by one.
7164
+ */
7165
+ export const databaseUpdate = (options) => (options.client ?? client).patch({
7166
+ security: [{
7167
+ key: 'database-bearerAuth',
7168
+ scheme: 'bearer',
7169
+ type: 'http'
7170
+ }],
7171
+ url: '/database/v1/databases/{database_id}/rest/{table}',
6878
7172
  ...options,
6879
7173
  headers: {
6880
7174
  'Content-Type': 'application/json',
@@ -6882,31 +7176,1358 @@ export const mediaCreateBatch = (options) => (options.client ?? client).post({
6882
7176
  }
6883
7177
  });
6884
7178
  /**
6885
- * Get batch
7179
+ * Insert rows
6886
7180
  *
6887
- * Read a batch job’s status, successful and failed item counts, and a bounded list of failed items. Use the id returned by batch creation; a job outside this library is not found.
7181
+ * Insert rows into an existing table after defining its fields; at most 500 rows per request. Each request is atomic: any failure rolls back the entire batch. There are no transactions across requests.
7182
+ * Rows are filled to the union of their keys with null; send Prefer: missing=default to use field defaults for missing keys.
7183
+ * The default is return=minimal: success returns HTTP 201 with an empty body. Send Prefer: return=representation to return the inserted rows. With resolution=merge-duplicates, a conflicting row keeps columns omitted from the request; supplied values replace the whole field value (including JSON objects), and explicit null clears a nullable field. With resolution=ignore-duplicates, a conflicting row is left unchanged. Without a conflict, both modes insert a new row using field defaults for omitted fields. In a batch, a key present in another row is filled with null when omitted in this row unless missing=default is set; that null can overwrite a value during merge. With missing=default, omitted keys stay omitted for conflict merges (existing values are preserved); new rows use defaults, or null when no default exists. Explicit null never invokes a default. Unlike Supabase, upsert conflicts can target only id or one unique field, not a composite key. Each table supports up to 1,000,000 rows.
6888
7184
  */
6889
- export const mediaGetBatch = (options) => (options.client ?? client).get({
7185
+ export const databaseInsert = (options) => (options.client ?? client).post({
6890
7186
  security: [{
6891
- key: 'media-BearerAuth',
7187
+ key: 'database-bearerAuth',
6892
7188
  scheme: 'bearer',
6893
7189
  type: 'http'
6894
7190
  }],
6895
- url: '/media/v1/libraries/{library_id}/batches/{job_id}',
7191
+ url: '/database/v1/databases/{database_id}/rest/{table}',
7192
+ ...options,
7193
+ headers: {
7194
+ 'Content-Type': 'application/json',
7195
+ ...options.headers
7196
+ }
7197
+ });
7198
+ /**
7199
+ * List knowledge bases
7200
+ *
7201
+ * Lists knowledge bases visible to the caller, newest first by default. Use last_id as after to read the next page; for example, ?limit=20.
7202
+ */
7203
+ export const knowledgeListVectorStores = (options) => (options?.client ?? client).get({
7204
+ security: [{
7205
+ key: 'knowledge-bearerAuth',
7206
+ scheme: 'bearer',
7207
+ type: 'http'
7208
+ }],
7209
+ url: '/knowledge/v1/vector_stores',
6896
7210
  ...options
6897
7211
  });
6898
7212
  /**
6899
- * Batch assets alias
7213
+ * Create knowledge base
6900
7214
  *
6901
- * Alias of batch creation. Apply one metadata or deletion action to ids or a frozen expression selection asynchronously; poll the returned job id to inspect completion and item failures.
7215
+ * Create a knowledge base, optionally starting ingestion of uploaded file_ids in the same call; no separate attachment or batch is needed for those files. Use the returned id with vectorStores.files.retrieve to poll each attachment until completed, failed or cancelled; store status=completed alone does not mean every file succeeded. PDF files accept up to 536870912 bytes (512 MiB), while other formats accept up to 52428800 bytes (50 MiB), constrained by Router conversion; every file is limited to 5000000 estimated tokens; each account holds up to 100 active/nondeleted stores. Minimal body: {"name":"Refund policies"}.
6902
7216
  */
6903
- export const mediaBatchAssets = (options) => (options.client ?? client).post({
7217
+ export const knowledgeCreateVectorStore = (options) => (options.client ?? client).post({
6904
7218
  security: [{
6905
- key: 'media-BearerAuth',
7219
+ key: 'knowledge-bearerAuth',
7220
+ scheme: 'bearer',
7221
+ type: 'http'
7222
+ }],
7223
+ url: '/knowledge/v1/vector_stores',
7224
+ ...options,
7225
+ headers: {
7226
+ 'Content-Type': 'application/json',
7227
+ ...options.headers
7228
+ }
7229
+ });
7230
+ /**
7231
+ * Delete knowledge base
7232
+ *
7233
+ * Remove a knowledge base from active use while keeping a recovery window. Unlike OpenAI vector stores, native DELETE returns the store with status=deleting and ISO purge_at, retains it for 7 days and is idempotent on repeat. Retrieve remains 200; object operations return 409. Use restore before purge_at to recover it, or purge to remove it irreversibly.
7234
+ */
7235
+ export const knowledgeDeleteVectorStore = (options) => (options.client ?? client).delete({
7236
+ security: [{
7237
+ key: 'knowledge-bearerAuth',
7238
+ scheme: 'bearer',
7239
+ type: 'http'
7240
+ }],
7241
+ url: '/knowledge/v1/vector_stores/{vector_store_id}',
7242
+ ...options
7243
+ });
7244
+ /**
7245
+ * Retrieve knowledge base
7246
+ *
7247
+ * Retrieves a knowledge base using an id returned by create or list. Add ?expand=files to include the first page of attached files. Soft-deleted stores remain readable with status=deleting until purged.
7248
+ */
7249
+ export const knowledgeRetrieveVectorStore = (options) => (options.client ?? client).get({
7250
+ security: [{
7251
+ key: 'knowledge-bearerAuth',
7252
+ scheme: 'bearer',
7253
+ type: 'http'
7254
+ }],
7255
+ url: '/knowledge/v1/vector_stores/{vector_store_id}',
7256
+ ...options
7257
+ });
7258
+ /**
7259
+ * Update knowledge base
7260
+ *
7261
+ * Updates an active knowledge base using its returned id. Omitted fields stay unchanged; metadata replaces the whole map. Example body: {"name":"Refund policies"}.
7262
+ */
7263
+ export const knowledgeUpdateVectorStore = (options) => (options.client ?? client).post({
7264
+ security: [{
7265
+ key: 'knowledge-bearerAuth',
7266
+ scheme: 'bearer',
7267
+ type: 'http'
7268
+ }],
7269
+ url: '/knowledge/v1/vector_stores/{vector_store_id}',
7270
+ ...options,
7271
+ headers: {
7272
+ 'Content-Type': 'application/json',
7273
+ ...options.headers
7274
+ }
7275
+ });
7276
+ /**
7277
+ * Search knowledge base
7278
+ *
7279
+ * Search ingested text to answer a question or find supporting passages. Native results contain one chunk each, so file_id can repeat; max_num_results counts chunks (1–50, default 10), while the compatible URL groups results by file. Unlike OpenAI vector stores, next_page is always null even when has_more is true. Only completed attachments are searchable. For keyword-only retrieval set ranking_options.hybrid_search to {"embedding_weight":0,"text_weight":1}; omit rewrite_query or set it to false to avoid query rewriting. Unlike OpenAI, ranker auto does not rerank; only default-2024-11-15 requests reranking. Set praxis.explain=true to inspect scores and use returned content[].chunk_id to retrieve a segment.
7280
+ */
7281
+ export const knowledgeSearchVectorStore = (options) => (options.client ?? client).post({
7282
+ security: [{
7283
+ key: 'knowledge-bearerAuth',
7284
+ scheme: 'bearer',
7285
+ type: 'http'
7286
+ }],
7287
+ url: '/knowledge/v1/vector_stores/{vector_store_id}/search',
7288
+ ...options,
7289
+ headers: {
7290
+ 'Content-Type': 'application/json',
7291
+ ...options.headers
7292
+ }
7293
+ });
7294
+ /**
7295
+ * List files
7296
+ *
7297
+ * Lists attached files and their ingestion status, newest attachment first by default. Use last_id as after to continue; ?filter=failed selects files that can be retried.
7298
+ */
7299
+ export const knowledgeListFiles = (options) => (options.client ?? client).get({
7300
+ security: [{
7301
+ key: 'knowledge-bearerAuth',
7302
+ scheme: 'bearer',
7303
+ type: 'http'
7304
+ }],
7305
+ url: '/knowledge/v1/vector_stores/{vector_store_id}/files',
7306
+ ...options
7307
+ });
7308
+ /**
7309
+ * Add file
7310
+ *
7311
+ * Attach an uploaded File for asynchronous ingestion, then poll this attachment until status is completed, failed or cancelled before searching. PDF files accept up to 536870912 bytes (512 MiB), while other formats accept up to 52428800 bytes (50 MiB), constrained by Router conversion; every file is limited to 5000000 estimated tokens; chunk sizes use estimated tokens rather than a model tokenizer. Text, Markdown, CSV, JSON, HTML, PDF, DOCX, PPTX, XLSX and PNG/JPEG/GIF/WebP images can be extracted; audio and video uploads are not knowledge documents. Images may yield generated descriptions rather than verbatim OCR. auto chunking resolves to static 800/400; explicit sizes are 100–4096 with overlap at most half the size. Each store holds at most 10000 attached files. Reattaching the same file returns its existing record without applying new attributes or chunking; inspect last_error after failure.
7312
+ */
7313
+ export const knowledgeAttachFile = (options) => (options.client ?? client).post({
7314
+ security: [{
7315
+ key: 'knowledge-bearerAuth',
7316
+ scheme: 'bearer',
7317
+ type: 'http'
7318
+ }],
7319
+ url: '/knowledge/v1/vector_stores/{vector_store_id}/files',
7320
+ ...options,
7321
+ headers: {
7322
+ 'Content-Type': 'application/json',
7323
+ ...options.headers
7324
+ }
7325
+ });
7326
+ /**
7327
+ * Remove file
7328
+ *
7329
+ * Removes the file from search immediately; does not delete the original File.
7330
+ */
7331
+ export const knowledgeRemoveFile = (options) => (options.client ?? client).delete({
7332
+ security: [{
7333
+ key: 'knowledge-bearerAuth',
7334
+ scheme: 'bearer',
7335
+ type: 'http'
7336
+ }],
7337
+ url: '/knowledge/v1/vector_stores/{vector_store_id}/files/{file_id}',
7338
+ ...options
7339
+ });
7340
+ /**
7341
+ * Retrieve file
7342
+ *
7343
+ * Retrieves an attached file using the id returned by attachment or file listing. Poll this operation until status leaves in_progress to observe the ingestion outcome.
7344
+ */
7345
+ export const knowledgeRetrieveFile = (options) => (options.client ?? client).get({
7346
+ security: [{
7347
+ key: 'knowledge-bearerAuth',
7348
+ scheme: 'bearer',
7349
+ type: 'http'
7350
+ }],
7351
+ url: '/knowledge/v1/vector_stores/{vector_store_id}/files/{file_id}',
7352
+ ...options
7353
+ });
7354
+ /**
7355
+ * Update file attributes
7356
+ *
7357
+ * Replaces search-filter attributes of an existing attachment without reingesting its content. Use an attached file id. Example body: {"attributes":{"category":"refund"}}; null clears the attributes.
7358
+ */
7359
+ export const knowledgeUpdateFile = (options) => (options.client ?? client).post({
7360
+ security: [{
7361
+ key: 'knowledge-bearerAuth',
7362
+ scheme: 'bearer',
7363
+ type: 'http'
7364
+ }],
7365
+ url: '/knowledge/v1/vector_stores/{vector_store_id}/files/{file_id}',
7366
+ ...options,
7367
+ headers: {
7368
+ 'Content-Type': 'application/json',
7369
+ ...options.headers
7370
+ }
7371
+ });
7372
+ /**
7373
+ * Read extracted content
7374
+ *
7375
+ * Extracted text chunks may overlap. Image content can be a generated description rather than verbatim OCR.
7376
+ */
7377
+ export const knowledgeRetrieveFileContent = (options) => (options.client ?? client).get({
7378
+ security: [{
7379
+ key: 'knowledge-bearerAuth',
7380
+ scheme: 'bearer',
7381
+ type: 'http'
7382
+ }],
7383
+ url: '/knowledge/v1/vector_stores/{vector_store_id}/files/{file_id}/content',
7384
+ ...options
7385
+ });
7386
+ /**
7387
+ * Create file batch
7388
+ *
7389
+ * Attaches existing Files as a batch for asynchronous ingestion. Supply exactly one of file_ids or files; files allows per-file settings. Existing attachments are reused. Read the returned batch id to monitor status.
7390
+ */
7391
+ export const knowledgeCreateFileBatch = (options) => (options.client ?? client).post({
7392
+ security: [{
7393
+ key: 'knowledge-bearerAuth',
7394
+ scheme: 'bearer',
7395
+ type: 'http'
7396
+ }],
7397
+ url: '/knowledge/v1/vector_stores/{vector_store_id}/file_batches',
7398
+ ...options,
7399
+ headers: {
7400
+ 'Content-Type': 'application/json',
7401
+ ...options.headers
7402
+ }
7403
+ });
7404
+ /**
7405
+ * Retrieve file batch
7406
+ *
7407
+ * Retrieves a batch created in this knowledge base, including current status and file counts. Use the batch id returned by batch creation to monitor ingestion.
7408
+ */
7409
+ export const knowledgeRetrieveFileBatch = (options) => (options.client ?? client).get({
7410
+ security: [{
7411
+ key: 'knowledge-bearerAuth',
7412
+ scheme: 'bearer',
7413
+ type: 'http'
7414
+ }],
7415
+ url: '/knowledge/v1/vector_stores/{vector_store_id}/file_batches/{batch_id}',
7416
+ ...options
7417
+ });
7418
+ /**
7419
+ * Cancel file batch
7420
+ *
7421
+ * Cancels only in-progress batches and pending files. Completed, failed and cancelled batches return unchanged (200, idempotent).
7422
+ */
7423
+ export const knowledgeCancelFileBatch = (options) => (options.client ?? client).post({
7424
+ security: [{
7425
+ key: 'knowledge-bearerAuth',
7426
+ scheme: 'bearer',
7427
+ type: 'http'
7428
+ }],
7429
+ url: '/knowledge/v1/vector_stores/{vector_store_id}/file_batches/{batch_id}/cancel',
7430
+ ...options
7431
+ });
7432
+ /**
7433
+ * List batch files
7434
+ *
7435
+ * Lists files still attached from the identified batch, newest attachment first by default. Use the batch creation id and ?filter=failed to inspect failures; last_id is the next after cursor.
7436
+ */
7437
+ export const knowledgeListBatchFiles = (options) => (options.client ?? client).get({
7438
+ security: [{
7439
+ key: 'knowledge-bearerAuth',
7440
+ scheme: 'bearer',
7441
+ type: 'http'
7442
+ }],
7443
+ url: '/knowledge/v1/vector_stores/{vector_store_id}/file_batches/{batch_id}/files',
7444
+ ...options
7445
+ });
7446
+ /**
7447
+ * Restore knowledge base
7448
+ *
7449
+ * Restores a deleting store within 7 days. Active stores return 409 VECTOR_STORE_INVALID_STATE; absent stores return 404. Empty body is allowed.
7450
+ */
7451
+ export const knowledgeRestoreVectorStore = (options) => (options.client ?? client).post({
7452
+ security: [{
7453
+ key: 'knowledge-bearerAuth',
7454
+ scheme: 'bearer',
7455
+ type: 'http'
7456
+ }],
7457
+ url: '/knowledge/v1/vector_stores/{vector_store_id}/restore',
7458
+ ...options
7459
+ });
7460
+ /**
7461
+ * Permanently purge knowledge base
7462
+ *
7463
+ * Immediately and irreversibly clears a deleting store using the retention cleanup path. Active stores return 409; absent stores return 404. Empty body is allowed.
7464
+ */
7465
+ export const knowledgePurgeVectorStore = (options) => (options.client ?? client).post({
7466
+ security: [{
7467
+ key: 'knowledge-bearerAuth',
7468
+ scheme: 'bearer',
7469
+ type: 'http'
7470
+ }],
7471
+ url: '/knowledge/v1/vector_stores/{vector_store_id}/purge',
7472
+ ...options
7473
+ });
7474
+ /**
7475
+ * Retry failed file
7476
+ *
7477
+ * Retries only failed files; other states return 409 FILE_INVALID_STATE. Retry after failure has not yet been observed in the documented run.
7478
+ */
7479
+ export const knowledgeRetryFile = (options) => (options.client ?? client).post({
7480
+ security: [{
7481
+ key: 'knowledge-bearerAuth',
7482
+ scheme: 'bearer',
7483
+ type: 'http'
7484
+ }],
7485
+ url: '/knowledge/v1/vector_stores/{vector_store_id}/files/{file_id}/retry',
7486
+ ...options
7487
+ });
7488
+ /**
7489
+ * List file segments
7490
+ *
7491
+ * Lists the stored chunks of an attached file, ordered by increasing segment index by default. Use the attachment id and last_id as after to continue; returned chunk ids can be retrieved individually.
7492
+ */
7493
+ export const knowledgeListSegments = (options) => (options.client ?? client).get({
7494
+ security: [{
7495
+ key: 'knowledge-bearerAuth',
7496
+ scheme: 'bearer',
7497
+ type: 'http'
7498
+ }],
7499
+ url: '/knowledge/v1/vector_stores/{vector_store_id}/files/{file_id}/segments',
7500
+ ...options
7501
+ });
7502
+ /**
7503
+ * Retrieve segment
7504
+ *
7505
+ * Retrieves one chunk and its term statistics. Take chunk_id from segment listing or native search content; the chunk must belong to this knowledge base.
7506
+ */
7507
+ export const knowledgeRetrieveSegment = (options) => (options.client ?? client).get({
7508
+ security: [{
7509
+ key: 'knowledge-bearerAuth',
7510
+ scheme: 'bearer',
7511
+ type: 'http'
7512
+ }],
7513
+ url: '/knowledge/v1/vector_stores/{vector_store_id}/segments/{chunk_id}',
7514
+ ...options
7515
+ });
7516
+ /**
7517
+ * List events
7518
+ *
7519
+ * Reads events for this knowledge base in increasing sequence order, including while soft-deleted. Pass next_seq as after_seq to continue; null next_seq marks the current end. Example: ?after_seq=0&limit=20.
7520
+ */
7521
+ export const knowledgeListEvents = (options) => (options.client ?? client).get({
7522
+ security: [{
7523
+ key: 'knowledge-bearerAuth',
7524
+ scheme: 'bearer',
7525
+ type: 'http'
7526
+ }],
7527
+ url: '/knowledge/v1/vector_stores/{vector_store_id}/events',
7528
+ ...options
7529
+ });
7530
+ /**
7531
+ * List libraries
7532
+ *
7533
+ * Read a caller-owned library’s current settings, usage and lifecycle status. A deleting library remains readable; missing, foreign or purged libraries return LIBRARY_NOT_FOUND.
7534
+ */
7535
+ export const mediaListLibraries = (options) => (options?.client ?? client).get({
7536
+ security: [{
7537
+ key: 'media-BearerAuth',
7538
+ scheme: 'bearer',
7539
+ type: 'http'
7540
+ }],
7541
+ url: '/media/v1/libraries',
7542
+ ...options
7543
+ });
7544
+ /**
7545
+ * Create library
7546
+ *
7547
+ * Create a library owned by the caller with a name, optional labels and understanding settings. Understanding is enabled by default; the returned id is used for subsequent asset operations.
7548
+ */
7549
+ export const mediaCreateLibrary = (options) => (options.client ?? client).post({
7550
+ security: [{
7551
+ key: 'media-BearerAuth',
7552
+ scheme: 'bearer',
7553
+ type: 'http'
7554
+ }],
7555
+ url: '/media/v1/libraries',
7556
+ ...options,
7557
+ headers: {
7558
+ 'Content-Type': 'application/json',
7559
+ ...options.headers
7560
+ }
7561
+ });
7562
+ /**
7563
+ * Create frame URLs
7564
+ *
7565
+ * Media creates JPEG frame URLs for inspecting one or more moments in a video without downloading the original. Obtain library_id from libraries and asset_id plus duration from assets. Send 1–20 integer microsecond timestamps strictly below duration, for example {"at_micros":[0,1000000],"width":640}. Only video assets are supported; audio and images return INVALID_PARAMS. Width defaults to 640 and accepts 160, 320 or 640. This read operation does not store a new asset or rerun understanding. Fetch each returned URL to obtain the frame; delivery usage follows media pricing. Authenticated links expire after 300 seconds; upload links remain public and permanent. Reissue expired links. Foreign libraries and assets return 404 without revealing their existence.
7566
+ */
7567
+ export const mediaCreateFrameUrls = (options) => (options.client ?? client).post({
7568
+ security: [{
7569
+ key: 'media-BearerAuth',
7570
+ scheme: 'bearer',
7571
+ type: 'http'
7572
+ }],
7573
+ url: '/media/v1/libraries/{library_id}/assets/{asset_id}/frames',
7574
+ ...options,
7575
+ headers: {
7576
+ 'Content-Type': 'application/json',
7577
+ ...options.headers
7578
+ }
7579
+ });
7580
+ /**
7581
+ * Delete library
7582
+ *
7583
+ * Restore a deleting library before its purge_at deadline. The library becomes active again and deleted_at and purge_at are cleared; expired or non-deleting libraries cannot be restored.
7584
+ */
7585
+ export const mediaDeleteLibrary = (options) => (options.client ?? client).delete({
7586
+ security: [{
7587
+ key: 'media-BearerAuth',
7588
+ scheme: 'bearer',
7589
+ type: 'http'
7590
+ }],
7591
+ url: '/media/v1/libraries/{library_id}',
7592
+ ...options
7593
+ });
7594
+ /**
7595
+ * Get library
7596
+ *
7597
+ * Update an active library’s supplied settings. Labels replace the complete map; understanding settings and model roles merge with current values. Changing the embedding model is rejected while assets exist.
7598
+ */
7599
+ export const mediaGetLibrary = (options) => (options.client ?? client).get({
7600
+ security: [{
7601
+ key: 'media-BearerAuth',
7602
+ scheme: 'bearer',
7603
+ type: 'http'
7604
+ }],
7605
+ url: '/media/v1/libraries/{library_id}',
7606
+ ...options
7607
+ });
7608
+ /**
7609
+ * Update library
7610
+ *
7611
+ * Update an active library. Set hotwords for spelling evidence in subsequent transcripts; [] disables inferred vocabulary. Transcript understanding calls the timestamped ASR, optional reference ASR and correction model through the existing metered model path. Reprocess assets to apply new settings to existing transcripts.
7612
+ */
7613
+ export const mediaUpdateLibrary = (options) => (options.client ?? client).patch({
7614
+ security: [{
7615
+ key: 'media-BearerAuth',
7616
+ scheme: 'bearer',
7617
+ type: 'http'
7618
+ }],
7619
+ url: '/media/v1/libraries/{library_id}',
7620
+ ...options,
7621
+ headers: {
7622
+ 'Content-Type': 'application/json',
7623
+ ...options.headers
7624
+ }
7625
+ });
7626
+ /**
7627
+ * Restore library
7628
+ *
7629
+ * Permanently remove a library that is already deleting, without waiting for purge_at. Its assets and related resources are removed and cannot be restored; first soft-delete an active library.
7630
+ */
7631
+ export const mediaRestoreLibrary = (options) => (options.client ?? client).post({
7632
+ security: [{
7633
+ key: 'media-BearerAuth',
7634
+ scheme: 'bearer',
7635
+ type: 'http'
7636
+ }],
7637
+ url: '/media/v1/libraries/{library_id}/restore',
7638
+ ...options
7639
+ });
7640
+ /**
7641
+ * Purge library
7642
+ *
7643
+ * List assets in an active library, newest first, optionally filtering by exact folder and stored resource type. Continue using next_cursor; video includes audio-only assets.
7644
+ */
7645
+ export const mediaPurgeLibrary = (options) => (options.client ?? client).post({
7646
+ security: [{
7647
+ key: 'media-BearerAuth',
7648
+ scheme: 'bearer',
7649
+ type: 'http'
7650
+ }],
7651
+ url: '/media/v1/libraries/{library_id}/purge',
7652
+ ...options
7653
+ });
7654
+ /**
7655
+ * List assets
7656
+ *
7657
+ * Upload content into an active library and return a Cloudinary-compatible resource. Use file for a multipart file, data URI, public HTTPS URL or same-owner file identifier. Reusing public_id overwrites by default; overwrite=false returns the existing resource. Chunk uploads require both chunk headers.
7658
+ */
7659
+ export const mediaListAssets = (options) => (options.client ?? client).get({
7660
+ security: [{
7661
+ key: 'media-BearerAuth',
7662
+ scheme: 'bearer',
7663
+ type: 'http'
7664
+ }],
7665
+ url: '/media/v1/libraries/{library_id}/assets',
7666
+ ...options
7667
+ });
7668
+ /**
7669
+ * Upload asset
7670
+ *
7671
+ * For understanding, Media generates proxies for video sources of 25 MB or more or longer than 10 minutes, and for audio-only sources of 100 MB or more; originals remain available unchanged. Long videos are supported. When a video proxy is needed and is still above 95 MB after recompression, the source is reported as UNSUPPORTED with the limit in the failure message. Proxy preparation uses the organization’s metered sandbox resources.
7672
+ */
7673
+ export const mediaUploadAsset = (options) => (options.client ?? client).post({
7674
+ security: [{
7675
+ key: 'media-BearerAuth',
7676
+ scheme: 'bearer',
7677
+ type: 'http'
7678
+ }],
7679
+ url: '/media/v1/libraries/{library_id}/assets',
7680
+ ...options,
7681
+ headers: {
7682
+ 'Content-Type': 'application/json',
7683
+ ...options.headers
7684
+ }
7685
+ });
7686
+ /**
7687
+ * Import file
7688
+ *
7689
+ * Copy a File into an independent Media asset. New assets default to organization-private delivery (type=authenticated); explicitly set type=upload for public originals and derivatives. Omitting type on overwrite preserves the current type. Deleting the source File does not delete this copy. For understanding, Media generates proxies for video sources of 25 MB or more or longer than 10 minutes, and for audio-only sources of 100 MB or more; originals remain available unchanged. Long videos are supported. When a video proxy is needed and is still above 95 MB after recompression, the source is reported as UNSUPPORTED with the limit in the failure message. Proxy preparation uses the organization’s metered sandbox resources.
7690
+ */
7691
+ export const mediaImportAsset = (options) => (options.client ?? client).post({
7692
+ security: [{
7693
+ key: 'media-BearerAuth',
7694
+ scheme: 'bearer',
7695
+ type: 'http'
7696
+ }],
7697
+ url: '/media/v1/libraries/{library_id}/assets/import',
7698
+ ...options,
7699
+ headers: {
7700
+ 'Content-Type': 'application/json',
7701
+ ...options.headers
7702
+ }
7703
+ });
7704
+ /**
7705
+ * Delete asset
7706
+ *
7707
+ * Queue reprocessing of the asset’s current version and return its updated state immediately. Omit kinds to retry failed tasks and legacy source-size unsupported tasks; explicit kinds rerun applicable completed tasks and recoverable source-size unsupported tasks. Other unsupported causes remain unchanged. Replaced understandings become superseded, and processing finishes asynchronously.
7708
+ */
7709
+ export const mediaDeleteAsset = (options) => (options.client ?? client).delete({
7710
+ security: [{
7711
+ key: 'media-BearerAuth',
7712
+ scheme: 'bearer',
7713
+ type: 'http'
7714
+ }],
7715
+ url: '/media/v1/libraries/{library_id}/assets/{asset_id}',
7716
+ ...options
7717
+ });
7718
+ /**
7719
+ * Get asset
7720
+ *
7721
+ * Update an asset’s supplied metadata fields. Tags and context replace their current collections; an empty collection clears them. Moving asset_folder or changing display_name preserves public_id and delivery URLs.
7722
+ */
7723
+ export const mediaGetAsset = (options) => (options.client ?? client).get({
7724
+ security: [{
7725
+ key: 'media-BearerAuth',
7726
+ scheme: 'bearer',
7727
+ type: 'http'
7728
+ }],
7729
+ url: '/media/v1/libraries/{library_id}/assets/{asset_id}',
7730
+ ...options
7731
+ });
7732
+ /**
7733
+ * Update asset
7734
+ *
7735
+ * Delete an asset from the library so it is no longer readable, searchable or deliverable. This removes the asset rather than placing it in the library’s restoration window; a missing asset returns ASSET_NOT_FOUND.
7736
+ */
7737
+ export const mediaUpdateAsset = (options) => (options.client ?? client).patch({
7738
+ security: [{
7739
+ key: 'media-BearerAuth',
7740
+ scheme: 'bearer',
7741
+ type: 'http'
7742
+ }],
7743
+ url: '/media/v1/libraries/{library_id}/assets/{asset_id}',
7744
+ ...options,
7745
+ headers: {
7746
+ 'Content-Type': 'application/json',
7747
+ ...options.headers
7748
+ }
7749
+ });
7750
+ /**
7751
+ * Reprocess asset
7752
+ *
7753
+ * For understanding, Media generates proxies for video sources of 25 MB or more or longer than 10 minutes, and for audio-only sources of 100 MB or more; originals remain available unchanged. Long videos are supported. When a video proxy is needed and is still above 95 MB after recompression, the source is reported as UNSUPPORTED with the limit in the failure message. Proxy preparation uses the organization’s metered sandbox resources.
7754
+ */
7755
+ export const mediaReprocessAsset = (options) => (options.client ?? client).post({
7756
+ security: [{
7757
+ key: 'media-BearerAuth',
7758
+ scheme: 'bearer',
7759
+ type: 'http'
7760
+ }],
7761
+ url: '/media/v1/libraries/{library_id}/assets/{asset_id}/reprocess',
7762
+ ...options,
7763
+ headers: {
7764
+ 'Content-Type': 'application/json',
7765
+ ...options.headers
7766
+ }
7767
+ });
7768
+ /**
7769
+ * List understandings
7770
+ *
7771
+ * List understanding results for an asset, ordered by creation time. Use the cursor to continue; include_superseded also returns replaced records. The optional shots array contains current-version shot boundaries and per-shot captions, scene, location guesses, visible text and confidence flags; it is absent on legacy records. Location guesses and folder mismatch are unverified hints. Correction-enabled transcripts expose text_original, corrected text and a correction audit. Their timed data array remains suitable for subtitles. Reference failure is marked missing; correction failure returns the original verbatim. Model inference uses the existing metered model path.
7772
+ */
7773
+ export const mediaListUnderstandings = (options) => (options.client ?? client).get({
7774
+ security: [{
7775
+ key: 'media-BearerAuth',
7776
+ scheme: 'bearer',
7777
+ type: 'http'
7778
+ }],
7779
+ url: '/media/v1/libraries/{library_id}/assets/{asset_id}/understandings',
7780
+ ...options
7781
+ });
7782
+ /**
7783
+ * Expression search
7784
+ *
7785
+ * Find visually similar assets using exactly one of asset_id or an inline base64 image. The library must support image search; an asset query needs a current image embedding and excludes that source asset from results.
7786
+ */
7787
+ export const mediaExpressionSearch = (options) => (options.client ?? client).post({
7788
+ security: [{
7789
+ key: 'media-BearerAuth',
7790
+ scheme: 'bearer',
7791
+ type: 'http'
7792
+ }],
7793
+ url: '/media/v1/libraries/{library_id}/search/expression',
7794
+ ...options,
7795
+ headers: {
7796
+ 'Content-Type': 'application/json',
7797
+ ...options.headers
7798
+ }
7799
+ });
7800
+ /**
7801
+ * Visual search
7802
+ *
7803
+ * Search assets with a nonblank text query and optional expression filter. Hybrid mode combines semantic and keyword matches; semantic mode uses vector similarity only. Results are ranked and limited by top_k.
7804
+ */
7805
+ export const mediaVisualSearch = (options) => (options.client ?? client).post({
7806
+ security: [{
7807
+ key: 'media-BearerAuth',
7808
+ scheme: 'bearer',
7809
+ type: 'http'
7810
+ }],
7811
+ url: '/media/v1/libraries/{library_id}/search/visual',
7812
+ ...options,
7813
+ headers: {
7814
+ 'Content-Type': 'application/json',
7815
+ ...options.headers
7816
+ }
7817
+ });
7818
+ /**
7819
+ * Semantic search
7820
+ *
7821
+ * Alias of semantic search. Search assets with a nonblank text query, optional expression filter and top_k; hybrid combines semantic and keyword matches, while semantic uses vector similarity only.
7822
+ */
7823
+ export const mediaSemanticSearch = (options) => (options.client ?? client).post({
7824
+ security: [{
7825
+ key: 'media-BearerAuth',
7826
+ scheme: 'bearer',
7827
+ type: 'http'
7828
+ }],
7829
+ url: '/media/v1/libraries/{library_id}/search/semantic',
7830
+ ...options,
7831
+ headers: {
7832
+ 'Content-Type': 'application/json',
7833
+ ...options.headers
7834
+ }
7835
+ });
7836
+ /**
7837
+ * Semantic search alias
7838
+ *
7839
+ * List all immediate child folders under parent, or under the root when parent is omitted. Counts include descendant assets. The result is unpaginated; limit and cursor are rejected.
7840
+ */
7841
+ export const mediaSearch = (options) => (options.client ?? client).post({
7842
+ security: [{
7843
+ key: 'media-BearerAuth',
7844
+ scheme: 'bearer',
7845
+ type: 'http'
7846
+ }],
7847
+ url: '/media/v1/libraries/{library_id}/search',
7848
+ ...options,
7849
+ headers: {
7850
+ 'Content-Type': 'application/json',
7851
+ ...options.headers
7852
+ }
7853
+ });
7854
+ /**
7855
+ * List folders
7856
+ *
7857
+ * undefined understood_count includes ready and partial assets; failed_count includes failed assets. Both accumulate descendants. counts_complete is false during historical backfill.
7858
+ */
7859
+ export const mediaListFolders = (options) => (options.client ?? client).get({
7860
+ security: [{
7861
+ key: 'media-BearerAuth',
7862
+ scheme: 'bearer',
7863
+ type: 'http'
7864
+ }],
7865
+ url: '/media/v1/libraries/{library_id}/folders',
7866
+ ...options
7867
+ });
7868
+ /**
7869
+ * Create batch
7870
+ *
7871
+ * Queue a frozen selection for tagging, untagging, context replacement, moving, deleting or reprocessing. IDs are limited to 1000; use an expression for larger selections, subject to the search scan budget. reprocess starts at most 30 assets per rolling minute per library. Only retryable failed steps and legacy source-size unsupported steps rerun. Omit kinds to inspect all recoverable steps, or supply kinds to narrow them. Other unsupported, permanent and completed steps remain unchanged; a permanent output blocks only its own step. Assets without any selected recoverable step count as failed items without starting understanding. Poll the returned job id; done counts accepted launches, not successful model inference. Staff Admin only permits reprocess and requires a nonblank reason. Example: {"action":"reprocess","selector":{"expression":"processing_state=failed AND failure_code=UPSTREAM_FAILED"}}. For understanding, Media generates proxies for video sources of 25 MB or more or longer than 10 minutes, and for audio-only sources of 100 MB or more; originals remain available unchanged. Long videos are supported. When a video proxy is needed and is still above 95 MB after recompression, the source is reported as UNSUPPORTED with the limit in the failure message. Proxy preparation uses the organization’s metered sandbox resources.
7872
+ */
7873
+ export const mediaCreateBatch = (options) => (options.client ?? client).post({
7874
+ security: [{
7875
+ key: 'media-BearerAuth',
7876
+ scheme: 'bearer',
7877
+ type: 'http'
7878
+ }],
7879
+ url: '/media/v1/libraries/{library_id}/batches',
7880
+ ...options,
7881
+ headers: {
7882
+ 'Content-Type': 'application/json',
7883
+ ...options.headers
7884
+ }
7885
+ });
7886
+ /**
7887
+ * Get batch
7888
+ *
7889
+ * Alias of batch creation. Apply one metadata or deletion action to ids or a frozen expression selection asynchronously; poll the returned job id to inspect completion and item failures.
7890
+ */
7891
+ export const mediaGetBatch = (options) => (options.client ?? client).get({
7892
+ security: [{
7893
+ key: 'media-BearerAuth',
7894
+ scheme: 'bearer',
7895
+ type: 'http'
7896
+ }],
7897
+ url: '/media/v1/libraries/{library_id}/batches/{job_id}',
7898
+ ...options
7899
+ });
7900
+ /**
7901
+ * Batch assets alias
7902
+ *
7903
+ * Queue a frozen selection for tagging, untagging, context replacement, moving, deleting or reprocessing. IDs are limited to 1000; use an expression for larger selections, subject to the search scan budget. reprocess starts at most 30 assets per rolling minute per library. Only retryable failed steps and legacy source-size unsupported steps rerun. Omit kinds to inspect all recoverable steps, or supply kinds to narrow them. Other unsupported, permanent and completed steps remain unchanged; a permanent output blocks only its own step. Assets without any selected recoverable step count as failed items without starting understanding. Poll the returned job id; done counts accepted launches, not successful model inference. Staff Admin only permits reprocess and requires a nonblank reason. Example: {"action":"reprocess","selector":{"expression":"processing_state=failed AND failure_code=UPSTREAM_FAILED"}}. For understanding, Media generates proxies for video sources of 25 MB or more or longer than 10 minutes, and for audio-only sources of 100 MB or more; originals remain available unchanged. Long videos are supported. When a video proxy is needed and is still above 95 MB after recompression, the source is reported as UNSUPPORTED with the limit in the failure message. Proxy preparation uses the organization’s metered sandbox resources.
7904
+ */
7905
+ export const mediaBatchAssets = (options) => (options.client ?? client).post({
7906
+ security: [{
7907
+ key: 'media-BearerAuth',
7908
+ scheme: 'bearer',
7909
+ type: 'http'
7910
+ }],
7911
+ url: '/media/v1/libraries/{library_id}/assets:batch',
7912
+ ...options,
7913
+ headers: {
7914
+ 'Content-Type': 'application/json',
7915
+ ...options.headers
7916
+ }
7917
+ });
7918
+ /**
7919
+ * Get job
7920
+ *
7921
+ * Read the current batch or video-generation Job status and progress. For generation, inspect outputs and failures, then save successful candidates before their preview and save window expires after 7 days.
7922
+ */
7923
+ export const mediaGetJob = (options) => (options.client ?? client).get({
7924
+ security: [{
7925
+ key: 'media-BearerAuth',
7926
+ scheme: 'bearer',
7927
+ type: 'http'
7928
+ }],
7929
+ url: '/media/v1/libraries/{library_id}/jobs/{job_id}',
7930
+ ...options
7931
+ });
7932
+ /**
7933
+ * List events
7934
+ *
7935
+ * Read library events in sequence order for observing asset writes and understanding progress. Obtain library_id from creation or listing; continue with after_seq for asc or before_seq for desc, without combining both. Use next_cursor when supplied. Reads do not start or retry understanding.
7936
+ */
7937
+ export const mediaListEvents = (options) => (options.client ?? client).get({
7938
+ security: [{
7939
+ key: 'media-BearerAuth',
7940
+ scheme: 'bearer',
7941
+ type: 'http'
7942
+ }],
7943
+ url: '/media/v1/libraries/{library_id}/events',
7944
+ ...options
7945
+ });
7946
+ /**
7947
+ * Create delivery token
7948
+ *
7949
+ * Issue a time-limited bearer token for originals and transformed authenticated assets in an active library. Use library_id from library creation or listing; read access is sufficient. Append token as the __cld_token__ query parameter on a matching delivery URL. The default ACL covers this library and the default lifetime is 900 seconds; narrow acl and expires_in before sharing. Anyone holding the token can read matching paths until expires_at.
7950
+ */
7951
+ export const mediaCreateDeliveryToken = (options) => (options.client ?? client).post({
7952
+ security: [{
7953
+ key: 'media-BearerAuth',
7954
+ scheme: 'bearer',
7955
+ type: 'http'
7956
+ }],
7957
+ url: '/media/v1/libraries/{library_id}/delivery_tokens',
7958
+ ...options,
7959
+ headers: {
7960
+ 'Content-Type': 'application/json',
7961
+ ...options.headers
7962
+ }
7963
+ });
7964
+ /**
7965
+ * Summarize understanding failures
7966
+ *
7967
+ * Inspect current understanding failures before retrying. Use library_id from library creation or listing. Groups include code, output kind, actual producer model, retryability and up to five sample asset IDs. At most 1024 detailed groups plus two overflow groups are returned; overflow groups separate retryable and unrecoverable entries and mark overflow=true. Unknown failure codes remain retryable. Historical counts are provisional while counts_complete is false. Example: GET /media/v1/libraries/lib_example/understandings/failure_summary.
7968
+ */
7969
+ export const mediaUnderstandingFailureSummary = (options) => (options.client ?? client).get({
7970
+ security: [{
7971
+ key: 'media-BearerAuth',
7972
+ scheme: 'bearer',
7973
+ type: 'http'
7974
+ }],
7975
+ url: '/media/v1/libraries/{library_id}/understandings/failure_summary',
7976
+ ...options
7977
+ });
7978
+ /**
7979
+ * List understanding results across a library
7980
+ *
7981
+ * Read current understanding entries across one library without fetching every asset separately. Use library_id from creation or listing. folder includes descendants; kinds is a comma-separated list of output kinds. Entries are ordered by asset_id and then understanding id. Continue with next_cursor and the same folder and kinds; limit defaults to 100 and cannot exceed 100. Superseded, deleted and old-version entries are excluded. During historical backfill, this method returns 503 CAPACITY rather than incomplete pages; poll failureSummary until counts_complete is true, then start pagination. Example: GET /media/v1/libraries/lib_example/understandings?folder=travel&kinds=caption,transcript&limit=100.
7982
+ */
7983
+ export const mediaListUnderstandingsByLibrary = (options) => (options.client ?? client).get({
7984
+ security: [{
7985
+ key: 'media-BearerAuth',
7986
+ scheme: 'bearer',
7987
+ type: 'http'
7988
+ }],
7989
+ url: '/media/v1/libraries/{library_id}/understandings',
7990
+ ...options
7991
+ });
7992
+ /**
7993
+ * Create video generation
7994
+ *
7995
+ * Create a video.generate job. Generation is charged per second. The response is 202 with a queued Job; poll GET /media/v1/libraries/{library_id}/jobs/{job_id} until terminal, then save successful outputs. Unsaved candidate Files expire after 7 days.
7996
+ */
7997
+ export const mediaCreateGeneration = (options) => (options.client ?? client).post({
7998
+ security: [{
7999
+ key: 'media-BearerAuth',
8000
+ scheme: 'bearer',
8001
+ type: 'http'
8002
+ }],
8003
+ url: '/media/v1/libraries/{library_id}/generations',
8004
+ ...options,
8005
+ headers: {
8006
+ 'Content-Type': 'application/json',
8007
+ ...options.headers
8008
+ }
8009
+ });
8010
+ /**
8011
+ * List jobs
8012
+ *
8013
+ * List batch and video-generation jobs in a library. Filter by status and continue with next_cursor. Poll a generation Job until terminal, then save successful candidate outputs before they expire after 7 days.
8014
+ */
8015
+ export const mediaListJobs = (options) => (options.client ?? client).get({
8016
+ security: [{
8017
+ key: 'media-BearerAuth',
8018
+ scheme: 'bearer',
8019
+ type: 'http'
8020
+ }],
8021
+ url: '/media/v1/libraries/{library_id}/jobs',
8022
+ ...options
8023
+ });
8024
+ /**
8025
+ * Cancel job
8026
+ *
8027
+ * Cancel a queued or running generation job. Already completed outputs remain available to save; poll or read the returned Job to confirm its status.
8028
+ */
8029
+ export const mediaCancelJob = (options) => (options.client ?? client).post({
8030
+ security: [{
8031
+ key: 'media-BearerAuth',
8032
+ scheme: 'bearer',
8033
+ type: 'http'
8034
+ }],
8035
+ url: '/media/v1/libraries/{library_id}/jobs/{job_id}/cancel',
8036
+ ...options
8037
+ });
8038
+ /**
8039
+ * Save generation output
8040
+ *
8041
+ * Save a successful candidate as a library asset. Candidate outputs expire after 7 days; save before expiry. Generation is charged per second when the job runs, not when an output is saved.
8042
+ */
8043
+ export const mediaSaveGenerationOutput = (options) => (options.client ?? client).post({
8044
+ security: [{
8045
+ key: 'media-BearerAuth',
8046
+ scheme: 'bearer',
8047
+ type: 'http'
8048
+ }],
8049
+ url: '/media/v1/libraries/{library_id}/jobs/{job_id}/outputs/{index}/save',
8050
+ ...options,
8051
+ headers: {
8052
+ 'Content-Type': 'application/json',
8053
+ ...options.headers
8054
+ }
8055
+ });
8056
+ /**
8057
+ * Get generation capabilities
8058
+ *
8059
+ * Read supported text-to-video intent, default model, duration and aspect-ratio limits, per-library concurrency and candidate retention. Generation is charged per second; unsaved candidates expire after 7 days.
8060
+ */
8061
+ export const mediaGetGenerationCapabilities = (options) => (options?.client ?? client).get({
8062
+ security: [{
8063
+ key: 'media-BearerAuth',
8064
+ scheme: 'bearer',
8065
+ type: 'http'
8066
+ }],
8067
+ url: '/media/v1/generation/capabilities',
8068
+ ...options
8069
+ });
8070
+ /**
8071
+ * List types
8072
+ *
8073
+ * Read the node and relation types registered for this organization before writing, so a create names a type the graph accepts. Each entry is one registrant's registration with its owner, version and definitions. Types cannot be created at runtime; they are registered by the owning service at deploy time, so a type missing here is not available to write.
8074
+ */
8075
+ export const ontologyListTypes = (options) => (options?.client ?? client).get({
8076
+ security: [{
8077
+ key: 'ontology-bearerAuth',
8078
+ scheme: 'bearer',
8079
+ type: 'http'
8080
+ }],
8081
+ url: '/ontology/v1/types',
8082
+ ...options
8083
+ });
8084
+ /**
8085
+ * Register type
8086
+ *
8087
+ * Register a node or relation type for this organization. Not open yet — this call currently answers 501 NOT_IMPLEMENTED and writes nothing, because a registration is checked and stored by the deploy gate that ships the registering service, not by a runtime call. Until it opens, read the types already in force with praxis.ontology.types.list and create records only of those types.
8088
+ */
8089
+ export const ontologyRegisterType = (options) => (options.client ?? client).post({
8090
+ security: [{
8091
+ key: 'ontology-bearerAuth',
8092
+ scheme: 'bearer',
8093
+ type: 'http'
8094
+ }],
8095
+ url: '/ontology/v1/types',
8096
+ ...options,
8097
+ headers: {
8098
+ 'Content-Type': 'application/json',
8099
+ ...options.headers
8100
+ }
8101
+ });
8102
+ /**
8103
+ * Retrieve type
8104
+ *
8105
+ * Read one registered type's definition before writing a record of it, to learn whether it is a node or an edge, which endpoints an edge type admits, and which origins it accepts. The name comes from types.list; a name that is not registered answers ONTOLOGY_TYPE_UNKNOWN, and writes of that type are refused.
8106
+ */
8107
+ export const ontologyRetrieveType = (options) => (options.client ?? client).get({
8108
+ security: [{
8109
+ key: 'ontology-bearerAuth',
8110
+ scheme: 'bearer',
8111
+ type: 'http'
8112
+ }],
8113
+ url: '/ontology/v1/types/{name}',
8114
+ ...options
8115
+ });
8116
+ /**
8117
+ * List nodes
8118
+ *
8119
+ * Discover the entities in this organization's graph and obtain node ids for retrieval, updates and relations. Filter by type, by free text over names, aliases, descriptions and facts, or by owner; limit is 1–100 and defaults to 50. Omit cursor for the first page, then copy next_cursor into the next request until it is null. A node whose content belongs to somebody else comes back as a restricted entry carrying only its id, type and name.
8120
+ */
8121
+ export const ontologyListNodes = (options) => (options?.client ?? client).get({
8122
+ security: [{
8123
+ key: 'ontology-bearerAuth',
8124
+ scheme: 'bearer',
8125
+ type: 'http'
8126
+ }],
8127
+ url: '/ontology/v1/nodes',
8128
+ ...options
8129
+ });
8130
+ /**
8131
+ * Create node
8132
+ *
8133
+ * Record one entity in the graph, for a system mirroring a record it owns. type must already be registered and ref, when given, must match that type's ref_prefix. Send an Idempotency-Key header; repeating the same key with the same content returns the first result instead of creating a second node. This writes structure only — to give an agent something to remember, use POST /agent/v1/agents/{agent_id}/consolidations.
8134
+ */
8135
+ export const ontologyCreateNode = (options) => (options.client ?? client).post({
8136
+ security: [{
8137
+ key: 'ontology-bearerAuth',
8138
+ scheme: 'bearer',
8139
+ type: 'http'
8140
+ }],
8141
+ url: '/ontology/v1/nodes',
8142
+ ...options,
8143
+ headers: {
8144
+ 'Content-Type': 'application/json',
8145
+ ...options.headers
8146
+ }
8147
+ });
8148
+ /**
8149
+ * Retrieve node
8150
+ *
8151
+ * Read one node's content and, with expand=relations, every relation on and around it. as_of reads the node as it was at that time. A node id from another organization, or one that never existed, answers ONTOLOGY_NODE_NOT_FOUND; a node you may reach but not read returns restricted true with its name only.
8152
+ */
8153
+ export const ontologyRetrieveNode = (options) => (options.client ?? client).get({
8154
+ security: [{
8155
+ key: 'ontology-bearerAuth',
8156
+ scheme: 'bearer',
8157
+ type: 'http'
8158
+ }],
8159
+ url: '/ontology/v1/nodes/{node_id}',
8160
+ ...options
8161
+ });
8162
+ /**
8163
+ * Update node
8164
+ *
8165
+ * Change a node's name, aliases or description when the mirrored record was renamed, without touching its type or identity. Send only the fields to change; omitted fields keep their current values and an explicitly null description clears it. Repeating the same edit converges on the same node, so this needs no Idempotency-Key.
8166
+ */
8167
+ export const ontologyUpdateNode = (options) => (options.client ?? client).patch({
8168
+ security: [{
8169
+ key: 'ontology-bearerAuth',
8170
+ scheme: 'bearer',
8171
+ type: 'http'
8172
+ }],
8173
+ url: '/ontology/v1/nodes/{node_id}',
8174
+ ...options,
8175
+ headers: {
8176
+ 'Content-Type': 'application/json',
8177
+ ...options.headers
8178
+ }
8179
+ });
8180
+ /**
8181
+ * Merge node
8182
+ *
8183
+ * Fold a duplicate node into the node that should survive, when two records are discovered to be the same entity. The merged node's relations and aliases move to the survivor and later reads of the duplicate resolve to it. Send an Idempotency-Key header; repeating the same key replays the first result. Reversal is a staff operation, not available here.
8184
+ */
8185
+ export const ontologyMergeNode = (options) => (options.client ?? client).post({
8186
+ security: [{
8187
+ key: 'ontology-bearerAuth',
8188
+ scheme: 'bearer',
8189
+ type: 'http'
8190
+ }],
8191
+ url: '/ontology/v1/nodes/{node_id}/merge',
8192
+ ...options,
8193
+ headers: {
8194
+ 'Content-Type': 'application/json',
8195
+ ...options.headers
8196
+ }
8197
+ });
8198
+ /**
8199
+ * List relations
8200
+ *
8201
+ * Read the facts in the graph and obtain relation ids for retrieval, invalidation or spreading. Filter by endpoint node, by type and by direction; as_of reads the relations as they were then. Invalidated relations are omitted unless include_invalid is true. limit is 1–100 and defaults to 50; follow next_cursor until it is null.
8202
+ */
8203
+ export const ontologyListRelations = (options) => (options?.client ?? client).get({
8204
+ security: [{
8205
+ key: 'ontology-bearerAuth',
8206
+ scheme: 'bearer',
8207
+ type: 'http'
8208
+ }],
8209
+ url: '/ontology/v1/relations',
8210
+ ...options
8211
+ });
8212
+ /**
8213
+ * Create relation
8214
+ *
8215
+ * Record one fact between two existing nodes, for a system mirroring a relationship it owns. type must be registered and must admit these endpoints; fact states the relationship in one sentence. Send an Idempotency-Key header; repeating the same key returns the first result instead of writing a second relation. This writes structure only — to give an agent something to remember, use POST /agent/v1/agents/{agent_id}/consolidations.
8216
+ */
8217
+ export const ontologyCreateRelation = (options) => (options.client ?? client).post({
8218
+ security: [{
8219
+ key: 'ontology-bearerAuth',
8220
+ scheme: 'bearer',
8221
+ type: 'http'
8222
+ }],
8223
+ url: '/ontology/v1/relations',
8224
+ ...options,
8225
+ headers: {
8226
+ 'Content-Type': 'application/json',
8227
+ ...options.headers
8228
+ }
8229
+ });
8230
+ /**
8231
+ * Retrieve relation
8232
+ *
8233
+ * Read one relation's fact and both of its clocks — valid_at and invalid_at for when it was true in the world, created_at and expired_at for when it was recorded and retired. An id from another organization, or one that never existed, answers ONTOLOGY_EDGE_NOT_FOUND.
8234
+ */
8235
+ export const ontologyRetrieveRelation = (options) => (options.client ?? client).get({
8236
+ security: [{
8237
+ key: 'ontology-bearerAuth',
8238
+ scheme: 'bearer',
8239
+ type: 'http'
8240
+ }],
8241
+ url: '/ontology/v1/relations/{relation_id}',
8242
+ ...options
8243
+ });
8244
+ /**
8245
+ * Invalidate relation
8246
+ *
8247
+ * Mark a relation as no longer true from a world time, when the mirrored record changed. The relation is kept — invalid_at moves and the relation still reads at an earlier as_of, so history stays answerable. Send an Idempotency-Key header; repeating the same key replays the first result. There is no delete.
8248
+ */
8249
+ export const ontologyInvalidateRelation = (options) => (options.client ?? client).post({
8250
+ security: [{
8251
+ key: 'ontology-bearerAuth',
8252
+ scheme: 'bearer',
8253
+ type: 'http'
8254
+ }],
8255
+ url: '/ontology/v1/relations/{relation_id}/invalidate',
8256
+ ...options,
8257
+ headers: {
8258
+ 'Content-Type': 'application/json',
8259
+ ...options.headers
8260
+ }
8261
+ });
8262
+ /**
8263
+ * Apply changeset
8264
+ *
8265
+ * Apply a batch of node, relation and invalidation operations as one transaction, when a mirror has several records to write together and a partial write would leave the graph inconsistent. Every operation succeeds or none is applied. Send an Idempotency-Key header; the same key with the same content replays the first result, and the same key with different content is ONTOLOGY_CONFLICT.
8266
+ */
8267
+ export const ontologyApplyChangeset = (options) => (options.client ?? client).post({
8268
+ security: [{
8269
+ key: 'ontology-bearerAuth',
8270
+ scheme: 'bearer',
8271
+ type: 'http'
8272
+ }],
8273
+ url: '/ontology/v1/changesets',
8274
+ ...options,
8275
+ headers: {
8276
+ 'Content-Type': 'application/json',
8277
+ ...options.headers
8278
+ }
8279
+ });
8280
+ /**
8281
+ * Search nodes
8282
+ *
8283
+ * Resolve text to the nodes it most likely names, when a mirror holds a name and needs the node id it corresponds to. Results are ranked candidates, not an answer, each reporting whether the match came from the node's name, an alias, its description or a relation's fact. Narrow with types, and cap the result count with limit (1–50, default 20). This reads structure; it is not an agent recall — agents recall through POST /agent/v1/agents/{agent_id}/consolidations.
8284
+ */
8285
+ export const ontologySearch = (options) => (options.client ?? client).post({
8286
+ security: [{
8287
+ key: 'ontology-bearerAuth',
8288
+ scheme: 'bearer',
8289
+ type: 'http'
8290
+ }],
8291
+ url: '/ontology/v1/search',
8292
+ ...options,
8293
+ headers: {
8294
+ 'Content-Type': 'application/json',
8295
+ ...options.headers
8296
+ }
8297
+ });
8298
+ /**
8299
+ * List sandboxes (v2)
8300
+ *
8301
+ * List your running and paused sandboxes with paging and filters. Use it to find a sandboxID before connecting to, pausing or killing a sandbox. Filter by state, template (id or alias), name, metadata (key=value pairs joined with &) and startedAfter; order sorts by start time (default newest first); limit is 1 to 100 (default 100). When more results exist the response carries an x-next-token header; send it back as nextToken for the next page. To read one sandbox use getSandbox.
8302
+ */
8303
+ export const getSandboxV1Sandboxes = (options) => (options?.client ?? client).get({
8304
+ querySerializer: { parameters: { state: { array: { explode: false } } } },
8305
+ security: [
8306
+ {
8307
+ key: 'sandbox-ApiKeyAuth',
8308
+ name: 'X-API-Key',
8309
+ type: 'apiKey'
8310
+ },
8311
+ {
8312
+ key: 'sandbox-AuthProviderBearerAuth',
8313
+ scheme: 'bearer',
8314
+ type: 'http'
8315
+ },
8316
+ {
8317
+ key: 'sandbox-AuthProviderTeamAuth',
8318
+ name: 'X-Team-ID',
8319
+ type: 'apiKey'
8320
+ },
8321
+ { name: 'X-Admin-Token', type: 'apiKey' },
8322
+ {
8323
+ key: 'sandbox-AdminTeamAuth',
8324
+ name: 'X-Team-ID',
8325
+ type: 'apiKey'
8326
+ },
8327
+ {
8328
+ key: 'sandbox-AdminJWTAuth',
8329
+ scheme: 'bearer',
8330
+ type: 'http'
8331
+ }
8332
+ ],
8333
+ url: '/sandbox/v1/sandboxes',
8334
+ ...options
8335
+ });
8336
+ /**
8337
+ * Create sandbox (v2)
8338
+ *
8339
+ * Create a sandbox from the template. All system communication with the sandbox is secured.
8340
+ */
8341
+ export const postSandboxV1Sandboxes = (options) => (options.client ?? client).post({
8342
+ security: [
8343
+ {
8344
+ key: 'sandbox-ApiKeyAuth',
8345
+ name: 'X-API-Key',
8346
+ type: 'apiKey'
8347
+ },
8348
+ {
8349
+ key: 'sandbox-AuthProviderBearerAuth',
8350
+ scheme: 'bearer',
8351
+ type: 'http'
8352
+ },
8353
+ {
8354
+ key: 'sandbox-AuthProviderTeamAuth',
8355
+ name: 'X-Team-ID',
8356
+ type: 'apiKey'
8357
+ },
8358
+ { name: 'X-Admin-Token', type: 'apiKey' },
8359
+ {
8360
+ key: 'sandbox-AdminTeamAuth',
8361
+ name: 'X-Team-ID',
8362
+ type: 'apiKey'
8363
+ },
8364
+ {
8365
+ key: 'sandbox-AdminJWTAuth',
8366
+ scheme: 'bearer',
8367
+ type: 'http'
8368
+ }
8369
+ ],
8370
+ url: '/sandbox/v1/sandboxes',
8371
+ ...options,
8372
+ headers: {
8373
+ 'Content-Type': 'application/json',
8374
+ ...options.headers
8375
+ }
8376
+ });
8377
+ /**
8378
+ * Sandbox metrics
8379
+ *
8380
+ * Read CPU, memory and disk usage samples of a sandbox over a time window. Use it to size a sandbox or find out why it is slow. start and end are Unix timestamps in seconds; without them the recent samples are returned. An unknown id answers 404.
8381
+ */
8382
+ export const getSandboxV1SandboxesBySandboxIdMetrics = (options) => (options.client ?? client).get({
8383
+ security: [
8384
+ {
8385
+ key: 'sandbox-ApiKeyAuth',
8386
+ name: 'X-API-Key',
8387
+ type: 'apiKey'
8388
+ },
8389
+ {
8390
+ key: 'sandbox-AuthProviderBearerAuth',
8391
+ scheme: 'bearer',
8392
+ type: 'http'
8393
+ },
8394
+ {
8395
+ key: 'sandbox-AuthProviderTeamAuth',
8396
+ name: 'X-Team-ID',
8397
+ type: 'apiKey'
8398
+ },
8399
+ { name: 'X-Admin-Token', type: 'apiKey' },
8400
+ {
8401
+ key: 'sandbox-AdminTeamAuth',
8402
+ name: 'X-Team-ID',
8403
+ type: 'apiKey'
8404
+ },
8405
+ {
8406
+ key: 'sandbox-AdminJWTAuth',
8407
+ scheme: 'bearer',
8408
+ type: 'http'
8409
+ }
8410
+ ],
8411
+ url: '/sandbox/v1/sandboxes/{sandboxID}/metrics',
8412
+ ...options
8413
+ });
8414
+ /**
8415
+ * Pause sandbox
8416
+ *
8417
+ * Pause a running sandbox, keeping its files and memory so that connectSandbox can resume it later. Use it to stop paying for compute without losing state; to discard the sandbox use killSandbox. Success answers 204. A sandbox that is not running answers 409.
8418
+ */
8419
+ export const postSandboxV1SandboxesBySandboxIdPause = (options) => (options.client ?? client).post({
8420
+ security: [
8421
+ {
8422
+ key: 'sandbox-ApiKeyAuth',
8423
+ name: 'X-API-Key',
8424
+ type: 'apiKey'
8425
+ },
8426
+ {
8427
+ key: 'sandbox-AuthProviderBearerAuth',
8428
+ scheme: 'bearer',
8429
+ type: 'http'
8430
+ },
8431
+ {
8432
+ key: 'sandbox-AuthProviderTeamAuth',
8433
+ name: 'X-Team-ID',
8434
+ type: 'apiKey'
8435
+ },
8436
+ { name: 'X-Admin-Token', type: 'apiKey' },
8437
+ {
8438
+ key: 'sandbox-AdminTeamAuth',
8439
+ name: 'X-Team-ID',
8440
+ type: 'apiKey'
8441
+ },
8442
+ {
8443
+ key: 'sandbox-AdminJWTAuth',
8444
+ scheme: 'bearer',
8445
+ type: 'http'
8446
+ }
8447
+ ],
8448
+ url: '/sandbox/v1/sandboxes/{sandboxID}/pause',
8449
+ ...options,
8450
+ headers: {
8451
+ 'Content-Type': 'application/json',
8452
+ ...options.headers
8453
+ }
8454
+ });
8455
+ /**
8456
+ * Set sandbox timeout
8457
+ *
8458
+ * Set the timeout for the sandbox. The sandbox will expire x seconds from the time of the request. Calling this method multiple times overwrites the TTL, each time using the current timestamp as the starting point to measure the timeout duration.
8459
+ */
8460
+ export const postSandboxV1SandboxesBySandboxIdTimeout = (options) => (options.client ?? client).post({
8461
+ security: [
8462
+ {
8463
+ key: 'sandbox-ApiKeyAuth',
8464
+ name: 'X-API-Key',
8465
+ type: 'apiKey'
8466
+ },
8467
+ {
8468
+ key: 'sandbox-AuthProviderBearerAuth',
8469
+ scheme: 'bearer',
8470
+ type: 'http'
8471
+ },
8472
+ {
8473
+ key: 'sandbox-AuthProviderTeamAuth',
8474
+ name: 'X-Team-ID',
8475
+ type: 'apiKey'
8476
+ },
8477
+ { name: 'X-Admin-Token', type: 'apiKey' },
8478
+ {
8479
+ key: 'sandbox-AdminTeamAuth',
8480
+ name: 'X-Team-ID',
8481
+ type: 'apiKey'
8482
+ },
8483
+ {
8484
+ key: 'sandbox-AdminJWTAuth',
8485
+ scheme: 'bearer',
8486
+ type: 'http'
8487
+ }
8488
+ ],
8489
+ url: '/sandbox/v1/sandboxes/{sandboxID}/timeout',
8490
+ ...options,
8491
+ headers: {
8492
+ 'Content-Type': 'application/json',
8493
+ ...options.headers
8494
+ }
8495
+ });
8496
+ /**
8497
+ * Connect sandbox (v2)
8498
+ *
8499
+ * Returns sandbox details. If the sandbox is paused, it will be resumed. TTL is only extended. The request body is optional; an omitted timeout defaults to 300 seconds.
8500
+ */
8501
+ export const postSandboxV1SandboxesBySandboxIdConnect = (options) => (options.client ?? client).post({
8502
+ security: [
8503
+ {
8504
+ key: 'sandbox-ApiKeyAuth',
8505
+ name: 'X-API-Key',
8506
+ type: 'apiKey'
8507
+ },
8508
+ {
8509
+ key: 'sandbox-AuthProviderBearerAuth',
8510
+ scheme: 'bearer',
8511
+ type: 'http'
8512
+ },
8513
+ {
8514
+ key: 'sandbox-AuthProviderTeamAuth',
8515
+ name: 'X-Team-ID',
8516
+ type: 'apiKey'
8517
+ },
8518
+ { name: 'X-Admin-Token', type: 'apiKey' },
8519
+ {
8520
+ key: 'sandbox-AdminTeamAuth',
8521
+ name: 'X-Team-ID',
8522
+ type: 'apiKey'
8523
+ },
8524
+ {
8525
+ key: 'sandbox-AdminJWTAuth',
6906
8526
  scheme: 'bearer',
6907
8527
  type: 'http'
6908
- }],
6909
- url: '/media/v1/libraries/{library_id}/assets:batch',
8528
+ }
8529
+ ],
8530
+ url: '/sandbox/v1/sandboxes/{sandboxID}/connect',
6910
8531
  ...options,
6911
8532
  headers: {
6912
8533
  'Content-Type': 'application/json',
@@ -6914,45 +8535,77 @@ export const mediaBatchAssets = (options) => (options.client ?? client).post({
6914
8535
  }
6915
8536
  });
6916
8537
  /**
6917
- * Get job alias
8538
+ * List templates (v2)
6918
8539
  *
6919
- * Alias of batch retrieval. Read the job returned by a batch request, including terminal status, successful and failed counts, and individual failure codes.
8540
+ * List official templates and all your custom templates, including waiting, building, ready and error builds. Custom templates appear first; each custom row describes its latest build, not necessarily the current ready build. Use templateID for build management and a ready template name when creating a sandbox. Own-face official distinguishes public catalog entries; sourceKind is omitted until a source is submitted and on official templates. Other organizations' templates are invisible.
6920
8541
  */
6921
- export const mediaGetJob = (options) => (options.client ?? client).get({
6922
- security: [{
6923
- key: 'media-BearerAuth',
8542
+ export const listSandboxTemplates = (options) => (options?.client ?? client).get({
8543
+ security: [
8544
+ {
8545
+ key: 'sandbox-ApiKeyAuth',
8546
+ name: 'X-API-Key',
8547
+ type: 'apiKey'
8548
+ },
8549
+ {
8550
+ key: 'sandbox-AuthProviderBearerAuth',
6924
8551
  scheme: 'bearer',
6925
8552
  type: 'http'
6926
- }],
6927
- url: '/media/v1/libraries/{library_id}/jobs/{job_id}',
6928
- ...options
6929
- });
6930
- /**
6931
- * List events
6932
- *
6933
- * Read library events in sequence order, including while the library is deleting. Page forward with asc and after_seq, or backward with desc and before_seq; never combine the two sequence cursors.
6934
- */
6935
- export const mediaListEvents = (options) => (options.client ?? client).get({
6936
- security: [{
6937
- key: 'media-BearerAuth',
8553
+ },
8554
+ {
8555
+ key: 'sandbox-AuthProviderTeamAuth',
8556
+ name: 'X-Team-ID',
8557
+ type: 'apiKey'
8558
+ },
8559
+ { name: 'X-Admin-Token', type: 'apiKey' },
8560
+ {
8561
+ key: 'sandbox-AdminTeamAuth',
8562
+ name: 'X-Team-ID',
8563
+ type: 'apiKey'
8564
+ },
8565
+ {
8566
+ key: 'sandbox-AdminJWTAuth',
6938
8567
  scheme: 'bearer',
6939
8568
  type: 'http'
6940
- }],
6941
- url: '/media/v1/libraries/{library_id}/events',
8569
+ }
8570
+ ],
8571
+ url: '/sandbox/v1/templates',
6942
8572
  ...options
6943
8573
  });
6944
8574
  /**
6945
- * Create delivery token
8575
+ * Create template (v3)
6946
8576
  *
6947
- * Issue a time-limited bearer token for originals and transformed authenticated assets in an active library. Use library_id from library creation or listing; read access is sufficient. Append token as the __cld_token__ query parameter on a matching delivery URL. The default ACL covers this library and the default lifetime is 3600 seconds; narrow acl and expires_in before sharing. Anyone holding the token can read matching paths until expires_at.
8577
+ * Reserve a waiting build before submitting its source. Reusing a name in your organization allocates a new build on the same template. Returns templateID and buildID; start it with templates.builds.update, then poll templates.builds.status.list. A name:tag suffix and tags are assigned after successful publication. Example: {"name":"my-template","cpuCount":2,"memoryMB":2048}. The own face also accepts diskGb, a positive integer defaulting to 10 GiB.
6948
8578
  */
6949
- export const mediaCreateDeliveryToken = (options) => (options.client ?? client).post({
6950
- security: [{
6951
- key: 'media-BearerAuth',
8579
+ export const requestTemplateBuild = (options) => (options.client ?? client).post({
8580
+ security: [
8581
+ {
8582
+ key: 'sandbox-ApiKeyAuth',
8583
+ name: 'X-API-Key',
8584
+ type: 'apiKey'
8585
+ },
8586
+ {
8587
+ key: 'sandbox-AuthProviderBearerAuth',
6952
8588
  scheme: 'bearer',
6953
8589
  type: 'http'
6954
- }],
6955
- url: '/media/v1/libraries/{library_id}/delivery_tokens',
8590
+ },
8591
+ {
8592
+ key: 'sandbox-AuthProviderTeamAuth',
8593
+ name: 'X-Team-ID',
8594
+ type: 'apiKey'
8595
+ },
8596
+ { name: 'X-Admin-Token', type: 'apiKey' },
8597
+ {
8598
+ key: 'sandbox-AdminTeamAuth',
8599
+ name: 'X-Team-ID',
8600
+ type: 'apiKey'
8601
+ },
8602
+ {
8603
+ key: 'sandbox-AdminJWTAuth',
8604
+ scheme: 'bearer',
8605
+ type: 'http'
8606
+ }
8607
+ ],
8608
+ url: '/sandbox/v1/templates',
6956
8609
  ...options,
6957
8610
  headers: {
6958
8611
  'Content-Type': 'application/json',
@@ -6960,12 +8613,11 @@ export const mediaCreateDeliveryToken = (options) => (options.client ?? client).
6960
8613
  }
6961
8614
  });
6962
8615
  /**
6963
- * List sandboxes (v2)
8616
+ * List team volumes
6964
8617
  *
6965
- * List your running and paused sandboxes with paging and filters. Use it to find a sandboxID before connecting to, pausing or killing a sandbox. Filter by state, template (id or alias), name, metadata (key=value pairs joined with &) and startedAfter; order sorts by start time (default newest first); limit is 1 to 100 (default 100). When more results exist the response carries an x-next-token header; send it back as nextToken for the next page. To read one sandbox use getSandbox.
8618
+ * List the volumes of your team. Use it to find a volumeID before reading or deleting a volume, or to attach a volume to a sandbox by name when you create it.
6966
8619
  */
6967
- export const getSandboxV1Sandboxes = (options) => (options?.client ?? client).get({
6968
- querySerializer: { parameters: { state: { array: { explode: false } } } },
8620
+ export const getSandboxV1Volumes = (options) => (options?.client ?? client).get({
6969
8621
  security: [
6970
8622
  {
6971
8623
  key: 'sandbox-ApiKeyAuth',
@@ -6994,15 +8646,15 @@ export const getSandboxV1Sandboxes = (options) => (options?.client ?? client).ge
6994
8646
  type: 'http'
6995
8647
  }
6996
8648
  ],
6997
- url: '/sandbox/v1/sandboxes',
8649
+ url: '/sandbox/v1/volumes',
6998
8650
  ...options
6999
8651
  });
7000
8652
  /**
7001
- * Create sandbox (v2)
8653
+ * Create team volume
7002
8654
  *
7003
- * Create a sandbox from the template. All system communication with the sandbox is secured.
8655
+ * Create a team volume: persistent storage that can be mounted into sandboxes and outlives them. Send the volume name; the response returns the volume id and name. Use getVolume to read it back and deleteVolume to remove it.
7004
8656
  */
7005
- export const postSandboxV1Sandboxes = (options) => (options.client ?? client).post({
8657
+ export const postSandboxV1Volumes = (options) => (options.client ?? client).post({
7006
8658
  security: [
7007
8659
  {
7008
8660
  key: 'sandbox-ApiKeyAuth',
@@ -7031,7 +8683,7 @@ export const postSandboxV1Sandboxes = (options) => (options.client ?? client).po
7031
8683
  type: 'http'
7032
8684
  }
7033
8685
  ],
7034
- url: '/sandbox/v1/sandboxes',
8686
+ url: '/sandbox/v1/volumes',
7035
8687
  ...options,
7036
8688
  headers: {
7037
8689
  'Content-Type': 'application/json',
@@ -7039,11 +8691,11 @@ export const postSandboxV1Sandboxes = (options) => (options.client ?? client).po
7039
8691
  }
7040
8692
  });
7041
8693
  /**
7042
- * Sandbox metrics
8694
+ * Delete team volume
7043
8695
  *
7044
- * Read CPU, memory and disk usage samples of a sandbox over a time window. Use it to size a sandbox or find out why it is slow. start and end are Unix timestamps in seconds; without them the recent samples are returned. An unknown id answers 404.
8696
+ * Delete a team volume and its data permanently. Use it only when no sandbox needs the volume any more; the data cannot be recovered. Success answers 204; an unknown id answers 404.
7045
8697
  */
7046
- export const getSandboxV1SandboxesBySandboxIdMetrics = (options) => (options.client ?? client).get({
8698
+ export const deleteSandboxV1VolumesByVolumeId = (options) => (options.client ?? client).delete({
7047
8699
  security: [
7048
8700
  {
7049
8701
  key: 'sandbox-ApiKeyAuth',
@@ -7072,15 +8724,15 @@ export const getSandboxV1SandboxesBySandboxIdMetrics = (options) => (options.cli
7072
8724
  type: 'http'
7073
8725
  }
7074
8726
  ],
7075
- url: '/sandbox/v1/sandboxes/{sandboxID}/metrics',
8727
+ url: '/sandbox/v1/volumes/{volumeID}',
7076
8728
  ...options
7077
8729
  });
7078
8730
  /**
7079
- * Pause sandbox
8731
+ * Team volume
7080
8732
  *
7081
- * Pause a running sandbox, keeping its files and memory so that connectSandbox can resume it later. Use it to stop paying for compute without losing state; to discard the sandbox use killSandbox. Success answers 204. A sandbox that is not running answers 409.
8733
+ * Read one team volume by id. Use it to confirm a volume exists and to read its name before mounting it in a sandbox. An unknown id answers 404.
7082
8734
  */
7083
- export const postSandboxV1SandboxesBySandboxIdPause = (options) => (options.client ?? client).post({
8735
+ export const getSandboxV1VolumesByVolumeId = (options) => (options.client ?? client).get({
7084
8736
  security: [
7085
8737
  {
7086
8738
  key: 'sandbox-ApiKeyAuth',
@@ -7109,19 +8761,15 @@ export const postSandboxV1SandboxesBySandboxIdPause = (options) => (options.clie
7109
8761
  type: 'http'
7110
8762
  }
7111
8763
  ],
7112
- url: '/sandbox/v1/sandboxes/{sandboxID}/pause',
7113
- ...options,
7114
- headers: {
7115
- 'Content-Type': 'application/json',
7116
- ...options.headers
7117
- }
8764
+ url: '/sandbox/v1/volumes/{volumeID}',
8765
+ ...options
7118
8766
  });
7119
8767
  /**
7120
- * Set sandbox timeout
8768
+ * Fork sandbox
7121
8769
  *
7122
- * Set the timeout for the sandbox. The sandbox will expire x seconds from the time of the request. Calling this method multiple times overwrites the TTL, each time using the current timestamp as the starting point to measure the timeout duration.
8770
+ * Fork the sandbox: checkpoint the running sandbox in place (it is briefly paused, snapshotted with its full memory state, and resumed on its node, keeping its ID and expiration untouched) and create count new sandboxes from that snapshot. Returns one result per requested fork, each carrying either the created sandbox or the error that prevented it from starting. A non-201 status means the request failed before any fork was attempted.
7123
8771
  */
7124
- export const postSandboxV1SandboxesBySandboxIdTimeout = (options) => (options.client ?? client).post({
8772
+ export const postSandboxV1SandboxesBySandboxIdFork = (options) => (options.client ?? client).post({
7125
8773
  security: [
7126
8774
  {
7127
8775
  key: 'sandbox-ApiKeyAuth',
@@ -7150,7 +8798,7 @@ export const postSandboxV1SandboxesBySandboxIdTimeout = (options) => (options.cl
7150
8798
  type: 'http'
7151
8799
  }
7152
8800
  ],
7153
- url: '/sandbox/v1/sandboxes/{sandboxID}/timeout',
8801
+ url: '/sandbox/v1/sandboxes/{sandboxID}/fork',
7154
8802
  ...options,
7155
8803
  headers: {
7156
8804
  'Content-Type': 'application/json',
@@ -7158,11 +8806,11 @@ export const postSandboxV1SandboxesBySandboxIdTimeout = (options) => (options.cl
7158
8806
  }
7159
8807
  });
7160
8808
  /**
7161
- * Connect sandbox (v2)
8809
+ * Create snapshot
7162
8810
  *
7163
- * Returns sandbox details. If the sandbox is paused, it will be resumed. TTL is only extended. The request body is optional; an omitted timeout defaults to 300 seconds.
8811
+ * Create a persistent snapshot from the sandbox's current state. Snapshots can be used to create new sandboxes and persist beyond the original sandbox's lifetime.
7164
8812
  */
7165
- export const postSandboxV1SandboxesBySandboxIdConnect = (options) => (options.client ?? client).post({
8813
+ export const postSandboxV1SandboxesBySandboxIdSnapshots = (options) => (options.client ?? client).post({
7166
8814
  security: [
7167
8815
  {
7168
8816
  key: 'sandbox-ApiKeyAuth',
@@ -7191,7 +8839,7 @@ export const postSandboxV1SandboxesBySandboxIdConnect = (options) => (options.cl
7191
8839
  type: 'http'
7192
8840
  }
7193
8841
  ],
7194
- url: '/sandbox/v1/sandboxes/{sandboxID}/connect',
8842
+ url: '/sandbox/v1/sandboxes/{sandboxID}/snapshots',
7195
8843
  ...options,
7196
8844
  headers: {
7197
8845
  'Content-Type': 'application/json',
@@ -7199,11 +8847,11 @@ export const postSandboxV1SandboxesBySandboxIdConnect = (options) => (options.cl
7199
8847
  }
7200
8848
  });
7201
8849
  /**
7202
- * List templates (v2)
8850
+ * List snapshots
7203
8851
  *
7204
- * List the templates you can create sandboxes from. Use it to pick the template id or alias for createSandbox. `base` is the default template that createSandbox uses when templateID is omitted. limit is 1 to 100 (default 100); send the cursor from the response back as nextToken to continue.
8852
+ * List the snapshots you created, one cursor page at a time. Use it to find a snapshot id before you create a sandbox from it or delete it. Filter by sandboxID (the source sandbox) or by name or snapshot id, optionally tag-qualified; limit is 1 to 100 (default 100). When more results exist send the cursor from the response back as nextToken.
7205
8853
  */
7206
- export const getSandboxV1Templates = (options) => (options?.client ?? client).get({
8854
+ export const getSandboxV1Snapshots = (options) => (options?.client ?? client).get({
7207
8855
  security: [
7208
8856
  {
7209
8857
  key: 'sandbox-ApiKeyAuth',
@@ -7232,15 +8880,15 @@ export const getSandboxV1Templates = (options) => (options?.client ?? client).ge
7232
8880
  type: 'http'
7233
8881
  }
7234
8882
  ],
7235
- url: '/sandbox/v1/templates',
8883
+ url: '/sandbox/v1/snapshots',
7236
8884
  ...options
7237
8885
  });
7238
8886
  /**
7239
- * List team volumes
8887
+ * Delete template
7240
8888
  *
7241
- * List the volumes of your team. Use it to find a volumeID before reading or deleting a volume, or to attach a volume to a sandbox by name when you create it.
8889
+ * Delete one of your snapshots. Sandboxes already created from it keep running; no new sandbox can be created from it afterwards. Success answers 204. A snapshot that does not exist or belongs to someone else answers 404.
7242
8890
  */
7243
- export const getSandboxV1Volumes = (options) => (options?.client ?? client).get({
8891
+ export const deleteSandboxV1SnapshotsBySnapshotId = (options) => (options.client ?? client).delete({
7244
8892
  security: [
7245
8893
  {
7246
8894
  key: 'sandbox-ApiKeyAuth',
@@ -7269,15 +8917,15 @@ export const getSandboxV1Volumes = (options) => (options?.client ?? client).get(
7269
8917
  type: 'http'
7270
8918
  }
7271
8919
  ],
7272
- url: '/sandbox/v1/volumes',
8920
+ url: '/sandbox/v1/snapshots/{snapshotID}',
7273
8921
  ...options
7274
8922
  });
7275
8923
  /**
7276
- * Create team volume
8924
+ * Update sandbox network
7277
8925
  *
7278
- * Create a team volume: persistent storage that can be mounted into sandboxes and outlives them. Send the volume name; the response returns the volume id and name. Use getVolume to read it back and deleteVolume to remove it.
8926
+ * Update the network configuration for a running sandbox. Replaces the current egress rules with the provided configuration. Omitting field clears it.
7279
8927
  */
7280
- export const postSandboxV1Volumes = (options) => (options.client ?? client).post({
8928
+ export const putSandboxV1SandboxesBySandboxIdNetwork = (options) => (options.client ?? client).put({
7281
8929
  security: [
7282
8930
  {
7283
8931
  key: 'sandbox-ApiKeyAuth',
@@ -7306,7 +8954,7 @@ export const postSandboxV1Volumes = (options) => (options.client ?? client).post
7306
8954
  type: 'http'
7307
8955
  }
7308
8956
  ],
7309
- url: '/sandbox/v1/volumes',
8957
+ url: '/sandbox/v1/sandboxes/{sandboxID}/network',
7310
8958
  ...options,
7311
8959
  headers: {
7312
8960
  'Content-Type': 'application/json',
@@ -7314,11 +8962,11 @@ export const postSandboxV1Volumes = (options) => (options.client ?? client).post
7314
8962
  }
7315
8963
  });
7316
8964
  /**
7317
- * Delete team volume
8965
+ * Sandbox logs (v2)
7318
8966
  *
7319
- * Delete a team volume and its data permanently. Use it only when no sandbox needs the volume any more; the data cannot be recovered. Success answers 204; an unknown id answers 404.
8967
+ * Read the log lines of a sandbox. Use it to debug what ran inside a sandbox. cursor is a start timestamp in milliseconds, direction chooses forward or backward from it, level sets the lowest level to return, search is a case-sensitive substring filter (at most 256 characters) and limit caps the count (at most 1000, default 1000). To continue, pass the timestamp of the last entry as the next cursor.
7320
8968
  */
7321
- export const deleteSandboxV1VolumesByVolumeId = (options) => (options.client ?? client).delete({
8969
+ export const getSandboxV1SandboxesBySandboxIdLogs = (options) => (options.client ?? client).get({
7322
8970
  security: [
7323
8971
  {
7324
8972
  key: 'sandbox-ApiKeyAuth',
@@ -7347,15 +8995,15 @@ export const deleteSandboxV1VolumesByVolumeId = (options) => (options.client ??
7347
8995
  type: 'http'
7348
8996
  }
7349
8997
  ],
7350
- url: '/sandbox/v1/volumes/{volumeID}',
8998
+ url: '/sandbox/v1/sandboxes/{sandboxID}/logs',
7351
8999
  ...options
7352
9000
  });
7353
9001
  /**
7354
- * Team volume
9002
+ * Start template build (v2)
7355
9003
  *
7356
- * Read one team volume by id. Use it to confirm a volume exists and to read its name before mounting it in a sandbox. An unknown id answers 404.
9004
+ * Submit source for a waiting build returned by templates.create; returns 202 after queueing, not after successful publication. Unlike E2B, COPY is rejected (use RUN curl or git clone), fromTemplate accepts official catalog names only, and plaintext registry credentials are rejected. The own face also accepts dockerfile, mutually exclusive with fromImage/fromTemplate/steps, and fromImageRegistry vault references for nonofficial images. Poll templates.builds.status.list until ready or error. Example: {"fromImage":"node:22","steps":[{"type":"RUN","args":["echo hello"]}]}.
7357
9005
  */
7358
- export const getSandboxV1VolumesByVolumeId = (options) => (options.client ?? client).get({
9006
+ export const startTemplateBuild = (options) => (options.client ?? client).post({
7359
9007
  security: [
7360
9008
  {
7361
9009
  key: 'sandbox-ApiKeyAuth',
@@ -7384,15 +9032,19 @@ export const getSandboxV1VolumesByVolumeId = (options) => (options.client ?? cli
7384
9032
  type: 'http'
7385
9033
  }
7386
9034
  ],
7387
- url: '/sandbox/v1/volumes/{volumeID}',
7388
- ...options
9035
+ url: '/sandbox/v1/templates/{templateID}/builds/{buildID}',
9036
+ ...options,
9037
+ headers: {
9038
+ 'Content-Type': 'application/json',
9039
+ ...options.headers
9040
+ }
7389
9041
  });
7390
9042
  /**
7391
- * Fork sandbox
9043
+ * Template build status
7392
9044
  *
7393
- * Fork the sandbox: checkpoint the running sandbox in place (it is briefly paused, snapshotted with its full memory state, and resumed on its node, keeping its ID and expiration untouched) and create count new sandboxes from that snapshot. Returns one result per requested fork, each carrying either the created sandbox or the error that prevented it from starting. A non-201 status means the request failed before any fork was attempted.
9045
+ * Poll a build using templateID and buildID from templates.create. waiting means source has not been submitted; building includes queued work; ready permits sandbox creation; error is terminal, with reason when available. logsOffset counts previously read log entries, starting at zero; add logEntries.length after each response. limit is 0–100, default 100. level selects one log level; offsets then count entries at that level. Drain logs until an empty page, including after a terminal status.
7394
9046
  */
7395
- export const postSandboxV1SandboxesBySandboxIdFork = (options) => (options.client ?? client).post({
9047
+ export const getTemplateBuildStatus = (options) => (options.client ?? client).get({
7396
9048
  security: [
7397
9049
  {
7398
9050
  key: 'sandbox-ApiKeyAuth',
@@ -7421,19 +9073,15 @@ export const postSandboxV1SandboxesBySandboxIdFork = (options) => (options.clien
7421
9073
  type: 'http'
7422
9074
  }
7423
9075
  ],
7424
- url: '/sandbox/v1/sandboxes/{sandboxID}/fork',
7425
- ...options,
7426
- headers: {
7427
- 'Content-Type': 'application/json',
7428
- ...options.headers
7429
- }
9076
+ url: '/sandbox/v1/templates/{templateID}/builds/{buildID}/status',
9077
+ ...options
7430
9078
  });
7431
9079
  /**
7432
- * Create snapshot
9080
+ * Delete template
7433
9081
  *
7434
- * Create a persistent snapshot from the sandbox's current state. Snapshots can be used to create new sandboxes and persist beyond the original sandbox's lifetime.
9082
+ * Permanently remove your template, its builds and tag assignments using templateID from templates.create. Active instances prevent deletion with 409; terminate them first. Unknown or other-organization IDs return 404. Snapshot IDs use snapshots.delete instead.
7435
9083
  */
7436
- export const postSandboxV1SandboxesBySandboxIdSnapshots = (options) => (options.client ?? client).post({
9084
+ export const deleteUserTemplate = (options) => (options.client ?? client).delete({
7437
9085
  security: [
7438
9086
  {
7439
9087
  key: 'sandbox-ApiKeyAuth',
@@ -7462,19 +9110,15 @@ export const postSandboxV1SandboxesBySandboxIdSnapshots = (options) => (options.
7462
9110
  type: 'http'
7463
9111
  }
7464
9112
  ],
7465
- url: '/sandbox/v1/sandboxes/{sandboxID}/snapshots',
7466
- ...options,
7467
- headers: {
7468
- 'Content-Type': 'application/json',
7469
- ...options.headers
7470
- }
9113
+ url: '/sandbox/v1/templates/{templateID}',
9114
+ ...options
7471
9115
  });
7472
9116
  /**
7473
- * List snapshots
9117
+ * List template builds
7474
9118
  *
7475
- * List the snapshots you created, one cursor page at a time. Use it to find a snapshot id before you create a sandbox from it or delete it. Filter by sandboxID (the source sandbox) or by name or snapshot id, optionally tag-qualified; limit is 1 to 100 (default 100). When more results exist send the cursor from the response back as nextToken.
9119
+ * Inspect your template and its newest builds using templateID from templates.create. Build states are waiting, building, ready or error. Use limit and the returned x-next-token header to page builds. Unknown or other-organization templates return 404.
7476
9120
  */
7477
- export const getSandboxV1Snapshots = (options) => (options?.client ?? client).get({
9121
+ export const getTemplateWithBuilds = (options) => (options.client ?? client).get({
7478
9122
  security: [
7479
9123
  {
7480
9124
  key: 'sandbox-ApiKeyAuth',
@@ -7503,15 +9147,15 @@ export const getSandboxV1Snapshots = (options) => (options?.client ?? client).ge
7503
9147
  type: 'http'
7504
9148
  }
7505
9149
  ],
7506
- url: '/sandbox/v1/snapshots',
9150
+ url: '/sandbox/v1/templates/{templateID}',
7507
9151
  ...options
7508
9152
  });
7509
9153
  /**
7510
- * Delete template
9154
+ * Delete template tags
7511
9155
  *
7512
- * Delete one of your snapshots. Sandboxes already created from it keep running; no new sandbox can be created from it afterwards. Success answers 204. A snapshot that does not exist or belongs to someone else answers 404.
9156
+ * Remove the specified tag labels from your template by name, for example {"name":"my-template","tags":["stable"]}. Builds remain available. Removing default means untagged sandbox creation no longer resolves this template. Unknown or other-organization names return 404. b<number> names are reserved read-only build aliases and cannot be assigned or deleted as tags.
7513
9157
  */
7514
- export const deleteSandboxV1SnapshotsBySnapshotId = (options) => (options.client ?? client).delete({
9158
+ export const deleteTemplateTags = (options) => (options.client ?? client).delete({
7515
9159
  security: [
7516
9160
  {
7517
9161
  key: 'sandbox-ApiKeyAuth',
@@ -7540,15 +9184,19 @@ export const deleteSandboxV1SnapshotsBySnapshotId = (options) => (options.client
7540
9184
  type: 'http'
7541
9185
  }
7542
9186
  ],
7543
- url: '/sandbox/v1/snapshots/{snapshotID}',
7544
- ...options
9187
+ url: '/sandbox/v1/templates/tags',
9188
+ ...options,
9189
+ headers: {
9190
+ 'Content-Type': 'application/json',
9191
+ ...options.headers
9192
+ }
7545
9193
  });
7546
9194
  /**
7547
- * Update sandbox network
9195
+ * Assign template tags
7548
9196
  *
7549
- * Update the network configuration for a running sandbox. Replaces the current egress rules with the provided configuration. Omitting field clears it.
9197
+ * Assign tags to the ready build selected by target in name:tag format, for example {"target":"my-template:default","tags":["stable"]}. Names belong to your organization. Tags move an existing label to this build without rebuilding. Obtain available names from templates.list and tags from templates.tags.list. b<number> names are reserved read-only build aliases and cannot be assigned or deleted as tags. target also accepts name:b<number> to select a ready build by number, for example my-template:b1.
7550
9198
  */
7551
- export const putSandboxV1SandboxesBySandboxIdNetwork = (options) => (options.client ?? client).put({
9199
+ export const assignTemplateTags = (options) => (options.client ?? client).post({
7552
9200
  security: [
7553
9201
  {
7554
9202
  key: 'sandbox-ApiKeyAuth',
@@ -7577,7 +9225,7 @@ export const putSandboxV1SandboxesBySandboxIdNetwork = (options) => (options.cli
7577
9225
  type: 'http'
7578
9226
  }
7579
9227
  ],
7580
- url: '/sandbox/v1/sandboxes/{sandboxID}/network',
9228
+ url: '/sandbox/v1/templates/tags',
7581
9229
  ...options,
7582
9230
  headers: {
7583
9231
  'Content-Type': 'application/json',
@@ -7585,11 +9233,11 @@ export const putSandboxV1SandboxesBySandboxIdNetwork = (options) => (options.cli
7585
9233
  }
7586
9234
  });
7587
9235
  /**
7588
- * Sandbox logs (v2)
9236
+ * List template tags
7589
9237
  *
7590
- * Read the log lines of a sandbox. Use it to debug what ran inside a sandbox. cursor is a start timestamp in milliseconds, direction chooses forward or backward from it, level sets the lowest level to return, search is a case-sensitive substring filter (at most 256 characters) and limit caps the count (at most 1000, default 1000). To continue, pass the timestamp of the last entry as the next cursor.
9238
+ * Read the tag-to-build assignments for your template using templateID from templates.create. Only ready builds acquire tags. Use a returned tag with the template name as name:tag when creating a sandbox or assigning additional tags. Foreign IDs return 404.
7591
9239
  */
7592
- export const getSandboxV1SandboxesBySandboxIdLogs = (options) => (options.client ?? client).get({
9240
+ export const listTemplateTags = (options) => (options.client ?? client).get({
7593
9241
  security: [
7594
9242
  {
7595
9243
  key: 'sandbox-ApiKeyAuth',
@@ -7618,7 +9266,44 @@ export const getSandboxV1SandboxesBySandboxIdLogs = (options) => (options.client
7618
9266
  type: 'http'
7619
9267
  }
7620
9268
  ],
7621
- url: '/sandbox/v1/sandboxes/{sandboxID}/logs',
9269
+ url: '/sandbox/v1/templates/{templateID}/tags',
9270
+ ...options
9271
+ });
9272
+ /**
9273
+ * Check template alias
9274
+ *
9275
+ * Resolve a name within your organization to its templateID before reading or managing builds. Use the bare template name, without a :tag suffix. Unknown and other-organization names return 404. The response public field is false for your private templates.
9276
+ */
9277
+ export const resolveTemplateAlias = (options) => (options.client ?? client).get({
9278
+ security: [
9279
+ {
9280
+ key: 'sandbox-ApiKeyAuth',
9281
+ name: 'X-API-Key',
9282
+ type: 'apiKey'
9283
+ },
9284
+ {
9285
+ key: 'sandbox-AuthProviderBearerAuth',
9286
+ scheme: 'bearer',
9287
+ type: 'http'
9288
+ },
9289
+ {
9290
+ key: 'sandbox-AuthProviderTeamAuth',
9291
+ name: 'X-Team-ID',
9292
+ type: 'apiKey'
9293
+ },
9294
+ { name: 'X-Admin-Token', type: 'apiKey' },
9295
+ {
9296
+ key: 'sandbox-AdminTeamAuth',
9297
+ name: 'X-Team-ID',
9298
+ type: 'apiKey'
9299
+ },
9300
+ {
9301
+ key: 'sandbox-AdminJWTAuth',
9302
+ scheme: 'bearer',
9303
+ type: 'http'
9304
+ }
9305
+ ],
9306
+ url: '/sandbox/v1/templates/aliases/{alias}',
7622
9307
  ...options
7623
9308
  });
7624
9309
  /**
@@ -7710,7 +9395,7 @@ export const vaultListVaults = (options) => (options?.client ?? client).get({
7710
9395
  /**
7711
9396
  * Create vault
7712
9397
  *
7713
- * Create an empty, active vault to hold credentials for your account, with a display name and optional metadata. Use its returned id as vault_id when creating secrets or OAuth authorizations. Unlike Anthropic, Agent sessions do not accept nonempty vault_ids; storing a credential or adding its ID to metadata does not enable vault-backed MCP authentication. Application vault references are also unavailable; praxis_vault_ref version bindings and secret writes with a vault source return 501, so creating a vault does not yet enable either consumer.
9398
+ * Create an empty, active vault to hold credentials for your account, with a display name and optional metadata. Use its returned id as vault_id when creating secrets or OAuth authorizations. Agent sessions and deployments accept up to 50 vault_ids and match their credentials against the session's MCP servers, so a stored static or oauth credential does serve as vault-backed MCP authentication; only environment_variable credentials are not yet placed, because the egress proxy ADR-058 §6 gives them is not built. Application vault references are also unavailable; praxis_vault_ref version bindings and secret writes with a vault source return 501, so creating a vault does not yet enable either consumer.
7714
9399
  */
7715
9400
  export const vaultCreateVault = (options) => (options.client ?? client).post({
7716
9401
  security: [{
@@ -8306,7 +9991,7 @@ export const ticketGetLabels = (options) => (options?.client ?? client).get({
8306
9991
  /**
8307
9992
  * Create or add labels
8308
9993
  *
8309
- * Create or add labels within the authenticated organization. Obtain resource identifiers from the corresponding list or create response. Writes complete synchronously; read the returned resource to observe the result. Organization owner or admin authority is required for this write; API keys without role information act as members.
9994
+ * Create or add labels within the authenticated organization. Obtain resource identifiers from the corresponding list or create response. Writes complete synchronously; read the returned resource to observe the result. Service authorization applies to the verified human subject.
8310
9995
  */
8311
9996
  export const ticketPostLabels = (options) => (options.client ?? client).post({
8312
9997
  security: [{
@@ -8328,7 +10013,7 @@ export const ticketPostLabels = (options) => (options.client ?? client).post({
8328
10013
  /**
8329
10014
  * Remove labels
8330
10015
  *
8331
- * Remove labels within the authenticated organization. Obtain resource identifiers from the corresponding list or create response. Writes complete synchronously; read the returned resource to observe the result. Organization owner or admin authority is required for this write; API keys without role information act as members.
10016
+ * Remove labels within the authenticated organization. Obtain resource identifiers from the corresponding list or create response. Writes complete synchronously; read the returned resource to observe the result. Service authorization applies to the verified human subject.
8332
10017
  */
8333
10018
  export const ticketDeleteLabelsName = (options) => (options.client ?? client).delete({
8334
10019
  security: [{
@@ -8346,7 +10031,7 @@ export const ticketDeleteLabelsName = (options) => (options.client ?? client).de
8346
10031
  /**
8347
10032
  * Update labels
8348
10033
  *
8349
- * Update labels within the authenticated organization. Obtain resource identifiers from the corresponding list or create response. Writes complete synchronously; read the returned resource to observe the result. Organization owner or admin authority is required for this write; API keys without role information act as members.
10034
+ * Update labels within the authenticated organization. Obtain resource identifiers from the corresponding list or create response. Writes complete synchronously; read the returned resource to observe the result. Service authorization applies to the verified human subject.
8350
10035
  */
8351
10036
  export const ticketPatchLabelsName = (options) => (options.client ?? client).patch({
8352
10037
  security: [{