Delete Event Template
Overview
The Arianee event template deletion allows brands to remove outdated or obsolete event templates from their system.
Let's start π
URL
Required rights:
admin
orcertDelete
To delete an event template, use the /arianeeEventTemplate/:id
.
DELETE - https://{{nmpUrl}}/arianeeEventTemplate/:id
Return Payload
Status Code | Success | Description |
---|---|---|
200 | true | The event template has been updated. |
{
"_id": "67a08e452ef96f911a194989",
"deleted": false,
"metadata": {
"name": "Activation de la garantie",
"icon": "https://img.freepik.com/vecteurs-premium/vecteur-conception-modele-logo-service_20029-568.jpg"
},
"content": "{\"eventType\":\"warranty\",\"language\":\"fr-FR\",\"title\":\"Activation de la garantie\",\"description\":\"La garantie de votre produit a été activée ou mise à jour avec succès. Pour une durée de %duree%.\",\"i18n\":[],\"$schema\":\"https://cert.arianee.org/version3/ArianeeEvent-i18n.json\"}",
"attributes": [
{
"field": "%duree%",
"label": "DurΓ©e",
"freeEntry": true,
"required": true,
"type": "select",
"options": [
{
"label": "1 an",
"value": "1 an"
},
{
"label": "2 ans",
"value": "2 ans"
},
{
"label": "4 ans",
"value": "4 ans"
}
]
}
],
"__v": 0,
"id": "67a08e452ef96f911a194989"
}
Errors
Status Code | Success | Error Message |
---|---|---|
404 | false | The event template has already been deleted. |
500 | false | The event template ID may be wrong. |
{
"message": "no ressource with this id"
}
{
"stringValue": "\"67a08e452ef96f911a19498\"",
"valueType": "string",
"kind": "ObjectId",
"value": "67a08e452ef96f911a19498",
"path": "_id",
"reason": {},
"name": "CastError",
"message": "Cast to ObjectId failed for value \"67a08e452ef96f911a19498\" (type string) at path \"_id\" for model \"ArianeeEventTemplate\""
}
Updated 2 days ago