## List recurring deals

`GET /v1/recurring-deals`

Returns deal recurrence settings with filtering, sorting and field selection. Use it to review schedules and their activity.

## Parameters

| Field | Type | Required | Description |
|---|---|---|---|
| `filter` | object | No | Filter by fields from [Recurring deal fields](./fields.md).<br>[Filtering syntax](/docs/filtering). Example: `?filter[active]=false`, or a JSON string |
| `sort` | string / object / string[] | No | Sort fields. `id` sorts ascending, `-id` descending |
| `order` | object | No | Alternative to `sort`, for example `{"id":"desc"}` |
| `select` | string / string[] | No | Response fields. A comma-separated string or an array of names |
| `limit` | number | No | Selection size, default 50, maximum 5000 |
| `offset` | number | No | Offset from the start of the selection |
| `withTotal` | boolean | No | Requests the total count. With `false`, `meta.total` is still returned |

**Pagination.** The server reads multiple pages for `limit > 50`, up to 5000 records per request. Use `offset` and `meta.hasMore` to continue reading.

## Examples

### curl — personal key

```bash
curl -X GET "https://vibecode.bitrix24.com/v1/recurring-deals?filter%5Bactive%5D=false&sort=-id&select=id,active&limit=2&withTotal=false" \
  -H "X-Api-Key: YOUR_API_KEY"
```

### curl — OAuth application

```bash
curl -X GET "https://vibecode.bitrix24.com/v1/recurring-deals?filter%5Bactive%5D=false&sort=-id&select=id,active&limit=2&withTotal=false" \
  -H "X-Api-Key: YOUR_APP_KEY" \
  -H "Authorization: Bearer USER_SESSION_TOKEN"
```

### JavaScript — personal key

```javascript
const response = await fetch('https://vibecode.bitrix24.com/v1/recurring-deals?filter%5Bactive%5D=false&sort=-id&select=id,active&limit=2&withTotal=false', {
  method: 'GET',
  headers: { 'X-Api-Key': 'YOUR_API_KEY' },
})
const result = await response.json()
if (!result.success) throw new Error(result.error.message)
console.log(result.data)
```

### JavaScript — OAuth application

```javascript
const response = await fetch('https://vibecode.bitrix24.com/v1/recurring-deals?filter%5Bactive%5D=false&sort=-id&select=id,active&limit=2&withTotal=false', {
  method: 'GET',
  headers: { 'X-Api-Key': 'YOUR_APP_KEY', 'Authorization': 'Bearer USER_SESSION_TOKEN' },
})
const result = await response.json()
if (!result.success) throw new Error(result.error.message)
console.log(result.data)
```

## Response fields

| Field | Type | Description |
|---|---|---|
| `success` | boolean | Whether the request succeeded |
| `data` | object[] | Recurrence settings. See [recurring deal fields](./fields.md) |
| `meta.total` | number | Total matching settings, when returned |
| `meta.hasMore` | boolean | Whether more records are available |
| `meta.warnings` | object[] | Warnings, when returned. Unknown `select` fields can be ignored in a successful request |

## Response example

```json
{
  "success": true,
  "data": [
    {
      "id": 17,
      "active": false
    },
    {
      "id": 9,
      "active": false
    }
  ],
  "meta": {
    "total": 4,
    "hasMore": true
  }
}
```

## Error response example

400 — unknown filter field:

```json
{
  "success": false,
  "error": {
    "code": "UNKNOWN_FILTER_FIELD",
    "message": "Unknown filter field 'unknownField' for entity 'recurring-deals'. Available: id, dealId, basedId, active, nextExecution, lastExecution, counterRepeat, startDate, categoryId, isLimit, limitRepeat, limitDate"
  }
}
```

## Errors

| HTTP | Code | Description |
|---|---|---|
| 400 | `UNKNOWN_FILTER_FIELD` | The filter references an unknown field. See the error message and [field definitions](./fields.md) |
| 400 | `INVALID_FILTER_FIELD` | A field name starts with the unsupported prefix `@` or `!@` |
| 400 | `INVALID_FILTER_OPERATOR` | An unknown operator, an empty condition object, or a logical condition using `$or` or `$and` |
| 400 | `INVALID_DUPLICATE_FILTER_FIELD` | Two conditions map to the same filter condition. Supply only one |
| 400 | `INVALID_SORT_FIELD` | Sorting uses a forbidden name: `__proto__`, `constructor` or `prototype` |
| 400 | `UNKNOWN_SORT_FIELD` | Sorting references an unknown field |
| 400 | `INVALID_SORT_DIRECTION` | A sort direction is not one of the strings `asc`, `desc`, `ASC`, `DESC` or the numbers `1`, `-1` |
| 400 | `INVALID_FILTER` | `filter` is not an object or a JSON string containing an object, or two filter formats are mixed |
| 401 | `MISSING_API_KEY` | The `X-Api-Key` header is missing |
| 401 | `TOKEN_MISSING` | No Bitrix24 access tokens are configured |
| 403 | `SCOPE_DENIED` | The API key lacks the `crm` scope |
| 403 | `BITRIX_ACCESS_DENIED` | Bitrix24 denied access, including a missing required scope |
| 422 | `BITRIX_ERROR` | Bitrix24 rejected the operation or a plan restriction applies. See `error.message` |
| 503 | `BITRIX_TIMEOUT` | Bitrix24 did not respond in time. Retry after the interval in `Retry-After` |
| 502 | `BITRIX_UNAVAILABLE` | A connection to Bitrix24 could not be established |
| 429 | `RATE_LIMITED` | The request rate limit was exceeded. The effective limit is in the `x-ratelimit-limit` header. Retry after the interval in the `Retry-After` header |

For the full list of common API errors, see [Error codes](/docs/errors).

## Known specifics

The response can include settings with `active: false`. To retrieve active schedules only, filter by `active: true`.

## See also

- [Get a recurring deal](./get.md)
- [Recurring deal fields](./fields.md)
- [Search recurring deals](./search.md)
- [Aggregate recurring deals](./aggregate.md)
- [Recurring deals](../recurring-deals.md)
- [Filtering syntax](/docs/filtering)
