Skip to content

GET /v1/projects/{projectId}/webhooks/event-types

Lists the webhook event types available in the requested apiVersion, including their descriptions, audiences and reader-schema URLs. Use this versioned catalog when selecting a destination's enabledEvents. The response may include version-retirement information; an authorized conditional request can return 304 without a body.

photon.projects.listWebhookEventTypes(input: ListWebhookEventTypesInput, options?: RequestOptions): Promise<ListWebhookEventTypesOutput>
import { Photon } from "@photon-ai/api";

const photon = new Photon({
  headers: { Authorization: `Bearer ${process.env.PHOTON_API_TOKEN}` },
});
const result = await photon.projects.listWebhookEventTypes({
  path: {
    projectId: "projectId",
  },
  query: {
    apiVersion: "2026-01-01",
  },
});
{
  "apiVersion": "2026-01-01",
  "contractNamespace": "@photon-hq/contracts",
  "events": [
    {
      "audience": "agent",
      "description": "string",
      "schemaProfile": "reader",
      "schemaUrl": "/v1/projects/pho_prj_00000000000000000000000001/webhooks/event-types/message.received/schema?apiVersion=2026-07-01",
      "type": "string"
    }
  ],
  "packageVersion": "string",
  "retirement": null,
  "selectable": true,
  "status": "preview",
  "successor": null
}

Parameters

Photon-VersionPhotonVersion

Selects the API contract date. Without it, the request is served as 2026-07-01.

projectIdstringrequired
apiVersionstring (date)required

Returns

200 Events available in the selected API version. ListWebhookEventTypesResponse

Headers: ETag, Photon-Version. The raw response carries these headers; see Raw responses.

One of: SelectableWebhookEventCatalog

apiVersionstring (date)required
contractNamespaceunknownrequired
eventsarray of WebhookEventTyperequired
packageVersionstringrequired
retirementWebhookApiVersionRetirement | nullrequired
selectabletruerequired
statusSelectableWebhookApiVersionStatusrequired
successorstring (date) | nullrequired

One of: DeprecatedWebhookEventCatalog

apiVersionstring (date)required
contractNamespaceunknownrequired
eventsarray of WebhookEventTyperequired
packageVersionstringrequired
retirementWebhookApiVersionRetirementrequired
selectablefalserequired
statusunknownrequired
successorstring (date) | nullrequired

304 Not Modified. Sent only when If-None-Match matches the ETag of an earlier 200 response for the same representation; no body. No body.

Headers: ETag, Photon-Version. The raw response carries these headers; see Raw responses.