Skip to main content
PATCH
/
applications
/
{applicationId}
/
triggers
/
{triggerId}
Update a trigger in the Application
curl --request PATCH \
  --url https://local.withsutro.com/applications/{applicationId}/triggers/{triggerId} \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --header 'x-sutro-api-client: <api-key>' \
  --data '
{
  "trigger": {
    "id": "<string>",
    "type": "<unknown>",
    "eventName": "<string>",
    "payload": {}
  },
  "actionId": "<string>",
  "initialState": {},
  "validation": [
    "<string>"
  ],
  "isPublic": true
}
'

Authorizations

Authorization
string
header
required

Builder authentication and authorization

x-sutro-api-client
string
header
required

A unique identifier for the API Client making a request

Path Parameters

applicationId
string<uuid>
required
triggerId
string<uuid>
required

Body

application/json
trigger
object
required
actionId
string
required

A unique identifier for the action

initialState
object
required
validation
string[]
required

A list of validation expressions that must all resolve to true for the action to be started.

A Sutro expression

isPublic
boolean

Response

Trigger updated