## List scenarios

`GET /v1/crm-forms/scenarios`

Returns the CRM form builder scenarios — form templates for callback requests, online booking, product sales, event registration and other tasks.

## Examples

### curl — personal key

```bash
curl "https://vibecode.bitrix24.com/v1/crm-forms/scenarios" \
  -H "X-Api-Key: YOUR_API_KEY"
```

### curl — OAuth application

```bash
curl "https://vibecode.bitrix24.com/v1/crm-forms/scenarios" \
  -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/crm-forms/scenarios', {
  headers: {
    'X-Api-Key': 'YOUR_API_KEY',
  },
})

const { success, data } = await res.json()
console.log(data.map(scenario => `${scenario.id} — ${scenario.title}`))
```

### JavaScript — OAuth application

```javascript
const res = await fetch('https://vibecode.bitrix24.com/v1/crm-forms/scenarios', {
  headers: {
    'X-Api-Key': 'YOUR_APP_KEY',
    'Authorization': 'Bearer USER_SESSION_TOKEN',
  },
})

const { success, data } = await res.json()
```

## Response fields

| Field | Type | Description |
|------|-----|---------|
| `success` | boolean | Always `true` on success |
| `data` | array | All builder scenarios. No pagination |
| `data[].id` | string | Scenario ID, for example `contacts`, `callback` |
| `data[].title` | string | Scenario name |
| `data[].description` | string | Scenario description |
| `data[].categoryId` | string | Scenario category. For the list, see [Scenario categories](/docs/entities/crm-forms/scenario-categories) |
| `data[].iconUrl` | string | Path to the scenario icon relative to the Bitrix24 account root URL, for example `/bitrix/images/crm/webform/icons/contacts.svg` |
| `data[].sections` | array of string | Form settings sections that belong to the scenario, for example `fields`, `agreements`, `crm`, `design` |
| `data[].expertSections` | array of string | Extended set of form settings sections |
| `data[].defaultSection` | string | Default settings section, one of the `sections` values |
| `data[].openable` | boolean | Whether the scenario can be opened in the form builder |
| `data[].soon` | boolean | The scenario is marked as coming soon |
| `data[].actions` | array of string | Scenario actions, for example `check`, `showHelp`. An empty array if the scenario has no actions |

## Response example

Two of the 26 scenarios are shown:

```json
{
  "success": true,
  "data": [
    {
      "id": "contacts",
      "title": "Contact details",
      "description": "Get the customer's phone, email address and name",
      "categoryId": "crm",
      "iconUrl": "/bitrix/images/crm/webform/icons/contacts.svg",
      "sections": [
        "fields",
        "agreements",
        "header-and-button",
        "crm",
        "design",
        "other"
      ],
      "expertSections": [
        "fields",
        "booking-resource-auto-selection",
        "agreements",
        "crm",
        "pay-systems",
        "header-and-button",
        "spam-protection",
        "fields-rules",
        "actions",
        "default-values",
        "analytics",
        "callback",
        "design",
        "other"
      ],
      "defaultSection": "fields",
      "openable": true,
      "soon": false,
      "actions": []
    },
    {
      "id": "event_registration",
      "title": "Online events",
      "description": "Registration for an online event",
      "categoryId": "events",
      "iconUrl": "/bitrix/images/crm/webform/icons/online.svg",
      "sections": [
        "fields",
        "agreements",
        "crm",
        "header-and-button",
        "actions",
        "default-values",
        "design",
        "other"
      ],
      "expertSections": [
        "fields",
        "booking-resource-auto-selection",
        "agreements",
        "crm",
        "pay-systems",
        "header-and-button",
        "spam-protection",
        "fields-rules",
        "actions",
        "default-values",
        "analytics",
        "callback",
        "design",
        "other"
      ],
      "defaultSection": "fields",
      "openable": true,
      "soon": false,
      "actions": [
        "check"
      ]
    }
  ]
}
```

## Error response example

400 — a query parameter is passed:

```json
{
  "success": false,
  "error": {
    "code": "INVALID_PARAMS",
    "message": "Unknown query parameter"
  }
}
```

## Errors

| HTTP | Code | Description |
|------|-----|----------|
| 400 | `INVALID_PARAMS` | The endpoint accepts no query parameters |
| 403 | `BITRIX_ACCESS_DENIED` | The Bitrix24 user lacks permission to access forms |
| 403 | `BITRIX_INSUFFICIENT_SCOPE` | The Bitrix24 token lacks the required scope |
| 404 | `ENTITY_NOT_FOUND` | Bitrix24 did not find a requested entity or field descriptor. The original code is in `error.b24Code` |
| 409 | `CRM_FORM_REST_NOT_ENABLED` | The CRM form REST methods are unavailable on this Bitrix24 account. This does not mean that an individual form is missing |
| 400–599 | `CRM_FORM_*` | Rejection under form rules. The code and HTTP status are preserved. The original code is in `error.b24Code` |
| 422 | `BITRIX_ERROR` | Another Bitrix24 rejection. The reason is in `error.message`. The original code is in `error.b24Code` |
| 429 | `RATE_LIMITED` | Request rate exceeded. Follow the `Retry-After` header |
| 502 | `BITRIX_UNAVAILABLE` | Bitrix24 returned an unexpected response shape |
| 502 | `BITRIX_UNAVAILABLE` | Bitrix24 is unavailable: a server error or a dropped connection |
| 503 | `BITRIX_TIMEOUT` | Bitrix24 did not respond in time. The read can be retried |
| 401 | `MISSING_API_KEY` | The `X-Api-Key` header is missing |
| 401 | `TOKEN_MISSING` | The key has no configured Bitrix24 credentials |
| 403 | `SCOPE_DENIED` | The Vibecode API key lacks the `crm` scope |

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

## See also

- [List scenario categories](/docs/entities/crm-forms/scenario-categories)
- [Get builder configuration](/docs/entities/crm-forms/configuration)
- [Create a form](/docs/entities/crm-forms/create)
- [CRM forms](/docs/entities/crm-forms)
