Deployments.ai Docs
Artifacts

Create a customer artifact upload

POST /v1/artifacts · SDK createArtifactUpload · CLI deployments artifact upload, deployments chat

POST
/v1/artifacts

Requires artifacts:write.

Authorization

headerAuthorizationBearer <token>

Opaque bearer credential scoped to one service account and tenant.

Header Parameters

x-deployments-environment?string

Required with a platform bearer JWT, where the three tenant headers select an environment the caller can access through active organization membership. Optional with an API key; when supplied, it must match the key's tenant.

Match^[0-7][0-9A-HJKMNP-TV-Z]{25}$
x-deployments-organization?string

Required with a platform bearer JWT, where the three tenant headers select an environment the caller can access through active organization membership. Optional with an API key; when supplied, it must match the key's tenant.

Match^[0-7][0-9A-HJKMNP-TV-Z]{25}$
x-deployments-project?string

Required with a platform bearer JWT, where the three tenant headers select an environment the caller can access through active organization membership. Optional with an API key; when supplied, it must match the key's tenant.

Match^[0-7][0-9A-HJKMNP-TV-Z]{25}$

Request Body

application/json
  1. body
byteSize*integer
Range0 < value <= 104857600
contentType*string
Match^\S[\s\S]*\S$|^\S$|^$
Length1 <= length <= 255
fileName*string
Match^\S[\s\S]*\S$|^\S$|^$
Length1 <= length <= 255
metadata?
name*string
Match^\S[\s\S]*\S$|^\S$|^$
Length1 <= length <= 255
retentionExpiresAt?string
Match^\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}\.\d{3}Z$
Formatdate-time
runId?string
Match^[0-9A-HJKMNP-TV-Za-hjkmnp-tv-z]{26}$
sha256*string
Match^[a-f0-9]{64}$
threadId?string
Match^[0-9A-HJKMNP-TV-Za-hjkmnp-tv-z]{26}$
type*string
Match^\S[\s\S]*\S$|^\S$|^$
Length1 <= length <= 100
visibility?string
Value in"organization""private"

Response Body

CreateArtifactUploadResponse

application/json
  1. response
artifact*
upload*
curl -X POST "https://example.com/v1/artifacts" \  -H "Content-Type: application/json" \  -d '{    "byteSize": 1,    "contentType": "string",    "fileName": "string",    "name": "string",    "sha256": "string",    "type": "string"  }'
{  "artifact": {    "agentDeploymentId": "string",    "artifactId": "string",    "byteSize": 0,    "contentType": "string",    "createdAt": "2019-08-24T14:15:22Z",    "fileName": "string",    "input": {      "kind": "image",      "mediaType": "image/jpeg"    },    "metadata": {      "property1": null,      "property2": null    },    "name": "string",    "object": "artifact",    "retentionExpiresAt": "2019-08-24T14:15:22Z",    "runId": "string",    "status": "available",    "threadId": "string",    "type": "string",    "updatedAt": "2019-08-24T14:15:22Z",    "version": 0,    "visibility": "organization"  },  "upload": {    "expiresAt": "2019-08-24T14:15:22Z",    "headers": {      "property1": "string",      "property2": "string"    },    "method": "PUT",    "url": "string"  }}