Skip to main content
PUT
/
rules
/
{id}
cURL
curl --request PUT \
  --url https://www.getinboxzero.com/api/v1/rules/{id} \
  --header 'API-Key: <api-key>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "name": "<string>",
  "condition": {
    "conditionalOperator": "AND",
    "aiInstructions": "<string>",
    "static": {
      "from": "<string>",
      "to": "<string>",
      "subject": "<string>"
    }
  },
  "actions": [
    {
      "type": "LABEL",
      "fields": {
        "label": "<string>",
        "to": "<string>",
        "cc": "<string>",
        "bcc": "<string>",
        "subject": "<string>",
        "content": "<string>",
        "webhookUrl": "<string>",
        "folderName": "<string>"
      },
      "delayInMinutes": 123
    }
  ],
  "runOnThreads": true
}
'
{
  "rule": {
    "id": "<string>",
    "name": "<string>",
    "enabled": true,
    "runOnThreads": true,
    "createdAt": "2023-11-07T05:31:56Z",
    "updatedAt": "2023-11-07T05:31:56Z",
    "condition": {
      "conditionalOperator": "AND",
      "aiInstructions": "<string>",
      "static": {
        "from": "<string>",
        "to": "<string>",
        "subject": "<string>"
      }
    },
    "actions": [
      {
        "type": "LABEL",
        "fields": {
          "label": "<string>",
          "to": "<string>",
          "cc": "<string>",
          "bcc": "<string>",
          "subject": "<string>",
          "content": "<string>",
          "webhookUrl": "<string>",
          "folderName": "<string>"
        },
        "delayInMinutes": 123
      }
    ]
  }
}

Authorizations

API-Key
string
header
required

Path Parameters

id
string
required

Body

application/json
name
string
required
Minimum string length: 1
condition
object
required
actions
object[]
required
Minimum array length: 1
runOnThreads
boolean
default:true

Response

200 - application/json

Successful response

rule
object
required