Checkliste
Zammad hat verschiedene Endpunkte für Checklisten:
INFO
Checklisten-Vorlagen enthalten ihre Elemente, während die Standard-Checkliste einen eigenen Endpunkt für Elemente hat.
Checklisten
INFO
Um Elemente der Checkliste hinzuzufügen, verwenden Sie den Endpunkt Checklisten-Elemente.
Anzeigen
Erforderliche Berechtigung: ticket.agent
GET
-Anfrage gesendet: /api/v1/checklists/{checklisten id}
Show response
// HTTP-Code 200 OK
{
"name": "Return order",
"sorted_item_ids": [
"18",
"19",
"20",
"21"
],
"updated_by_id": 3,
"created_by_id": 3,
"ticket_id": 4,
"id": 6,
"created_at": "2024-10-15T08:47:50.860Z",
"updated_at": "2024-10-15T08:50:52.698Z",
"item_ids": [
18,
19,
20,
21
]
}
Per Ticket anzeigen
Erforderliche Berechtigung: ticket.agent
GET
-Anfrage gesendet: /api/v1/checklists/by_ticket/{ticket id}
Show response
// HTTP-Code 200 OK
{
"id": 6,
"assets": {
"Checklist": {
"6": {
"name": "Return order",
"sorted_item_ids": [
"18",
"19",
"20",
"21"
],
"updated_by_id": 3,
"created_by_id": 3,
"ticket_id": 4,
"id": 6,
"created_at": "2024-10-15T08:47:50.860Z",
"updated_at": "2024-10-15T08:50:52.698Z",
"item_ids": [
18,
19,
20,
21
]
}
},
"ChecklistItem": {
"18": {
"text": "Prepare shipment",
"checked": false,
"updated_by_id": 3,
"ticket_id": null,
"created_by_id": 3,
"checklist_id": 6,
"id": 18,
"created_at": "2024-10-15T08:47:51.036Z",
"updated_at": "2024-10-15T08:47:59.717Z"
},
"19": {
"text": "Inform customer",
"checked": false,
"updated_by_id": 3,
"ticket_id": null,
"created_by_id": 3,
"checklist_id": 6,
"id": 19,
"created_at": "2024-10-15T08:48:02.042Z",
"updated_at": "2024-10-15T08:48:12.726Z"
},
"20": {
"text": "Hand over the goods to the shipping company",
"checked": false,
"updated_by_id": 3,
"ticket_id": null,
"created_by_id": 3,
"checklist_id": 6,
"id": 20,
"created_at": "2024-10-15T08:48:14.216Z",
"updated_at": "2024-10-15T08:49:10.467Z"
},
"21": {
"text": "Check whether return has arrived",
"checked": false,
"updated_by_id": 3,
"ticket_id": null,
"created_by_id": 3,
"checklist_id": 6,
"id": 21,
"created_at": "2024-10-15T08:49:12.388Z",
"updated_at": "2024-10-15T08:49:40.746Z"
}
}
}
}
Erstellen
Erforderliche Berechtigung: ticket.agent
POST
-Anfrage gesendet: /api/v1/checklists
Show request/response
{
"ticket_id": 7,
"template_id": 1
}
Aktualisierung
Erforderliche Berechtigung: ticket.agent
PATCH
-Anfrage gesendet: /api/v1/checklists/{checklisten id}
Show request/response
{
"name": "New checklist name",
"sorted_item_ids": [
"34",
"33",
"32"
]
}
Löschen
Erforderliche Berechtigung: ticket.agent
DELETE
-Anfrage gesendet: /api/v1/checklists/{checklisten id}
Show response
// HTTP-Code 200 OK
Checklisten-Elemente
Anzeigen
Erforderliche Berechtigung: ticket.agent
GET
-Anfrage gesendet: /api/v1/checklist_items/{checklist item id}
Show response
// HTTP-Code 200 OK
{
"text": "Hand over the goods to the shipping company",
"checked": false,
"updated_by_id": 3,
"ticket_id": null,
"created_by_id": 3,
"checklist_id": 6,
"id": 20,
"created_at": "2024-10-15T08:48:14.216Z",
"updated_at": "2024-10-15T08:49:10.467Z"
}
Erstellen
Erforderliche Berechtigung: ticket.agent
POST
-Anfrage gesendet: /api/v1/checklist_items
Show request/response
{
"text": "New Item via API!",
"checklist_id": 12,
"checked": false
}
Aktualisierung
Erforderliche Berechtigung: ticket.agent
PATCH
-Anfrage gesendet: /api/v1/checklist_items/{checklist item id}
Show request/response
{
"text": "Changed checklist item",
"checked": true
}
Löschen
Erforderliche Berechtigung: ticket.agent
DELETE
-Anfrage gesendet: /api/v1/checklist_items/{checklist item id}
Show response
// HTTP-Code 200 OK
Checklisten-Vorlagen
Anzeigen
Erforderliche Berechtigung: admin.checklists
oder ticket.agent
GET
-Anfrage gesendet: /api/v1/checklist_templates/{checklist template id}
Show response
{
"name": "Return order",
"active": true,
"updated_by_id": 3,
"created_by_id": 3,
"id": 28,
"sorted_item_ids": [
"18",
"19",
"20",
"21"
],
"created_at": "2024-10-15T12:43:14.642Z",
"updated_at": "2024-10-15T12:43:34.242Z",
"item_ids": [
18,
19,
20,
21
]
}
Erstellen
Erforderliche Berechtigung: admin.checklists
POST
-Anfrage gesendet: /api/v1/checklist_templates
Show request/response
{
"name": "My checklist template",
"active": true,
"items": [
"Item 1",
"Item 2",
"Item 3"
]
}
Aktualisierung
Erforderliche Berechtigung: admin.checklists
PATCH
-Anfrage gesendet: /api/v1/checklist_templates/{checklist template id}
Show request/response
{
"name": "My changed checklist template name",
"active": true,
"items": [
"Item 7",
"Item 8",
"Item 9"
]
}
Löschen
Erforderliche Berechtigung: admin.checklists
DELETE
-Anfrage gesendet: /api/v1/checklist_templates/{checklist template id}
Show response
// HTTP-Code 200 OK