Skip to main content
POST
/
v1
/
files
Upload File
curl --request POST \
  --url https://documents.absconsulting.com/v1/files \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: multipart/form-data' \
  --form file='@example-file'
{
  "id": "<string>",
  "object": "<string>",
  "filename": "<string>",
  "url": "<string>",
  "bytes": 123,
  "created_at": 123,
  "metadata": {}
}

Authorizations

Authorization
string
header
required

Bearer token for authentication

Body

multipart/form-data
file
file
required

The File object (not file name) to be uploaded.

metadata
string | null

A set of up to 16 key-value pairs that can be attached to an object. This can be useful for storing additional information about the object in a structured format, and querying for objects. Keys are strings with a maximum length of 64 characters. Values are strings with a maximum length of 512 characters.

Response

Successful Response

id
string
required

The ID of the file.

object
string
required

The type of object.

filename
string
required

The name of the file, including the extension.

url
string
required

The URL of the file.

bytes
integer
required

The size of the file in bytes.

created_at
integer
required

The timestamp when the file was created.

metadata
Metadata · object

The metadata of the file.