Summary
Import Triggers
Description
Import Triggers.
Route
PUT /operations-manager/triggers
Roles
admin
apiwrite
Parameters
DetailsExampleSchema
Name |
Type |
Required |
Description |
triggers |
array |
yes |
An array of exported Trigger documents. |
options |
object |
yes |
Optional parameters. |
Copied to Clipboard
{
"triggers": [
{
"name": "myCoolDocumentName",
"type": "endpoint",
"enabled": true,
"actionType": "automations",
"actionId": "421de94473165a7e761343a2",
"verb": "POST",
"routeName": "vZ7OkZe",
"schema": null,
"_id": "09eae3418f9bd26f83c6388e",
"description": "Some helpful information about the document",
"lastExecuted": null,
"migrationVersion": -19545204,
"createdBy": null,
"created": "1961-08-31T05:53:31.76Z",
"lastUpdatedBy": null,
"lastUpdated": "1949-10-19T18:26:59.17Z"
},
{
"name": "myCoolDocumentName",
"type": "endpoint",
"enabled": true,
"actionType": "automations",
"actionId": "b3ce1f3604fc2d241ad40cff",
"verb": "POST",
"routeName": "qImUlsbGJ8",
"_id": "f43012539ad8f68f90d1eb32",
"description": "Some helpful information about the document",
"lastExecuted": 85621311,
"migrationVersion": 4305474,
"createdBy": "do anim officia cupidatat",
"created": "1955-12-28T06:58:51.389Z",
"lastUpdatedBy": null,
"lastUpdated": "1945-11-28T07:09:37.096Z"
}
],
"options": {
"adapterMap": {
"old_name": "new_name"
}
}
}
Copied to Clipboard
{
"type": "object",
"properties": {
"triggers": {
"title": "triggers",
"type": "array",
"items": {
"title": "triggers",
"$ref": "trigger-json"
}
},
"options": {
"title": "options",
"type": "object",
"properties": {
"adapterMap": {
"type": "object",
"description": "A mapping of provenance names to be converted upon import, specified in \"old_name\": \"new_name\" format.",
"examples": [
{
"staging": "production"
},
{
"old_name": "new_name"
}
]
}
},
"additionalProperties": false
}
},
"required": [
"triggers",
"options"
],
"additionalProperties": false
}
Return
DetailsExampleSchema
Name |
Type |
Description |
createdTigger |
object |
The result of the import operation. |
Copied to Clipboard
{
"message": "Successfully imported 3 of 4 documents",
"data": [
{
"success": false,
"data": {
"name": "myCoolDocumentName",
"description": "Some helpful information about the document",
"enabled": true,
"actionType": "automations",
"actionId": "308df103ae06bf27a844dedf",
"lastExecuted": 71843574,
"migrationVersion": -2451200,
"createdBy": "Pronghorn",
"created": "1948-10-13T07:46:54.664Z",
"lastUpdatedBy": "Pronghorn",
"lastUpdated": "1953-02-11T21:40:27.187Z",
"_id": "f0a86fe62d3e62952464c1ee"
}
},
{
"success": false,
"data": {
"name": "myCoolDocumentName",
"description": "Some helpful information about the document",
"enabled": false,
"actionType": "automations",
"actionId": "01f065a73360d844f10aaed2",
"lastExecuted": null,
"migrationVersion": 7486643,
"createdBy": "Pronghorn",
"created": "2015-08-30T14:57:42.355Z",
"lastUpdatedBy": "435402c6edd8781e0049fefa",
"lastUpdated": "1948-09-18T11:09:39.429Z",
"_id": "db0910f28a4461e97bde6a2e"
}
}
]
}