POST
/
v1
/
namespace
/
{namespaceId}
/
uploads
Create presigned URL for file upload
curl --request POST \
  --url https://api.agentset.ai/v1/namespace/{namespaceId}/uploads \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{
  "fileName": "document.pdf",
  "contentType": "application/pdf",
  "fileSize": 1024
}'
{
  "success": true,
  "data": {
    "url": "<string>",
    "key": "<string>"
  }
}

Authorizations

Authorization
string
header
required

Default authentication mechanism

Path Parameters

namespaceId
string
required

The id of the namespace (prefixed with ns_)

Examples:

"ns_123"

Body

application/json
fileName
string
required

File name

Minimum length: 1
Examples:

"document.pdf"

contentType
string
required

Content type

Examples:

"application/pdf"

fileSize
number
required

File size in bytes

Required range: 1 <= x <= 209715200
Examples:

1024

Response

Presigned URL generated successfully

success
boolean
required
data
object
required