# Get limits

`GET /v1/limits` · [Sandbox · coming soon]

> Base URL: Sandbox `https://sandbox.zulu.com.co/v1`
>
> Not in production yet: it arrives with this same signature. Try it in the sandbox.

Returns the workspace's limits in force: the Bre-B maximum and the online ACH caps (with today's usage), which decide a withdrawal's `method`; the FX limits and hours; and those of PSE links and Bre-B keys. Exceeding an ACH cap is not an error: the withdrawal goes `MANUAL`.

## Authentication

`Authorization: Bearer <access_token>` (401 when missing or expired) and `X-API-Key` (403 when missing or not matching).

## Responses

### 200

The limits in force.

| Field | Type | Required | Description |
| --- | --- | --- | --- |
| `transfer` | object | required | Withdrawals (`POST /v1/transfer`). |
| `transfer.breB` | object | required | Bre-B. |
| `transfer.breB.maxAmount` | number | required | Maximum per Bre-B withdrawal (COP). |
| `transfer.ach` | object | required | Online ACH. Above a cap, the withdrawal goes `MANUAL` (not an error). |
| `transfer.ach.maxAmount` | number | required | Maximum per online ACH withdrawal (COP). |
| `transfer.ach.dailyCount` | integer | required | Online ACH withdrawals per day. |
| `transfer.ach.dailyAmount` | number | required | Daily sum of online ACH withdrawals (COP). |
| `transfer.ach.usedToday` | object | required | The day's usage (Bogotá). |
| `transfer.ach.usedToday.count` | integer | required | Today's online ACH withdrawals. |
| `transfer.ach.usedToday.amount` | number | required | Today's sum (COP). |
| `transfer.manual` | object | required | Manual payment (traditional ACH). |
| `transfer.manual.cutoffTime` | string | required | Daily cutoff of manual payment (HH:MM, Bogotá, business days). pattern ^([01]\d\|2[0-3]):[0-5]\d$. |
| `fx` | object | required | Conversions (both sides must comply). |
| `fx.COP` | object | required | Limits of the COP side. |
| `fx.COP.min` | number | required | Minimum per conversion (COP). |
| `fx.COP.max` | number | required | Maximum per conversion (COP). |
| `fx.USD` | object | required | Limits of the USD side. |
| `fx.USD.min` | number | required | Minimum per conversion (USD). |
| `fx.USD.max` | number | required | Maximum per conversion (USD). |
| `fx.marketHours` | object | required | FX market hours. |
| `fx.marketHours.mode` | string | required | Simulated hours. Values: `ALWAYS_OPEN` (Always open (the sandbox default, like production's test users).), `REAL` (Real hours: Colombian business days, from `open` to `close`.). |
| `fx.marketHours.open` | string | required | Opening (HH:MM, Bogotá). pattern ^([01]\d\|2[0-3]):[0-5]\d$. |
| `fx.marketHours.close` | string | required | Closing (HH:MM, Bogotá). pattern ^([01]\d\|2[0-3]):[0-5]\d$. |
| `fx.marketHours.timezone` | string | required | Time zone. Always `"America/Bogota"`. |
| `fx.sameDayCutoff` | string | required | Last time to quote `SAME_DAY` (HH:MM, Bogotá). pattern ^([01]\d\|2[0-3]):[0-5]\d$. |
| `rechargeLinks` | object | required | PSE payment links. |
| `rechargeLinks.maxActive` | integer | required | Active links at once (`CREATED` or `AWAITING_PAYMENT`). |
| `rechargeLinks.minAmount` | number | required | Minimum amount of a link (COP). |
| `rechargeLinks.maxAmount` | number | required | Maximum amount of a link (COP). |
| `breBKeys` | object | required | Own Bre-B keys. |
| `breBKeys.max` | integer | required | Bre-B keys per workspace. |

### 401

The access token is missing, invalid or expired.

### 403

The `X-API-Key` is missing, invalid or does not match the token.

### 429

Too many requests: wait the seconds in `Retry-After`.

### 500

Internal error.

## Errors

| HTTP | error | cause | Description |
| --- | --- | --- | --- |
| 401 | — | `Unauthorized` | The `Authorization: Bearer <access_token>` header is missing, or the token is invalid or expired. |
| 403 | — | `Forbidden` | The `X-API-Key` is missing, unknown, revoked or does not belong to the credentials of the token. |
| 429 | — | `Too Many Requests` | You exceeded the request limit of your credentials. Wait the seconds in `Retry-After`. |
| 500 | `InternalServerApiError` | `[code:1] unexpected error` | Internal error. On operations that move money, check the state before retrying so the operation is not duplicated. |

## Examples

### Sandbox default limits

```bash
curl https://sandbox.zulu.com.co/v1/limits \
  -H "Authorization: Bearer $ZULU_ACCESS_TOKEN" \
  -H "X-API-Key: $ZULU_API_KEY"
```

**Response 200**

```json
{
  "transfer": {
    "breB": {
      "maxAmount": 12110000
    },
    "ach": {
      "maxAmount": 250000000,
      "dailyCount": 10000,
      "dailyAmount": 999999999999999,
      "usedToday": {
        "count": 3,
        "amount": 4500000
      }
    },
    "manual": {
      "cutoffTime": "15:30"
    }
  },
  "fx": {
    "COP": {
      "min": 4000,
      "max": 4000000000
    },
    "USD": {
      "min": 1,
      "max": 1000000
    },
    "marketHours": {
      "mode": "ALWAYS_OPEN",
      "open": "08:05",
      "close": "15:30",
      "timezone": "America/Bogota"
    },
    "sameDayCutoff": "13:00"
  },
  "rechargeLinks": {
    "maxActive": 15,
    "minAmount": 100000,
    "maxAmount": 1000000000
  },
  "breBKeys": {
    "max": 5
  }
}
```
