Get state information

Get information about the state of a request to create a report file.

Input data

Endpoint

https://tracker.my.com/api/report/v1/file/get.json

Method

GET

Parameters

Name Value Description
idReportFile * Integer Unique file identifier

* - required parameters

Example query

/api/report/v1/file/get.json?idReportFile=2

Responses

Success

A 200 response (OK) indicates success. It will include file info according to status:

  • The In progress status shows the progress percentage.

    {
      "code": 200,
      "message": "Ok",
      "data": {
        "idReportFile": "2",
        "status": "In progress",
        "progress": "64%",
      }
    }
  • The Error occurred status means that the file will never be created.

    {
      "code": 200,
      "message": "Ok",
      "data": {
        "idReportFile": "2",
        "status": "Error occurred"
      }
    }
  • The Success status means that file is created. You will see file list with timestamp (the files will then be unavailable).

    {
      "code": 200,
      "message": "Ok",
      "data": {
        "idReportFile": "2",
        "status": "Success!",
        "files": [
          {
            "link": "https://rawdata.hb.bizmrg.com/report/2021.01.01/2.8e8defceaf77a773550a8a011fb74b85.xlsx",
            "timestampExpires": "1609502400"
          }
        ]
      }
    }

Errors

A 404 response indicates that the file is unavailable or could not be found.

{
  "code": 404,
  "message": "Not Found",
  "data": {
    "error": {
      "detail": "File Report request not found"
    }
  }
}

Restrictions

A 403 response indicates that the method needs authorization. Maybe you made mistakes or forgot to send authorization data.

{
  "code": 403,
  "message": "Access denied",
  "data": null
}