API referencaWebhookovi

Isporuke

Zadnje isporuke adrese: status, broj pokušaja, sljedeći pokušaj, HTTP status vaše adrese i greška.

GEThttps://api.cifra.ba/v1/webhooks/{id}/deliveries
Pristup
watchlist
Obračun
Besplatno
GET/v1/webhooks/{id}/deliveries
curl "https://api.cifra.ba/v1/webhooks/whe_K7pX2mQ9vN4tR8bL1cZe/deliveries" \
  -H "Authorization: Bearer $CIFRA_API_KEY"
Odgovor
{
  "object": "list",
  "data": [
    {
      "id": 90412,
      "event_id": "evt_2kQ9mX7vR4tL8bN1cZ5p",
      "event_type": "webhook.test",
      "status": "succeeded",
      "attempts": 1,
      "next_attempt_at": null,
      "last_status_code": 200,
      "last_error": null,
      "duration_ms": 184,
      "created_at": "2026-10-18T22:11:40.003Z",
      "delivered_at": "2026-10-18T22:11:40.212Z"
    },
    {
      "id": 90388,
      "event_id": "evt_7vT1bN6cZ3pW5yH0gD9x",
      "event_type": "watchlist.alert",
      "status": "pending",
      "attempts": 2,
      "next_attempt_at": "2026-10-18T07:12:44.000Z",
      "last_status_code": 503,
      "last_error": "HTTP 503",
      "duration_ms": 10000,
      "created_at": "2026-10-18T06:12:44.000Z",
      "delivered_at": null
    }
  ]
}

Parametri putanje

  • idstringobavezno

    Oznaka adrese (whe_…).

Parametri upita

  • limitintegeropcionalnopodrazumijevano 501 – 100

    Koliko zadnjih isporuka.

Odgovor

200
  • objectstringobavezno

    list.

  • dataobject[]obavezno

    Isporuke, od najnovije.

    Prikaži 11 polja
    • idintegerobavezno

      Oznaka isporuke.

    • event_idstringobavezno

      Događaj.

    • event_typestringobavezno

      Vrsta događaja.

    • statusenumobavezno

      pending (čeka pokušaj), sending, succeeded, failed.

      pendingsendingsucceededfailed
    • attemptsintegerobavezno

      Broj pokušaja.

    • next_attempt_atstring | nullobavezno

      Sljedeći pokušaj.

    • last_status_codeinteger | nullobavezno

      Zadnji HTTP status vaše adrese.

    • last_errorstringobavezno

      Zadnja greška.

    • duration_msinteger | nullobavezno

      Trajanje zadnjeg pokušaja.

    • created_atstringobavezno

      Trenutak u ISO 8601 (UTC).

    • delivered_atstring | nullobavezno

      Kad je isporučeno.

Greške

  • 404
    not_found

    Ne postoji, ili pripada drugoj kompaniji ili drugom okruženju.

Uz ove, svaki poziv s ključem može vratiti opšte greške (ključ, pristup, limiti).