Register a webhook endpoint owned by this installation.
POST
/apps/webhooks/subscriptions
const url = 'https://your-store.myciqra.com/apps/webhooks/subscriptions';const options = { method: 'POST', headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'}, body: '{"description":"example","eventTypes":["example"],"url":"example"}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://your-store.myciqra.com/apps/webhooks/subscriptions \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '{ "description": "example", "eventTypes": [ "example" ], "url": "example" }'Required scope: write_webhooks — an installation token without it receives 403.
Authorizations
Section titled “Authorizations”Request Bodyrequired
Section titled “Request Bodyrequired”Media typeapplication/json
object
description
required
null | string
eventTypes
required
Array<string> | null
url
required
null | string
Examplegenerated
{ "description": "example", "eventTypes": [ "example" ], "url": "example"}Responses
Section titled “Responses”OK
Media typeapplication/json
object
autoDisabledAt
null | string format: date-time
autoDisabledReason
null | string
consecutiveFailures
integer | string format: int32
createdAt
required
string format: date-time
description
required
null | string
eventTypes
required
Array<string>
hasSigningSecret
required
boolean
id
required
string format: uuid
installationId
null | string format: uuid
isActive
required
boolean
isDeliverable
required
boolean
updatedAt
required
null | string format: date-time
url
required
string
Example
{ "consecutiveFailures": 0}Bad Request
Media typeapplication/json
object
error
required
string
Examplegenerated
{ "error": "example"}