ServicesTasksHTTP APITriggers

Update trigger

PUT
/api/tasks/projects/{project_id}/task-triggers/{trigger_id}

Update trigger.

Authorization

bearerAuth
headerAuthorizationBearer <token>

Path Parameters

project_id*string
trigger_id*string
Formatuuid

Request Body

application/json
  1. body
definition*
expectedRevision*|

Response Body

Success

application/json
  1. response
checkpointSequence?||null
createdAtMicros*|
createdBy*|||||
definition*
error?string|null
nextFireAtMicros?||null
projectId*string
resources*array<>
revision*|
triggerId*string
Formatuuid
curl -X PUT 'https://api.spiraldb.dev/api/tasks/projects/string/task-triggers/497f6eca-6276-4993-bfeb-53cbbbba6f08' \  -H 'Content-Type: application/json' \  -d '{  "definition": {    "action": {      "input": null,      "taskSpecId": {        "name": "string",        "version": 0      }    },    "enabled": true,    "name": "string",    "source": {      "interval": {        "everySeconds": 0      },      "type": "interval"    }  },  "expectedRevision": "string"}'
{  "checkpointSequence": "string",  "createdAtMicros": "string",  "createdBy": {    "application": {      "applicationId": "string"    },    "type": "application"  },  "definition": {    "action": {      "input": null,      "options": {        "deadlineAtMicros": "string",        "maxAttempts": 0,        "resourceProfile": "cpu_1"      },      "taskSpecId": {        "name": "string",        "version": 0      }    },    "enabled": true,    "name": "string",    "source": {      "interval": {        "everySeconds": 0,        "startAtMicros": "string"      },      "type": "interval"    }  },  "error": "string",  "nextFireAtMicros": "string",  "projectId": "string",  "resources": [    {      "definitionVersionId": "44570abd-22cb-4285-9488-b5d477271796",      "readTarget": {        "commitOnBranch": {          "branchId": "712f308d-801e-48bc-b072-9c404734ceb7",          "commitId": "a1b223ee-0195-4e35-9b2a-72c93f345117"        },        "type": "commitOnBranch"      },      "resourceId": "026d60bb-63a8-407e-bf67-01dcfc6022e6",      "resourceVersionId": "9498cbd5-d381-4876-b1b6-8b7197891ece",      "role": "target"    }  ],  "revision": "string",  "triggerId": "b89c9c0a-30c6-475a-b185-93813e22ffcf"}