Skip to main content

webhook

Register and manage webhook event subscriptions. 6 API commands.

All webhook commands share these flags:

FlagShortDescription
--paramsPath/query parameters as JSON
--dataRequest body as JSON
--jq-qjq expression to filter output
--dry-runPreview the request without executing

create

Register a new webhook.

shoplazza webhook create --data '<json_body>'

The request body must include address (notification URL) and topic (event name).

Example

shoplazza webhook create --data '{
"webhook": {
"topic": "orders/create",
"address": "https://example.com/hook"
}
}'

list

List all registered webhooks.

shoplazza webhook list

Example

shoplazza webhook list --format table

get

Get details of a specific webhook.

shoplazza webhook get --params '{"webhook_id":"123"}'

update

Update a webhook subscription.

shoplazza webhook update --params '{"webhook_id":"123"}' --data @webhook.json

Example

shoplazza webhook update --params '{"webhook_id":"123"}' --data '{
"webhook": {
"address": "https://example.com/webhooks/orders-v2"
}
}'

delete

Delete a webhook subscription.

shoplazza webhook delete --params '{"webhook_id":"123"}'

count

Count registered webhooks.

shoplazza webhook count