From 0d04c6fe03c8505b0c9f2276af34f1bf36d4e45d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A9s?= Date: Sun, 1 Oct 2017 21:42:58 -0300 Subject: [PATCH] This explains the webhooks tested in #1263 --- Webhook-data.md | 60 +++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 60 insertions(+) create mode 100644 Webhook-data.md diff --git a/Webhook-data.md b/Webhook-data.md new file mode 100644 index 0000000..9784057 --- /dev/null +++ b/Webhook-data.md @@ -0,0 +1,60 @@ +# Webhook data + +When a webhook is activated it sends the related information within the POST request body. + +## Card creation + +``` +{ + text: '{{wekan-username}} added "{{card-title}}" to "{{list-name}}"\nhttp://{{wekan-host}}/b/{{board-id}}/{{board-name}}/{{card-id}}', + cardId: '{{card-id}}', + listId: '{{list-id}}', + boardId: '{{board-id}}', + user: '{{wekan-username}}', + card: '{{card-title}}', + description: 'act-createCard' +} +``` + +## Card archival + +``` +{ + text: '{{wekan-username}} archived "{{card-title}}"\nhttp://{{wekan-host}}/b/{{board-id}}/{{board-name}}/{{card-id}}', + cardId: '{{card-id}}', + listId: '{{list-id}}', + boardId: '{{board-id}}', + user: '{{wekan-username}}', + card: '{{card-title}}', + description: 'act-archivedCard' +} +``` + +## Comment creation + +``` +{ + text: '{{wekan-username}} commented on "{{card-title}}": "{{comment-body}}"\nhttp://{{wekan-host}}/b/{{board-id}}/{{board-name}}/{{card-id}}', + cardId: '{{card-id}}', + boardId: '{{board-id}}', + comment: '{{comment-body}}', + user: '{{wekan-username}}', + card: '{{card-title}}', + description: 'act-addComment' +} +``` + +## Card move + +``` +{ + text: '{{wekan-username}} moved "{{card-title}}" from "{{old-list-name}}" to "{{new-list-name}}"\nhttp://{{wekan-host}}/b/{{board-id}}/{{board-name}}/{{card-id}}', + cardId: '{{card-id}}', + listId: '{{new-list-id}}', + oldListId: '{{old-list-id}}', + boardId: '{{board-id}}', + user: '{{wekan-username}}', + card: '{{card-title}}', + description: 'act-moveCard' +} +``` \ No newline at end of file