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

# GET /v3/account — Retrieve Account and Credit Balance

> Get your OTP.ID merchant account profile and current credit balance without exposing credentials or secrets.

Use `GET /v3/account` to retrieve safe account information for the API key you are using. This endpoint is useful for internal dashboards, credit monitoring, and alerts before sending OTP traffic.

The response never includes credentials such as your API key, password, webhook secret, or internal database IDs.

## Endpoint

```text theme={null}
GET https://api.otp.id/v3/account
```

## Request headers

| Header          | Value              | Required |
| --------------- | ------------------ | -------- |
| `Authorization` | `Bearer <api_key>` | ✅ Yes    |

## Response fields

<ResponseField name="merchant_id" type="string">
  Your public merchant ID.
</ResponseField>

<ResponseField name="name" type="string">
  The account owner or merchant name.
</ResponseField>

<ResponseField name="brand_name" type="string">
  The brand name configured for OTP messages.
</ResponseField>

<ResponseField name="brand_email" type="string">
  The brand email configured on the merchant account.
</ResponseField>

<ResponseField name="email" type="string">
  The login/contact email for the merchant account.
</ResponseField>

<ResponseField name="saldo" type="integer">
  Your remaining OTP.ID credits.
</ResponseField>

## Example

<CodeGroup>
  ```bash cURL theme={null}
  curl https://api.otp.id/v3/account \
    -H "Authorization: Bearer YOUR_API_KEY"
  ```

  ```js JavaScript theme={null}
  const response = await fetch('https://api.otp.id/v3/account', {
    headers: {
      Authorization: `Bearer ${process.env.OTPID_API_KEY}`
    }
  });

  const result = await response.json();
  console.log(result.data.saldo);
  ```
</CodeGroup>

**Success response:**

```json theme={null}
{
  "success": true,
  "data": {
    "merchant_id": "MC20260807ABCD",
    "name": "Dewa",
    "brand_name": "MyApp",
    "brand_email": "support@myapp.example",
    "email": "owner@myapp.example",
    "saldo": 250000
  },
  "error": null
}
```

## Errors

| HTTP Status | Error Code       | Description                                                      |
| ----------- | ---------------- | ---------------------------------------------------------------- |
| 401         | `UNAUTHORIZED`   | The `Authorization` header is missing or the API key is invalid. |
| 429         | `RATE_LIMITED`   | You exceeded the global API-key rate limit.                      |
| 500         | `INTERNAL_ERROR` | An unexpected server-side error occurred.                        |
