Webhook Endpoints in Cloud
In this guide, you'll learn how to manage the HTTP endpoints that receive webhook event deliveries for your organization.
What are Webhook Endpoints?#
A webhook endpoint is an HTTPS URL that receives event payloads from Medusa when certain actions occur in your organization.
Only one endpoint can be configured at a time per organization. The endpoint will receive all webhook events for the organization, regardless of which project or environment the event originated from.
Create a Webhook Endpoint#
To add a webhook endpoint to your organization:
- Make sure you're viewing the correct organization's dashboard in Cloud.
- Click on a project from the dashboard.
- Click Webhooks > Endpoints in the sidebar.
- Click Create endpoint.
- In the form that opens, fill in the following fields:
- Endpoint URL (required): The HTTPS address where events will be delivered.
- Enabled: whether the endpoint is active immediately. This is enabled by default.
- Click Create endpoint to save the endpoint.
Manage an Existing Endpoint#
Once an endpoint is created, it appears as a card on the Endpoints page.
Edit the Endpoint URL#
To update the URL of an existing endpoint:
- In the endpoint card, click the URL field and update the address.
- Click Save to apply the change.
Reveal or Copy the Signing Secret#
Medusa generates a signing secret for each endpoint. You can use the secret to verify that incoming requests are from Medusa.
To manage the signing secret:
- In the endpoint card, find the Signing Secret section. The value is hidden by default.
- Click the icon to show the secret, or click the icon to copy it to the clipboard.
Rotate the Signing Secret#
Rotating the signing secret generates a new secret and invalidates the previous one. This is useful if you suspect that the secret has been compromised or if you want to rotate it periodically for security reasons.
To rotate the signing secret:
- In the endpoint card, click the icon in the Signing Secret section.
- Confirm the action in the prompt that appears.
Medusa generates a new secret and the previous one is no longer valid.
Enable or Disable the Endpoint#
To enable or disable the endpoint without deleting it, toggle the switch in the top-right corner of the endpoint card.
If an endpoint is disabled, Medusa will not send any events to it until it is re-enabled.
Delete the Endpoint#
To delete a webhook endpoint:
- In the endpoint card, click the icon.
- Confirm the deletion in the prompt that appears.
The endpoint is removed and Medusa will stop sending events to it.