Skip to main content
POST
/
files_upload
Upload a file in x-form encoded HTTP request
curl --request POST \
  --url https://app.timelines.ai/integrations/api/files_upload \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: multipart/form-data' \
  --form file='@example-file' \
  --form filename=somefile.jpeg \
  --form 'content_type=<string>'
{
  "status": "ok",
  "data": {
    "temporary_download_url": "http://acme.com/somefile.png",
    "uid": "90d353e6-44c1-48ff-b15b-69b7721e5450",
    "filename": "somefile.png",
    "size": 10000,
    "mimetype": "image/png",
    "uploaded_by_email": "john.doe@acme.com",
    "uploaded_at": "2023-06-18 15:19:23 +0300"
  }
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

multipart/form-data

The body of request in multipart/form-data format, containing the file content, file name and mime-type.

file
file
required

A file content in binary format.

filename
string

A filename.

Example:

"somefile.jpeg"

content_type
string

A mime-type of the file.

Response

Success

status
enum<string>
required
Available options:
ok,
error
Example:

"ok"

data
object
required