Sending Batch files via API

Request

Method  Request URI
POST https://{clientEndpointId}- fane01.azurewebsites.net/api/upload/{date}/{filename}?code ={token}

 

  • You will receive your clientEndpointId after the integration meeting.
    For example: casinomagic
  • The corresponding date for the uploaded data in YYYY-MM-DD.
    For example: 2023-12-31
  • Filename - The target csv of the upload. Reusing the filename allows data to be overwritten.
    For example: spins_01.csv
  • You will receive your token after the integration meeting.
    For example: Abc123Z==
Request Headers

Content-type: multipart/form-data 

Body

Binary multipart form data.

API Response

  • HTTP status codes: 200 (Success), 401 (Authorisation failure), 500 (Internal error).
  • If the response is successful, the response body is empty.
  • If the request isn't successful, the body contains an error code and error message.

API Example

POST /api/upload/2021-01-01/spins_01.csv?code=ABC123Z== HTTP/1.1
Host: https://casinomagic-fane01.azurewebsites.net
Content-Length: 198
Content-Type: multipart/form-data; boundary=----
WebKitFormBoundary7MA4YWxkTrZu0gW
----WebKitFormBoundary7MA4YWxkTrZu0gW
Content-Disposition: form-data; name=""; filename="spins_01.csv"
Content-Type: text/csv
(data)
----WebKitFormBoundary7MA4YWxkTrZu0gW


curl --location --request POST 'https://casinomagic-
fane01.azurewebsites.net/api/upload/2021-01-
01/spins01.csv?code=ABC123Z==' \
--form '=@"/path/to/file/spins-048046c6b0cf-c000.csv"'