Files

Swagger notice: Swagger 2.0 doesn't support file upload with a content-type different than application/x-www-form-urlencoded.

post/api/v2/files

Request

  • Base URL
    / (relative, and the document was published on a file host, not at the API’s origin)
  • URL
    /api/v2/files
  • Auth
    API key in header Coder-Session-Token

Headers

Content-Typestring required

Content-Type must be application/x-tar or application/zip

Request body application/x-www-form-urlencoded

filestring binary required

File to be uploaded. If using tar format, file must conform to ustar (pax may cause problems).

Response

Returns existing file if duplicate

hashstring uuid

Changes