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

# General rules and channels

> Reads and changes the workspace's contact hours and limits and lists the available channels

# General rules and channels

The **general rules** apply to every cadence in the workspace: allowed days and hours, and how many contacts each person gets per day. The **channels** say what each contact can use and what is ready. Available only to debt-collection workspaces (see [Collection cadences](https://docs.talkover.ai/en/api-reference/portfolio/cadences.md)).

| What it does | Call |
| - | - |
| Reads the general rules | `GET /api/v1/cadences/settings` |
| Changes the general rules | `PUT /api/v1/cadences/settings` |
| Lists the channels and each one's options | `GET /api/v1/cadences/channels` |

## Change the general rules

Send the complete rules.

**allowed\_weekdays** `array` *required*

Allowed days, from 1 (Monday) to 7 (Sunday).

**window\_start** `string` *required*

Start of the allowed hours, `HH:MM`, in the workspace's timezone.

**window\_end** `string` *required*

End of the allowed hours, `HH:MM`, after the start.

**channel\_limits** `object` *required*

Contacts per person per day, per channel, 0 to 20. Example: `{"voice": 1, "whatsapp": 1}`. Adds up every band and every cadence. The webhook does not count.

**daily\_cap** `integer`

Cap of contacts per person per day across channels, 1 to 50. `null` = no cap.

**voice\_concurrency** `integer`

Simultaneous cadence calls per agent, 1 to 100. `null` = the agent's own limit.

```bash theme={null}
curl -X PUT "https://app.talkover.ai/api/v1/cadences/settings" \
  -H "Authorization: Bearer talq_your_environment_token_here" \
  -H "Content-Type: application/json" \
  -d '{"allowed_weekdays": [1,2,3,4,5,6], "window_start": "08:00", "window_end": "20:00", "channel_limits": {"voice": 1, "whatsapp": 1}, "daily_cap": null, "voice_concurrency": null}'
```

The response carries the saved rules, in the same format. An unknown channel in `channel_limits` answers `422`.

## Channels

Each channel carries:

| Field | What it is |
| - | - |
| `key` | the `channel` value in a contact: `voice`, `whatsapp`, `webhook`, `enrich`, `sms`, `email` |
| `available` | whether the channel can be published in your workspace (`sms` and `email` not yet) |
| `options` | the values accepted in the configuration: `campaign_id` and `agent_id` for `voice`; `messaging_account_id`, `template_id` and `variable_source` for `whatsapp` |
| `readiness` | what must be ready, item by item (`label`, `ok`) |
| `limit` | the per-person daily limit in force for the channel |
| `accounts` | for `whatsapp`, the connected numbers and the state of each |

> [!NOTE]
>
> Connecting or disconnecting a WhatsApp number is done on the **Cobrança › Régua › Canais** screen: Meta's sign-up runs in the browser. The API lists the numbers already connected.

## Error responses

| Status | When |
| - | - |
| `403` | the workspace is not debt collection, or a user token without permission to change |
| `422` | invalid field (`errors`), end time before start time, unknown channel |


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.