v1

latestOpenAPI 3.1.02026-07-24170121.2 MB

Add Webhooks

post/v1/webhooks

Headers

Acceptstring required

Indicates which content types, expressed as MIME types, the client is able to understand.

Content-Typestring required

Indicates the media type of the resource sent in the HTTP message body. <br /><br /><b>Possible Values:</b><br /> application/json<br />application/x-www-form-urlencoded

Request body

event_typesstring[] required

Event that will trigger the web hook. One of those values: invoice.created, charge.created, subscription.created, subscription.updated, plan.created, plan.updated, plan.deleted, discount.created, discount.deleted, customer.created, customer.updated, customer.deleted, customer.card.added, customer.card.updated, customer.card.deleted, dispute.created, dispute.updated, refund.created, token.created, charge.captured charge.voided, subscription.cancelled, invoice.charge.success, invoice.charge.failed, dispute.won, dispute.lost, order.created, order.canceled, order.charged, order.charged.failure

urlstring required

url of the resouce that will be invoked when event ocurs

activestring

if present value is active

Response

201

Example response

{
  "data": {
    "object": "WebHook",
    "id": "0k3NRljnRg4jAl",
    "event_types": [
      {
        "event_type": "plan.created"
      }
    ],
    "url": "https://dash.readme.com/project/payarcdocs/v1.2.0/refs/add-webhooks",
    "created_at": 1726225956,
    "updated_at": 1726225956,
    "enabled": true
  }
}