Inbound Routing
5 endpoints
PUT
/api/inbound/rules/{id}auth requiredUpdate an inbound routing rule
Updates an existing inbound routing rule. All fields are optional; only provided fields are changed.
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
| id | path | string | required | The ID of the routing rule. |
Request Bodyrequired
| Field | Type | Required | Description |
|---|---|---|---|
| name | string | optional | |
| priority | number | optional | |
| isEnabled | boolean | optional | |
| conditions | object[] | optional | |
| actions | object[] | optional | |
| metadata | object | optional |
Responses
200The updated routing rule.
| Field | Type | Required | Description |
|---|---|---|---|
| id | string | required | |
| name | string | required | |
| priority | any | required | |
| isEnabled | any | required | |
| conditions | any | required | |
| actions | any | required | |
| metadata | any | required | |
| createdAt | string | required | |
| updatedAt | string | required |
400Invalid request body
401Unauthorized
404Routing rule not found
500Internal server error
DELETE
/api/inbound/rules/{id}auth requiredDelete an inbound routing rule
Permanently deletes an inbound routing rule by its ID.
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
| id | path | string | required | The ID of the routing rule. |
Responses
200Deletion confirmed.
| Field | Type | Required | Description |
|---|---|---|---|
| deleted | boolean | required |
401Unauthorized
404Routing rule not found
500Internal server error
GET
/api/inbound/rulesauth requiredList inbound routing rules
Returns a paginated list of inbound routing rules for the organization.
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
| page | query | integer | optional | Page number (1-based). Defaults to 1. |
| pageSize | query | integer | optional | Number of items per page. Defaults to 25. |
Responses
200Paginated list of routing rules.
| Field | Type | Required | Description |
|---|---|---|---|
| data | object[] | required | |
| total | number | required | |
| page | number | required | |
| pageSize | number | required |
401Unauthorized
500Internal server error
POST
/api/inbound/rulesauth requiredCreate an inbound routing rule
Creates a new inbound routing rule with conditions and actions for processing incoming emails.
Request Bodyrequired
| Field | Type | Required | Description |
|---|---|---|---|
| name | string | required | |
| priority | number | optional | |
| isEnabled | boolean | optional | |
| conditions | object[] | required | |
| actions | object[] | required | |
| metadata | object | optional |
Responses
200The newly created routing rule.
| Field | Type | Required | Description |
|---|---|---|---|
| id | string | required | |
| name | string | required | |
| priority | any | required | |
| isEnabled | any | required | |
| conditions | any | required | |
| actions | any | required | |
| metadata | any | required | |
| createdAt | string | required | |
| updatedAt | string | required |
400Invalid request body
401Unauthorized
500Internal server error
POST
/api/inbound/testauth requiredTest inbound routing rules
Simulates an incoming email against all active routing rules and returns which rules would match along with their actions.
Request Bodyrequired
| Field | Type | Required | Description |
|---|---|---|---|
| from | string | required | |
| to | string | required | |
| subject | string | required | |
| body | string | optional | |
| size | number | optional | |
| headers | object | optional |
Responses
200Test results showing matched rules and evaluated count.
| Field | Type | Required | Description |
|---|---|---|---|
| matchedRules | object[] | required | |
| totalRulesEvaluated | number | required |
400Invalid request body
401Unauthorized
500Internal server error