Summary
Updates non-scheduling data for an automation
Description
Updates custom data for an automation. For scheduling data please use updateAutomationSchedule
Route
PUT /automation_catalog/automations/:id
Roles
admin
other
readonly
apiread
Parameters
DetailsExampleSchema
Name |
Type |
Required |
Description |
id |
string |
yes |
Unique id of the automation |
options |
object |
yes |
Object containing the fields to be updated |
Copied to Clipboard
{
"options": {
"gbac": {
"write": [
"ebf1484e0e058f7b4fbe78a7"
],
"read": [
"b1d0229b57b6a0bff6c8c813",
"b5884e98f5bff7240a7226e2"
]
},
"workflowId": "8e3695fe-c5bf-4286-ae83-186b3fea1c1a",
"formId": "58f3b6cfb16ed1da79bb4dcc"
}
}
Copied to Clipboard
{
"type": "object",
"properties": {
"options": {
"title": "options",
"type": "object",
"description": "Custom data stored with an automation.",
"properties": {
"formData": {
"type": "object",
"properties": {},
"required": [],
"additionalProperties": true
},
"workflowId": {
"type": "string",
"examples": [
"8e3695fe-c5bf-4286-ae83-186b3fea1c1a"
],
"format": "uuid"
},
"formId": {
"$ref": "automationDocument#/definitions/ObjectId"
},
"gbac": {
"type": "object",
"description": "Sets of group Ids that are allowed to access this automation.",
"properties": {
"write": {
"type": "array",
"description": "Group ids that have write access to the automation document.",
"items": {
"$ref": "automationDocument#/definitions/ObjectId"
}
},
"read": {
"type": "array",
"description": "Group ids that have read access to the automation document.",
"items": {
"$ref": "automationDocument#/definitions/ObjectId"
}
}
},
"required": [
"write",
"read"
]
}
},
"required": [
"gbac"
]
}
},
"required": [
"options"
],
"additionalProperties": false
}
Return
DetailsExampleSchema
Name |
Type |
Description |
document |
object |
Updated document of requested automation |
Copied to Clipboard
{
"_id": "57483983489dc36d0b1e26c1",
"name": "test",
"data": {
"gbac": {
"write": [
"5220727aaf1698d1991f36d5",
"d57678885eebe61bf55c7353",
"9b987686bc3ac57a529ddfd7"
],
"read": [
"490a38f97224cababce222d7",
"89dfcafd5bd8e8f7b944c274"
]
},
"lastUpdated": "2019-11-25T22:51:39.201Z",
"description": "amet ullamco occaecat",
"workflowId": "8e3695fe-c5bf-4286-ae83-186b3fea1c1a",
"formId": "fe63261e04043099a50ceff0"
},
"lastModifiedBy": "reprehenderit consectetur",
"lastRunAt": "2019-11-25T22:51:39.201Z",
"nextRunAt": "2019-11-25T22:51:39.201Z",
"repeatInterval": "1 day"
}