@naturali/sdk 0.293.1 → 0.294.1

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.
package/dist/index.mjs CHANGED
@@ -3163,6 +3163,17 @@ var Evaluations = class {
3163
3163
  });
3164
3164
  }
3165
3165
  /**
3166
+ * Check an eval's probes
3167
+ *
3168
+ * Grades every probe of the eval's `criteria` with the criterion's scorers, as a run does before its first item, and reports each one without creating a run. A probe holds when the criterion's verdict on it (every scorer it binds passed) is the `passed` it declares; the report passes when every probe holds. The scorers run under the authority a run of the eval holds and are metered as a run's. An eval without `criteria` reports no probes.
3169
+ */
3170
+ static checkEvalProbes(options) {
3171
+ return (options.client ?? client).post({
3172
+ url: "/v1/projects/{project_id}/evals/{eval_id}/probes",
3173
+ ...options
3174
+ });
3175
+ }
3176
+ /**
3166
3177
  * Get an eval run
3167
3178
  *
3168
3179
  * Returns a run's status, counts, and aggregate scores
@@ -3346,6 +3357,52 @@ var Files = class {
3346
3357
  });
3347
3358
  }
3348
3359
  /**
3360
+ * Create a presigned upload URL
3361
+ *
3362
+ * Creates a short-lived, single-use presigned upload URL — the local-storage equivalent of an S3 presigned URL. The token fixes where the file lands, its byte ceiling (`max_bytes`) and, when `content_type` is given, its type. The client then uploads the file to the returned `upload_url` with no credential: as the raw body with `PUT /v1/projects/{project_id}/files/upload/{token}` (what a browser sends), or as multipart or base64 with `POST /v1/projects/{project_id}/files/upload/{token}`.
3363
+ */
3364
+ static createPresignedUrl(options) {
3365
+ return (options.client ?? client).post({
3366
+ url: "/v1/projects/{project_id}/files/presigned-url",
3367
+ ...options,
3368
+ headers: {
3369
+ "Content-Type": "application/json",
3370
+ ...options.headers
3371
+ }
3372
+ });
3373
+ }
3374
+ /**
3375
+ * Upload a file using an upload token
3376
+ *
3377
+ * Uploads file content authorized by a single-use token from `POST /v1/projects/{project_id}/files/presigned-url`. No bearer credential is required — the token is the credential. Accepts either multipart/form-data (field `file`) or JSON with a base64-encoded `content` field.
3378
+ */
3379
+ static uploadFileWithToken(options) {
3380
+ return (options.client ?? client).post({
3381
+ url: "/v1/projects/{project_id}/files/upload/{token}",
3382
+ ...options,
3383
+ headers: {
3384
+ "Content-Type": "application/json",
3385
+ ...options.headers
3386
+ }
3387
+ });
3388
+ }
3389
+ /**
3390
+ * Upload a raw file body with an upload token
3391
+ *
3392
+ * Uploads file content authorized by a single-use token from `POST /v1/projects/{project_id}/files/presigned-url`, sending the file itself as the request body, so a browser can `PUT` a `File` to the token's `upload_url` with no credential. The body is streamed to storage. It must declare its size in `Content-Length`, at most the token's `max_bytes`; when the token fixes a content type, `Content-Type` must match it. A refused upload leaves the token usable.
3393
+ */
3394
+ static putFileWithToken(options) {
3395
+ return (options.client ?? client).put({
3396
+ bodySerializer: null,
3397
+ url: "/v1/projects/{project_id}/files/upload/{token}",
3398
+ ...options,
3399
+ headers: {
3400
+ "Content-Type": "*/*",
3401
+ ...options.headers
3402
+ }
3403
+ });
3404
+ }
3405
+ /**
3349
3406
  * Delete a file
3350
3407
  *
3351
3408
  * Removes a file from the system by ID
@@ -6043,7 +6100,7 @@ var Tasks = class {
6043
6100
  /**
6044
6101
  * Update a task
6045
6102
  *
6046
- * Updates a task's payload, title, or assignee. `state` is never directly writable — move it with a transition; sending a `state` field is rejected as an unknown field (`VALIDATION_FAILED`). `payload` is shallow-merged over the existing payload (PATCH semantics): keys the request omits are preserved. The payload is caller-owned; the automation result lives in the read-only `last_result` field, which no patch can reach. The merged payload is validated against the workflow's `payload_schema`.
6103
+ * Updates a task's payload, title, assignee or metadata. `state` is never directly writable — move it with a transition; sending a `state` field is rejected as an unknown field (`VALIDATION_FAILED`). `payload` is shallow-merged over the existing payload (PATCH semantics): keys the request omits are preserved. The payload is caller-owned; the automation result lives in the read-only `last_result` field, which no patch can reach. The merged payload is validated against the workflow's `payload_schema`. `metadata`, unlike `payload`, replaces the stored bag whole.
6047
6104
  */
6048
6105
  static updateTask(options) {
6049
6106
  return (options.client ?? client).patch({
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@naturali/sdk",
3
- "version": "0.293.1",
3
+ "version": "0.294.1",
4
4
  "description": "TypeScript SDK for the naturali.ai API, generated from its OpenAPI specs",
5
5
  "keywords": [
6
6
  "naturali",
@@ -38,7 +38,7 @@
38
38
  },
39
39
  "devDependencies": {
40
40
  "@hey-api/openapi-ts": "^0.99.0",
41
- "@naturali/api": "0.293.1",
41
+ "@naturali/api": "0.294.1",
42
42
  "@ttoss/openapi-codegen": "^0.10.1",
43
43
  "@types/node": "^26.5.1",
44
44
  "tsdown": "^0.23.0",