Documentation Index
Fetch the complete documentation index at: https://docs.waffo.ai/llms.txt
Use this file to discover all available pages before exploring further.
Update an existing webhook’s URL, subscribed events, or channel-specific secret. The channel and testMode fields are immutable — to change them, remove and re-add the webhook.
POST /v1/actions/store/update-webhook
Authentication: API Key (owner or admin role required)
Request Body
| Field | Type | Required | Description |
|---|
id | string | Yes | Webhook UUID (returned from add-webhook or GraphQL Store.storeWebhooks) |
url | string | No | Replace target URL. |
events | string[] | No | Replace subscribed event types |
secret | string | null | No | Replace channel-specific credential. Pass null to clear. |
channel is permanent for a given webhook record — to switch channel, remove and re-add. URL changes are accepted as-is; merchant ensures the new URL matches the channel.
Example Request
import { WaffoPancake } from "@waffo/pancake-ts";
const client = new WaffoPancake({
merchantId: process.env.WAFFO_MERCHANT_ID!,
privateKey: process.env.WAFFO_PRIVATE_KEY!,
});
// Add more events to an existing webhook
await client.webhooks.update({
id: "11111111-2222-3333-4444-555555555555",
events: ["order.completed", "refund.succeeded", "subscription.canceled"],
});
Success Response (200)
Returns the updated webhook entity. Identical shape to add-webhook.
Response Fields
| Field | Type | Description |
|---|
id | string | Webhook UUID |
storeId | string | Owning store UUID |
channel | string | Webhook channel (immutable) |
url | string | Target webhook URL |
events | string[] | Subscribed event types |
testMode | boolean | true for test transactions, false for production (immutable) |
secret | string | null | Channel-specific credential, null if cleared |
createdAt | string | Creation timestamp (ISO 8601) |
updatedAt | string | Last update timestamp (ISO 8601) |
Error Responses
| Status | Description |
|---|
| 400 | id not a valid UUID, events not a string array, or secret not a string/null |
| 403 | Caller is not an owner or admin of the store |
| 404 | Webhook not found |