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": "manual",
"enabled": false,
"actionType": "automations",
"actionId": "412b23912d63639a99ae7f59",
"formData": {
"ip": "1.2.3.4",
"name": "myNewDevice"
},
"_id": "754a8a3bfbd40eca975ac45c",
"formId": null,
"description": "Some helpful information about the document",
"lastExecuted": null,
"migrationVersion": -6625392,
"createdBy": null,
"created": "1996-12-25T15:08:16.353Z",
"lastUpdatedBy": null,
"lastUpdated": "1990-03-12T20:33:32.46Z",
"formSchemaHash": null,
"legacyWrapper": false
},
{
"name": "myCoolDocumentName",
"type": "eventSystem",
"enabled": false,
"actionType": "automations",
"actionId": "aa07f6b80be33f439709dd19",
"source": "nisi",
"topic": "non aute id irure commodo",
"_id": "8374edaaed7955076300518a",
"description": "Some helpful information about the document",
"lastExecuted": null,
"migrationVersion": -77577335,
"legacyWrapper": true,
"createdBy": "nulla",
"created": "2018-07-11T03:02:16.647Z",
"lastUpdatedBy": "minim",
"lastUpdated": "1997-09-04T04:26:34.362Z"
},
{
"name": "myCoolDocumentName",
"type": "endpoint",
"enabled": false,
"actionType": "automations",
"actionId": "edd68018d2324d6e8d148f61",
"verb": "POST",
"routeName": "R",
"schema": null,
"_id": "e923051ed46eeb4192fe8af2",
"jst": null,
"description": "Some helpful information about the document",
"lastExecuted": 33064655,
"migrationVersion": 16936510,
"createdBy": "Ut laboris veniam in",
"created": "2003-01-07T12:57:35.982Z",
"lastUpdatedBy": "esse occaecat cupidatat in nulla",
"lastUpdated": "1989-11-14T23:16:15.047Z"
}
],
"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 created the requested item",
"data": [
{
"success": false,
"data": {
"name": "myCoolDocumentName",
"description": "Some helpful information about the document",
"enabled": false,
"actionType": "automations",
"actionId": "c714133f5f0bbc61dcc535d4",
"lastExecuted": null,
"migrationVersion": 85964620,
"createdBy": "Pronghorn",
"created": "1987-12-14T19:43:38.3Z",
"lastUpdatedBy": "581cfce3649962effbfe7cc0",
"lastUpdated": "2006-05-16T08:19:59.765Z",
"_id": "b940b6264533cf6cd476b2d8"
}
},
{
"success": true,
"data": {
"name": "myCoolDocumentName",
"description": "Some helpful information about the document",
"enabled": false,
"actionType": "automations",
"actionId": "3a382ca87bcdf01e0645e574",
"lastExecuted": 90055499,
"migrationVersion": -3963184,
"createdBy": "Pronghorn",
"created": "1957-04-12T08:13:46.332Z",
"lastUpdatedBy": "Pronghorn",
"lastUpdated": "2022-10-30T05:45:57.024Z",
"_id": "2c2d7c1ebf1d51a34545384f"
}
}
]
}