About the API System

Connection

API requests are made at - https://api.highranklinks.com/api/{endpoint}/{method}

where:

  • {endpoint} - endpoint
  • {method} - method

For requests that require authorization, in the http header, you must pass - Authorization: Bearer {token}

where:

  • {token} - received during the authorization process: https://api.highranklinks.com/api/auth/login
Successful response format

Answer without data

{
    "status": "success"
}

Answer with data

{
    "status": "success",
    "response": {
        ...
    }
}
Error response format
{
    "status": "error",
    "response": {
        "code": {code},
        "name": {name},
        "message": {message},
        "params": {params}
    }
}

where:

  • {code} - error code. Errors
  • {name} - error name. Errors
  • {message} - internal error message corresponding to the error code
  • {params} - if there are parameters in the message template, they will be in the "params" object
API Specific Errors

VALIDATION_FAILURE - occurs when the input data is not validated. More

HTTP_METHOD_NOT_SUPPORTED - occurs if the request is not made by the http method that is expected

AUTHENTICATION_REQUIRED - occurs when you make a call to a method that requires authorization

ROUTE_NOT_FOUND - occurs when making a call to a non-existent route

SERVICE_UNAVAILABLE - occurs when technical work is carried out on the service