Webhookit
Lähetä testitapahtuma
Lähetä ping-tapahtuma webhookiin
POST
/
api
/
v1
/
webhooks
/
{id}
/
ping
curl --request POST \
--url https://anivahealth.com/api/v1/webhooks/4a6c8e0f-2b4d-4f6a-8c0e-2a4c6e8f0b1d/ping \
--header 'x-api-key: YOUR_API_KEY'
{
"delivery_id": "7c9e1a3b-5d7f-4b2d-9e4a-6c8e0a2b4d6f"
}
{
"error": "The endpoint is disabled. Enable it first."
}
Lähetä allekirjoitettu
ping-tapahtuma webhookiin sen enabled_events-asetuksesta riippumatta. Kutsu palauttaa vastauksen heti.
Seuraa tulosta kohdassa Listaa toimitukset.
Vaatii
webhooks_manage-scopen.Pyyntö
Polkuparametrit
Vastaus
Onnistuessaan API palauttaa202 Accepted.
Virhevastaukset
| Tilakoodi | Kuvaus |
|---|---|
400 | Virheellinen pyyntö. Katso error-viesti. |
401 | Virheellinen API-avain. |
403 | API-avain puuttuu tai sillä ei ole webhooks_manage-käyttöoikeutta. |
404 | Webhookia ei löytynyt, tai se kuuluu toiselle API-avaimelle. |
409 | Webhook on pois käytöstä. Ota se ensin käyttöön. |
500 | Palvelimen sisäinen virhe. |
curl --request POST \
--url https://anivahealth.com/api/v1/webhooks/4a6c8e0f-2b4d-4f6a-8c0e-2a4c6e8f0b1d/ping \
--header 'x-api-key: YOUR_API_KEY'
{
"delivery_id": "7c9e1a3b-5d7f-4b2d-9e4a-6c8e0a2b4d6f"
}
{
"error": "The endpoint is disabled. Enable it first."
}
⌘I
curl --request POST \
--url https://anivahealth.com/api/v1/webhooks/4a6c8e0f-2b4d-4f6a-8c0e-2a4c6e8f0b1d/ping \
--header 'x-api-key: YOUR_API_KEY'
{
"delivery_id": "7c9e1a3b-5d7f-4b2d-9e4a-6c8e0a2b4d6f"
}
{
"error": "The endpoint is disabled. Enable it first."
}