Upload a file

You can use this endpoint to attach a file to an ongoing investigation.

The following file types are supported:

  • doc
  • docx
  • xls
  • xlsx
  • jpg
  • pdf
  • png

You can upload a file size of maximum 5MB per file.

File can be uploaded via multipart/form-data. You can upload one file at a time.

Request

URL: /api/v1/investigation/:supportTicketId/file

Method: POST

Content-Type: multipart/form-data

Response

HTTP status : 201 Created

If the file is uploaded successfully, then you will receive 201 Created response from the server.

The response contains metadata about the file (called fileId) in the response body.

68b2a410-a233-4400-9dfb-e8a2831bac11

Error Scenarios

  • If you provide a file bigger than 5mb size, the API will return an error as below:
{
    "title": "Bad Input",
    "status": 400,
    "detail": "File size is too large. Please upload a file smaller than 5242880 MB.",
    "traceId": "00-5e63dd08a42e4301590ab73c75ee6c9b-4cf294d4a788d99e-00",
    "errorCode": "INV0001"
}
  • If you provide a file type other than above supported file, the API will return an error as below:
{
    "title": "Bad Input",
    "status": 400,
    "detail": "Invalid File type. Please upload a .doc, .docx, .xls, .xlsx, .jpg, .pdf, .png file",
    "traceId": "00-37da1a1379f4734f8e5b158a19efc9ba-0d6d3c4633acb594-00",
    "errorCode": "INV0002"
}
Path Params
string
required
Body Params
file
string
string
string
string
Headers
string
string
enum
Defaults to application/json;odata.metadata=minimal;odata.streaming=true
Responses

500

Internal Server Error

Language
Credentials
Bearer
JWT
URL
LoadingLoading…
Response
Click Try It! to start a request and see the response here! Or choose an example:
application/json;odata.metadata=minimal;odata.streaming=true
application/json;odata.metadata=minimal;odata.streaming=false
application/json;odata.metadata=minimal
application/json;odata.metadata=full;odata.streaming=true
application/json;odata.metadata=full;odata.streaming=false
application/json;odata.metadata=full
application/json;odata.metadata=none;odata.streaming=true
application/json;odata.metadata=none;odata.streaming=false
application/json;odata.metadata=none
application/json;odata.streaming=true
application/json;odata.streaming=false
application/json
application/json;odata.metadata=minimal;odata.streaming=true;IEEE754Compatible=false
application/json;odata.metadata=minimal;odata.streaming=true;IEEE754Compatible=true
application/json;odata.metadata=minimal;odata.streaming=false;IEEE754Compatible=false
application/json;odata.metadata=minimal;odata.streaming=false;IEEE754Compatible=true
application/json;odata.metadata=minimal;IEEE754Compatible=false
application/json;odata.metadata=minimal;IEEE754Compatible=true
application/json;odata.metadata=full;odata.streaming=true;IEEE754Compatible=false
application/json;odata.metadata=full;odata.streaming=true;IEEE754Compatible=true
application/json;odata.metadata=full;odata.streaming=false;IEEE754Compatible=false
application/json;odata.metadata=full;odata.streaming=false;IEEE754Compatible=true
application/json;odata.metadata=full;IEEE754Compatible=false
application/json;odata.metadata=full;IEEE754Compatible=true
application/json;odata.metadata=none;odata.streaming=true;IEEE754Compatible=false
application/json;odata.metadata=none;odata.streaming=true;IEEE754Compatible=true
application/json;odata.metadata=none;odata.streaming=false;IEEE754Compatible=true
application/json;odata.metadata=none;odata.streaming=false;IEEE754Compatible=false
application/json;odata.metadata=none;IEEE754Compatible=false
application/json;odata.metadata=none;IEEE754Compatible=true
application/json;odata.streaming=true;IEEE754Compatible=false
application/json;odata.streaming=true;IEEE754Compatible=true
application/json;odata.streaming=false;IEEE754Compatible=false
application/json;odata.streaming=false;IEEE754Compatible=true
application/json;IEEE754Compatible=false
application/json;IEEE754Compatible=true
text/plain
application/octet-stream
text/json