Skip to content
Skip to Content
Coder Docs

Upload chat file

POST
/api/v2/chats/files

Authorization

CoderSessionToken
headerCoder-Session-Token<token>

Query Parameters

organization*string

Organization ID

Formatuuid

Header Parameters

Content-Disposition*string

Attachment disposition carrying the file name

Request Body

Raw file binary data

body*string

Response Body

Created

application/json
  1. response
id?string
Formatuuid

The samples read CODER_URL and CODER_SESSION_TOKEN: set up your environment.

curl -X POST \	"$CODER_URL/api/v2/chats/files?organization={organization}" \	-H "Coder-Session-Token: $CODER_SESSION_TOKEN" \	-H "Content-Disposition: {Content-Disposition}" \	-H "Content-Type: application/json" \	-d '"string"'
Example Response
{  "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08"}