Get group balance

POST /user/balance


Description

The method is used to retrieve the current balance of a user or group. A JWT token must be provided in the request header.


Request format

  • HTTP method: POST
  • URL: /user/balance
  • Content-Type: application/json
  • Authorization: required

Request parameters

ParameterTypeWhere passedRequiredDescription
tokenstringHeaderUser JWT token

Example request (cURL)

curl -X POST "https://api.enface.ai/user/balance" 
  -H "Content-Type: application/json" 
  -H "Authorization: Bearer jwt.temporary.token"

Response examples

Success (200 OK)
{
  "status": "ok"
}
Error (400 Bad Request)
{
  "message": "invalid schema",
  "status": "error"
}
Error (401 Unauthorized)
{
  "message": "access denied",
  "status": "error"
}
Error (404 Not Found)
{
  "message": "item with this id does not found",
  "status": "error"
}