> ## Documentation Index
> Fetch the complete documentation index at: https://docs.mayar.id/llms.txt
> Use this file to discover all available pages before exploring further.

# Get Account Balance

> Endpoint where you can get your account balance

<RequestExample>
  ```bash Request Example theme={null}
  curl --request GET 'https://api.mayar.id/hl/v2/balances' \
   --header 'Authorization: Bearer Paste-Your-API-Key-Here'
  ```
</RequestExample>

<ResponseExample>
  ```json Response Example 200 theme={null}
  {
      "statusCode": 200,
      "messages": "success",
      "data": {
          "balanceActive": 0,
          "balancePending": 0,
          "balance": 0
      }
  }
  ```
</ResponseExample>

Endpoint:

<CodeGroup>
  ```Production Production theme={null}
  https://api.mayar.id/hl/v2/balances
  ```

  ```Sandbox Sandbox theme={null}
  https://api.mayar.club/hl/v2/balances
  ```
</CodeGroup>

## Authorization

<ResponseField name="Authorization" type="string" required>
  Example:

  `Authorization | Bearer Paste-Your-API-Key-Here`
</ResponseField>

## Response

Successful Response

## Main Structure (Root)

<ResponseField name="statusCode" type="integer">
  Status code returned by the API.
</ResponseField>

<ResponseField name="messages" type="string">
  Status message that describes the status code.
</ResponseField>

<ResponseField name="data" type="object">
  The account balance object.
</ResponseField>

### data Structure (Object)

<ResponseField name="data.balanceActive" type="integer">
  Active balance that can be used/withdrawn immediately.
</ResponseField>

<ResponseField name="data.balancePending" type="integer">
  Pending balance (cannot be withdrawn).
</ResponseField>

<ResponseField name="data.balance" type="integer">
  Total overall balance (Active balance + Pending balance).
</ResponseField>
