POST
Upload file

Authorizations

Authorization
string
header
required

A RavChat API key: Authorization: Bearer sk-rav-...

Body

multipart/form-data
file
file
required

The file bytes.

purpose
string
required

OpenAI-style purpose, e.g. assistants.

Example:

"assistants"

project_id
string

Target project (defaults to your key's project).

path
string

Relative workspace path. Present = live project file (mutable); absent = immutable managed object.

Response

The created file object.

id
string
Example:

"file-rav-0f8ff0ae"

object
string
Example:

"file"

bytes
integer
Example:

4812

created_at
integer
Example:

1720512000

filename
string
Example:

"summary.md"

purpose
string
Example:

"assistants_output"

status
string
Example:

"processed"

project_id
string
workspace_id
string
path
string
Example:

"summary.md"

source
enum<string>

Who created the file.

Available options:
user,
assistant,
media
session_id
string