Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improved webhook logs documentation with debugging and testing details #763

Open
wants to merge 3 commits into
base: pre-release
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
39 changes: 19 additions & 20 deletions manage/webhook/log.rst
Original file line number Diff line number Diff line change
@@ -1,35 +1,34 @@
Webhook Logs
============

Zammad provides a history of your recent webhooks.
You can find them below **Recent logs**.
Zammad provides a history of your recent webhook events, helping you monitor and debug interactions with third-party services. You can access them under **Recent Logs** in the webhook settings.

.. figure:: /images/manage/webhook/webhook-logs-and-entries.png
:alt: Webhook logs showing possible issues with third party communication
:alt: Webhook logs showing possible issues with third-party communication
:align: center
:width: 90%

If you need more details you can click on the request link in question.
Zammad will provide a modal with the following information:
Each log entry contains key details about the webhook request and response, allowing you to troubleshoot delivery issues. Clicking on a request link opens a detailed modal with the following information:

Direction
Always ``out``.
Webhook Log Details
-------------------

URL
The URL Zammad sent the request to.
- **Direction**: Always ``out``, indicating outgoing requests from Zammad.
- **URL**: The destination URL where Zammad sent the request.
- **Method**: Always ``POST``.
- **Status**: The HTTP status code received from the remote server. A successful request returns a ``2xx`` code.
- **Request**: Displays the HTTP request headers and payload that Zammad sent.
- **Response**: Shows the response headers from the remote server.
- **Created at**: The timestamp when Zammad sent the request.

Method
Always ``POST``.
### Debugging Webhook Issues

Status
Contains the HTTP status code the remote server replied with.
Should be ``2xx`` if successful.
If a webhook fails (e.g., receiving a ``4xx`` or ``5xx`` status code), check the request and response details to diagnose the issue. Common causes include incorrect URLs, authentication errors, or server-side failures.

Request
Contains the request Zammad sent (HTTP header and payload)
### Testing Webhooks

Response
Contains the remotes response header.
Before deploying webhooks in production, you can use testing tools to inspect and debug requests. If you do so, make sure to exclude any sensitive or personal data.

- **[Beeceptor](https://beeceptor.com/)**: A free tool to capture and inspect webhook requests in real time. Set up a temporary endpoint to verify payload structure and headers.
- **[Webhook.site](https://webhook.site/)**: Another useful alternative for real-time request logging and debugging.

Created at
Date and time the request was sent.