Skip to content

Commit

Permalink
fix(docs): Change order of how the HMAC is calculated for bots
Browse files Browse the repository at this point in the history
Signed-off-by: Marcel Müller <marcel-mueller@gmx.de>
  • Loading branch information
SystemKeeper committed Feb 14, 2024
1 parent 6eb02c5 commit 3cb7fd1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion docs/bots.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ Webhook based bots are available with the Nextcloud 27.1 compatible Nextcloud Ta
## Receiving chat messages

Messages are signed using the shared secret that is specified when installing a bot on the server.
Create a HMAC with SHA256 over the request body and the `RANDOM` header using the shared secret.
Create a HMAC with SHA256 over the `RANDOM` header and the request body using the shared secret.
Only when the `SIGNATURE` matches the request should be accepted and handled.

**Sample PHP code:**
Expand Down

0 comments on commit 3cb7fd1

Please sign in to comment.