Skip to content
KnockDevelopers
Magic links

List chat routing rules

Chat with a Developer
GET
/v1/chat-routing-rules

Returns your chat routing rules, the default rule first, then by name: the rules that assign the chats a chat or modal link starts. Pass a rule's chatRoutingId to POST and PATCH /v1/magic-links, or in chatRoutingIds to GET /v1/magic-links.

These are not the routing rules of GET /v1/routing-rules: those route form and workflow leads through POST /v1/route, and their routingId is never a chatRoutingId.

Authorization

ApiKeyAuth
headerx-api-key<token>

Your Knock API key. Ask your Knock account team for one: a key with the Enrichment API role to enrich and route leads and find warm intros, the Viewer role to read chats, meetings, routing rules, FAQs, analytics, magic links, meeting routing rules, marketing cards and members, the Admin, Editor or AI Manager role to change FAQs, the Admin, Editor or Partner Contributor role to create marketing cards and wrap chat links, or the Admin role to set the working hours of your members.

Query Parameters

limit?integer

Page size.

Range1 <= value <= 100
Default20
offset?integer

Number of rules to skip.

Range0 <= value
Default0

Response Body

A page of chat routing rules.

application/json
  1. response

A page of chat routing rules.

total*integer

Number of items that match the query, across all pages.

limit*integer

Page size of this page.

offset*integer

Number of items skipped before this page.

items*array<>

Chat routing rules, the default rule first, then by name.

Example Request
curl -X GET 'https://app.knock-ai.com/v1/chat-routing-rules' \  -H 'x-api-key: <YOUR_API_KEY>'
Example Response
{  "total": 1,  "limit": 50,  "offset": 0,  "items": [    {      "chatRoutingId": "3c5e7a9b-1d2f-4a6b-8c0d-2e4f6a8b0c1d",      "name": "Inbound demo requests",      "isDefault": true    }  ]}