Skip to main content
PATCH
/
projects
/
{project_id}
/
webhooks
/
{id}
cURL
curl "https://api.phrase.com/v2/projects/:project_id/webhooks/:id" \
  -u USERNAME_OR_ACCESS_TOKEN \
  -X PATCH \
  -d '{"callback_url":"http://example.com/hooks/phraseapp-notifications","description":"My webhook for chat notifications","events":"locales:create,translations:update"}' \
  -H 'Content-Type: application/json'
{
  "id": "abcd1234cdef1234abcd1234cdef1234",
  "callback_url": "http://example.com/hooks/phraseapp-notifications",
  "description": "My webhook for chat notifications",
  "events": "locales:create,translations:update",
  "active": true,
  "include_branches": false,
  "created_at": "2015-01-28T09:52:53Z",
  "updated_at": "2015-01-28T09:52:53Z"
}

Authorizations

Authorization
string
header
required

Enter your token in the format token TOKEN

Headers

X-PhraseApp-OTP
string

Two-Factor-Authentication token (optional)

Path Parameters

project_id
string
required

Project ID

id
string
required

ID

Body

application/json
callback_url
string

Callback URL to send requests to

Example:

"http://example.com/hooks/phraseapp-notifications"

secret
string

Webhook secret used to calculate signature. If empty, the default project secret will be used.

Example:

"secr3t"

description
string

Webhook description

Example:

"My webhook for chat notifications"

events
string

List of event names to trigger the webhook (separated by comma)

Example:

"locales:create,translations:update"

active
boolean

Whether webhook is active or inactive

Example:

null

include_branches
boolean

If enabled, webhook will also be triggered for events from branches of the project specified.

Example:

null

Response

OK

id
string
callback_url
string
description
string
events
string[]
active
boolean
include_branches
boolean
created_at
string<date-time>
updated_at
string<date-time>