Create a webhook endpoint

POST
/v1/webhook-endpoints

The response carries the signing secret. It is shown only here and after a rotation.

Autorización

apiKey
headerAuthorizationBearer <clave>

Your secret API key, sent as Authorization: Bearer <key>. A key names its environment: psp_test_… works only against sandbox (https://api-sandbox.caibopay.app), psp_live_… only against live (https://api.caibopay.app). Keys are issued by Caibo when your account is opened; the dashboard (Developers) shows the key in use.

application/json
  1. body
description?string

A note.

event_types?array<>
url*string

An https URL on port 443 with a public address.

Formatouri

Cuerpo de la respuesta

The request was already made: the existing resource is returned.

application/json
  1. response
created_at*string

When it was created.

Formatodate-time
description?string

A note.

event_types*array<>
id*string

The id of the webhook endpoint.

Match^we_[0-9a-z]+$
previous_secret_expires_at?string

Until when the previous secret also signs.

Formatodate-time
secret?string

The signing secret. Present only when the endpoint is created or its secret rotated.

status*string

active: deliveries are sent. paused: you paused it. failing: deliveries keep failing and the endpoint is only probed.

Valor en"active""paused""failing"
url*string

The URL.

Ejemplo de solicitud
curl -X POST 'https://api-sandbox.caibopay.app/v1/webhook-endpoints' \  -H 'Content-Type: application/json' \  -d '{  "url": "http://example.com"}'
Ejemplo de respuesta
{  "created_at": "2019-08-24T14:15:22Z",  "description": "string",  "event_types": [    "beneficiary.created"  ],  "id": "string",  "previous_secret_expires_at": "2019-08-24T14:15:22Z",  "secret": "string",  "status": "active",  "url": "string"}