Update a webhook

PUT

PUT https://platform-api.lia.com.br/external_api/v1/webhooks/:id

Body params

NameDescriptionRequiredType
nameName of your producttrueString
urlWebhook’s urltrueInteger
entityThe webhook entity, can be order, billing or billtrueString
eventsEvents from that webhooktrueArray
verbHttp verb used in requesttrueString

Example request

curl --location --request PUT 'https://platform-api-sandbox.lia.com.br/external_api/v1/webhooks/25daf5a4-f81f-4617-9e1d-92afaf54496e' \
--header 'Authorization: Bearer token' \
--data '{
    "url": "https://webhook.site/cd02b018-fe29-4687-9636-459e8b41a77f",
    "entity": "bill",
    "events": ["paid"],
    "name": "Black Friday 2023",
    "verb": "post"
}'

Example response

{
    "id": "25daf5a4-f81f-4617-9e1d-92afaf54496e",
    "url": "https://webhook.site/cd02b018-fe29-4687-9636-459e8b41a77f",
    "entity": "bill",
    "events": [
        "paid"
    ],
    "created_at": "2023-11-16T15:26:16.516-03:00",
    "updated_at": "2023-11-16T16:02:54.702-03:00",
    "name": "Black Friday 2023",
    "verb": "post"
}