Graine AI

List webhook subscriptions

List the organisation's webhook subscriptions, most recently updated first.

List the organisation's webhook subscriptions, most recently updated first.

Both agent-scoped subscriptions and the organisation-wide default are returned; scope on each row says which it is.

Three things worth knowing:

  • agent_id distinguishes absent from empty. Omitting it lists everything. ?agent_id=abc lists that agent's own subscriptions. ?agent_id= lists the organisation-wide default only, because an empty value addresses the org-wide slot everywhere in this API.
  • event_type filters on the RESOLVED list, so a subscription created without an explicit event_types matches ?event_type=all_processing_completed.
  • At most 500 subscriptions are visible. The store caps its listing there and pages are cut from that window, so total is capped at 500 as well. No organisation is expected to approach it; if yours does, scope your subscriptions per agent rather than per URL.

An organisation with no subscriptions and a subscription store that is momentarily unreadable both answer with an empty page — the store reports them identically.

Errors: 400, 401, 403, 422, 429, 503.

Rate limit: 1000 requests per minute per organization (bucket default). Exceeding it returns 429 with Retry-After; the X-RateLimit-* response headers report your remaining allowance on every call.

GET
/v2/webhooks
/v2/webhooks?agent_id=6c6f4cc3-f56c-479d-8422-7f76694daa29&enabled=true&event_type=all_processing_completed&page=1&page_size=20

The Authorization access token

Authorization

Authorization
Required
Bearer <token>

Your Graine API key. Create one in the dashboard under Developers, or via POST /v2/api-keys. Send it as Authorization: Bearer <key>.

In: header

Query Parameters

agent_idAgent Id

Omit for every subscription in the organisation. Pass an agent id for that agent's own subscriptions. Pass an EMPTY value (?agent_id=) for the organisation-wide default only.

enabledEnabled

Filter by enabled state.

event_typeEvent Type

Only subscriptions that receive this event. Valid event types: all_processing_completed, call_completed, call_corrected, call_ringing, call_started, client_analysis_completed, platform_analysis_completed, recording_completed. Omitting event_types, or sending an empty list, resolves to all_processing_completed — there is no value that means "every event".

organization_idOrganization Id

Must match the organisation the API key belongs to.

pagePage

1-indexed page number (max 10000 — narrow the window instead)

Default: 1Minimum: 1Maximum: 10000

page_sizePage Size

Items per page (max 100)

Default: 20Minimum: 1Maximum: 100

Response Body

200

A page of subscriptions, org-wide default first.

data
Required
Data

This page of subscriptions.

pagination
Required
Pagination

Where this page sits in the result set.

400

1000 — malformed input the schema could not reject: an unknown event type, a method other than POST/PUT, a reserved header name, or a callback_url pointing at a private, loopback or metadata address.

error
Required
Error

Stable integer code from the /v2 error table. Branch on this.

message
Required
Message

One human-readable sentence. Wording may change; the code will not.

401

1100 — missing, unknown or inactive API key. 1101 — a browser session token was presented instead of a gat_ key.

error
Required
Error

Stable integer code from the /v2 error table. Branch on this.

message
Required
Message

One human-readable sentence. Wording may change; the code will not.

403

1102 — the key is valid but lacks the scope this endpoint requires, or names another organisation. GET /v2/scopes reports which scopes the key holds.

error
Required
Error

Stable integer code from the /v2 error table. Branch on this.

message
Required
Message

One human-readable sentence. Wording may change; the code will not.

422

1001 — the body or query failed validation; the message names the first offending field.

error
Required
integer

Stable integer code from the error table. Branch on this, not on the message.

message
Required
string

One human-readable sentence. Wording may change; the code will not.

429

1300 — per-organisation rate limit exceeded. Carries Retry-After.

error
Required
Error

Stable integer code from the /v2 error table. Branch on this.

message
Required
Message

One human-readable sentence. Wording may change; the code will not.

503

1501 — the webhook subscription store is unreachable.

error
Required
Error

Stable integer code from the /v2 error table. Branch on this.

message
Required
Message

One human-readable sentence. Wording may change; the code will not.

504

1502 — an upstream did not respond in time.

error
Required
Error

Stable integer code from the /v2 error table. Branch on this.

message
Required
Message

One human-readable sentence. Wording may change; the code will not.

curl -X GET "https://api.graine.ai/v2/webhooks?agent_id=6c6f4cc3-f56c-479d-8422-7f76694daa29&enabled=true&event_type=all_processing_completed&organization_id=string&page=1&page_size=20" \
  -H "Authorization: Bearer <token>"

A page of subscriptions, org-wide default first.

{
  "data": [
    {
      "subscription_id": "b91d2f77-3ea5-4c58-9d10-6f8b4a2c7e31",
      "agent_id": "6c6f4cc3-f56c-479d-8422-7f76694daa29",
      "scope": "agent",
      "event_types": [
        "all_processing_completed"
      ],
      "callback_url": "https://example.com/hooks/graine",
      "method_type": "POST",
      "headers": {
        "Authorization": "***"
      },
      "header_names": [
        "X-Tenant"
      ],
      "enabled": true,
      "has_secret": true,
      "secret": "***",
      "secret_unavailable": false,
      "created_at": "2026-08-20T13:06:01.724Z",
      "updated_at": "2026-08-20T13:27:49.073Z",
      "created_by": "dev_1a2b3c4d5e6f7a8b"
    }
  ],
  "pagination": {
    "page": 1,
    "page_size": 20,
    "total": 137,
    "total_pages": 7,
    "has_more": true
  }
}