Pular para o conteúdo principal
PATCH
Atualizar webhook

Autorizações

Authorization
string
header
obrigatório

Chave secreta da conta: Authorization: Bearer sk_test_… ou sk_live_…. Use só no servidor.

Cabeçalhos

Idempotency-Key
string

Chave única por operação (um UUID serve). Repetir com a mesma chave devolve a resposta original.

Parâmetros de caminho

endpointID
string
obrigatório
Pattern: ^we_[0-9A-Za-z]{22}$
Exemplo:

"we_3Tz8yU1oI4pA7sD0fG2hJk"

Corpo

application/json
isActive
boolean

true liga, false desliga. Desligado, o endpoint não recebe entregas.

events
enum<string>[]

A nova lista de eventos. Pelo menos um.

Minimum array length: 1
Opções disponíveis:
checkout.session.created,
checkout.session.completed,
checkout.session.expired,
customer.created,
customer.converted,
invoice.finalized,
invoice.sent,
invoice.paid,
invoice.voided,
invoice.uncollectible,
invoice.auto_collection_failed,
payment.confirmed,
payment.failed,
payment.refunded,
payment.refund_reversed,
payment.chargeback,
payment.chargeback_reversed,
plan.changed,
usage.threshold_reached,
credit.balance_low,
credit.balance_depleted,
subscription.cancel_scheduled,
subscription.cancel_unscheduled,
subscription.canceled,
subscription.past_due,
refund_request.created,
payment.duplicate_detected,
payment.duplicate_refunded,
refund_request.declined
active
boolean
obsoleto

Grafia antiga de isActive, ainda aceita.

Resposta

O endpoint atualizado.

id
string
obrigatório
Pattern: ^we_[0-9A-Za-z]{22}$
Exemplo:

"we_3Tz8yU1oI4pA7sD0fG2hJk"

url
string<uri>
obrigatório

URL que recebe as entregas.

events
string[]
obrigatório

Eventos assinados. Qualquer evento emitido pode ser assinado pelo nome, inclusive os que ainda não têm payload documentado.

isActive
boolean
obrigatório

Se o endpoint está recebendo entregas.

createdAt
string<date-time>
obrigatório