Pular para o conteúdo

Create webhooks

Requisição

Create a new webhook

Segurança
TokenAuth
Corpoapplication/jsonobrigatório
namestringobrigatório

The webhook name.

Exemplo:"Palisade Transactions"
descriptionstring

The webhook description.

Exemplo:"A webhook used to monitor transactions"
endpointstringobrigatório

The webhook endpoint to send data to

Exemplo:"https://palisade.co/webhook"
curl -i -X POST \
  https://docs.ripple.com/_mock/pt-br/products/wallet/api-docs/palisade-api/palisade-api/v2/webhooks \
  -H 'Authorization: YOUR_API_KEY_HERE' \
  -H 'Content-Type: application/json' \
  -d '{
    "name": "Palisade Transactions",
    "description": "A webhook used to monitor transactions",
    "endpoint": "https://palisade.co/webhook"
  }'

Respostas

Corpoapplication/json
idstringobrigatório

The webhook ID.

Exemplo:"ce4918bf-a199-4ce2-85a3-d0d296855384"
createdBystringobrigatório

The ID of the user who created this webhook

Exemplo:"ce4918bf-a199-4ce2-85a3-d0d296855384"
createdAtstring, (date-time)obrigatório

The date and time the webhook was created

Exemplo:"2022-03-29T10:22:22.420Z"
updatedBystringobrigatório

The ID of the user who updated this webhook

Exemplo:"ce4918bf-a199-4ce2-85a3-d0d296855384"
updatedAtstring, (date-time)obrigatório

The date and time the webhook was updated

Exemplo:"2022-03-29T10:22:22.420Z"
namestringobrigatório

The webhook name

Exemplo:"Palisade Transactions"
descriptionstring

The webhook description

Exemplo:"A webhook used to monitor transactions"
endpointstringobrigatório

The webhook endpoint to send data to

Exemplo:"https://palisade.co/webhook"
subscriptionCountinteger, (int32)obrigatório

The number of subscriptions associated with the webhook

Exemplo:5
publicKeystringobrigatório

The public key used to verify the webhook signature

Exemplo:"MFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEpHiEkdd/ba5dU4sNCgsWrMOE6fLakHywl0OgF5aVfxkiqNh22oybRAREev7jvnwH4jqitHx79KGi6CMwiJjmaw=="
lastSuccessstring, (date-time)

The timestamp of the last successful webhook delivery

Exemplo:"2022-03-29T10:22:22.420Z"
lastFailurestring, (date-time)

The timestamp of the last failed webhook delivery

Exemplo:"2022-03-29T10:22:22.420Z"
successCountinteger, (int32)obrigatório

The number of successful webhook deliveries in the last hour

Exemplo:42
failureCountinteger, (int32)obrigatório

The number of failed webhook deliveries in the last hour

Exemplo:3
Resposta
{ "id": "ce4918bf-a199-4ce2-85a3-d0d296855384", "createdBy": "ce4918bf-a199-4ce2-85a3-d0d296855384", "createdAt": "2022-03-29T10:22:22.420Z", "updatedBy": "ce4918bf-a199-4ce2-85a3-d0d296855384", "updatedAt": "2022-03-29T10:22:22.420Z", "name": "Palisade Transactions", "description": "A webhook used to monitor transactions", "endpoint": "https://palisade.co/webhook", "subscriptionCount": 5, "publicKey": "MFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEpHiEkdd/ba5dU4sNCgsWrMOE6fLakHywl0OgF5aVfxkiqNh22oybRAREev7jvnwH4jqitHx79KGi6CMwiJjmaw==", "lastSuccess": "2022-03-29T10:22:22.420Z", "lastFailure": "2022-03-29T10:22:22.420Z", "successCount": 42, "failureCount": 3 }