Webhooks

POST /public/v1/webhooks

Changed on

Register an outbound webhook. Valley POSTs a JSON payload to webhookUrl whenever one of the triggerTypes fires. scope PERSONAL (default) fires only for the caller's own events; WORKSPACE fires for every member and requires ADMIN/OWNER.

Request

  • Base URL
    https://api.joinvalley.co
  • Auth
    API key in header x-api-key

Request body

workspaceIdstring

Required for a user API key. A workspace API key is locked to its own workspace.

webhookUrlstring required

Absolute http(s) endpoint Valley will POST event payloads to.

triggerTypesstring[] required

Events that fire this webhook. PROSPECT_RESPONSE and SEND_FIRST_PROSPECT_RESPONSE are mutually exclusive; if both are sent only PROSPECT_RESPONSE is kept.

scope'PERSONAL' | 'WORKSPACE'
labelstring

Response

Default Response

statusCodenumber
statusboolean
messagestring

Changes