
## Get currency

`GET /v1/currencies/:id`

Returns a currency by code (USD, EUR, …).

## Path parameters

| Parameter | Type | Description |
|----------|-----|---------|
| `id` | string | Currency code (USD, EUR, …) |

## Examples

### curl — personal key

```bash
curl "https://vibecode.bitrix24.com/v1/currencies/USD" \
  -H "X-Api-Key: YOUR_API_KEY"
```

### curl — OAuth application

```bash
curl "https://vibecode.bitrix24.com/v1/currencies/USD" \
  -H "X-Api-Key: YOUR_APP_KEY" \
  -H "Authorization: Bearer USER_SESSION_TOKEN"
```

### JavaScript — personal key

```javascript
const res = await fetch('https://vibecode.bitrix24.com/v1/currencies/USD', {
  headers: { 'X-Api-Key': 'YOUR_API_KEY' },
})
const { success, data } = await res.json()
```

### JavaScript — OAuth application

```javascript
const res = await fetch('https://vibecode.bitrix24.com/v1/currencies/USD', {
  headers: {
    'X-Api-Key': 'YOUR_APP_KEY',
    'Authorization': 'Bearer USER_SESSION_TOKEN',
  },
})
const { success, data } = await res.json()
```

## Response fields

| Field | Type | Description |
|------|-----|---------|
| `id` | string | Currency code (USD, EUR, …) |
| `amountCnt` | number | Number of units for the rate |
| `amount` | number | Exchange rate |
| `sort` | number | Sort order |
| `base` | boolean | Base currency |
| `fullName` | string | Name (US Dollar, $) |
| `lid` | string | ID of the site the currency is bound to |
| `formatString` | string | Display format |
| `decPoint` | string | Decimal separator |
| `thousandsSep` | string | Thousands separator |
| `decimals` | number | Decimal places |
| `dateUpdate` | datetime | Date of the last update |

## Response example

```json
{
  "success": true,
  "data": {
    "id": "USD",
    "fullName": "US Dollar",
    "amount": 92.5,
    "amountCnt": 1,
    "base": false,
    "sort": 200,
    "lid": "en",
    "formatString": "$#",
    "decimals": 2,
    "decPoint": ".",
    "thousandsSep": ",",
    "dateUpdate": "2024-11-12T07:20:08.000Z"
  }
}
```


## Error response example

```json
{
  "success": false,
  "error": { "code": "ENTITY_NOT_FOUND", "message": "Not found" }
}
```

## Errors

| HTTP | Code | Description |
|------|-----|---------|
| 404 | `ENTITY_NOT_FOUND` | Currency not found |
| 403 | `SCOPE_DENIED` | API key does not have the `crm` scope |
| 401 | `TOKEN_MISSING` | No API key provided |

Full list of errors — [Errors](/docs/errors).

## See also

- [List currencies](/docs/entities/currencies/list) — all Bitrix24 account currencies
- [Update currency](/docs/entities/currencies/update) — change the rate
- [Currencies](/docs/entities/currencies) — entity overview
