/rules/{id}Fully replaces the rule configuration. All required fields must be provided. If the rule's status is enabled, the update will set it to disabled and require a human to review and re-enable it in the Sequence app before it can be triggered again.
AuthorizationClick to expand
ApiKeyAuth Format: ApiKey <key>. Keys are scoped to an organization and carry explicit permissions.
Each key holds a list of permission entries. An entry specifies a scope and a resources
constraint. A request returns 403 if the key lacks the required scope, or if the requested
resource is outside the key's allowed list.
| Scope | Resources | Grants access to |
|---|---|---|
LIST_ACCOUNTS | none | List all accounts in the organization |
READ_ACCOUNTS | account IDs or * | Full account details and balance for a specific account |
LIST_RULES | none | List all rules in the organization |
READ_RULES | rule IDs or * | Full rule details (steps, conditions, actions) for a specific rule |
TRIGGER_RULES | rule IDs or * | Triggering rule executions |
READ_RULE_EXECUTIONS | rule IDs or * | Rule execution history - rule_id filter required |
READ_TRANSFERS | account IDs or * | Transfer history - account_id filter required |
MANUAL_TRANSFER | list of { source, target, max_amount? } sets | Creating manual transfers |
READ_CARDS | account IDs or * | Cards and card transactions - account_id filter required |
In: header
Path Parameters
id*stringThe rule ID.
Header Parameters
Idempotency-Key?stringA client-generated unique key to ensure idempotent processing. Requests with the same key within 24 hours return the original response without re-executing the operation. Recommended format: UUID v4.
X-Request-ID?stringA client-provided request identifier echoed back in the response `X-Request-ID` header and `request_id` body field. If omitted, the server generates one.
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
| Field | Type | Description |
|---|---|---|
nickname? | string | null | |
description? | string | null | |
status* | string, Value in "enabled" | "disabled" | |
+ trigger* | Trigger | |
+ steps* | array<RuleStep> |
Response Body
application/json
application/json
application/json
application/json
application/json
curl -X PUT "https://api.getsequence.io/api/v1/rules/string" \ -H "Content-Type: application/json" \ -d '{ "nickname": "Monthly savings transfer", "description": null, "status": "enabled", "trigger": { "type": "SCHEDULED", "schedule_type": "MONTHLY", "start_date": "2024-04-01T09:00:00Z", "account_id": "acc_01HABC4567" }, "steps": [ { "conditions": null, "actions": [ { "type": "fixed_amount", "amount_in_cents": 100000, "source": { "id": "acc_01HABC4567", "type": "income_source" }, "destination": { "id": "acc_01HSAV9999", "type": "pod" }, "group_index": 0, "up_to_enabled": true } ] } ] }'{
"request_id": "req_01HXYZ4444",
"data": {
"id": "rule_01HXYZ1234",
"nickname": "Monthly savings transfer",
"description": null,
"status": "enabled",
"trigger": {
"type": "SCHEDULED",
"schedule_type": "MONTHLY",
"start_date": "2024-04-01T09:00:00Z",
"account_id": "acc_01HABC4567"
},
"steps": [
{
"conditions": null,
"actions": [
{
"type": "fixed_amount",
"amount_in_cents": 100000,
"source": {
"id": "acc_01HABC4567",
"type": "income_source"
},
"destination": {
"id": "acc_01HSAV9999",
"type": "pod"
},
"group_index": 0,
"up_to_enabled": true,
"is_direct_deposit": false
}
]
}
],
"created_at": "2024-03-01T10:00:00Z",
"updated_at": "2024-04-01T09:00:00Z"
}
}{
"error": {
"code": "resource_not_found",
"message": "Rule with id 'rule_123' was not found."
}
}{
"error": {
"code": "unauthorized",
"message": "Missing or invalid API key."
}
}{
"error": {
"code": "forbidden",
"message": "This API key does not have the required permission."
}
}{
"error": {
"code": "resource_not_found",
"message": "Rule with id 'rule_123' was not found."
}
}Delete a rule DELETEv2
Soft-deletes the rule. The rule is deactivated and no longer visible in the Sequence app, but is not permanently removed from the system.
List rule executions GET
Returns rule executions for the organization, ordered by `created_at` descending. Supports filtering by status, trigger type, and date range. `rule_id` is required and must be present in the token's `READ_RULE_EXECUTIONS` resources.