GraphQLRepositorieswebhook
entities.webhook
Read webhook records with the webhook repository, and change them with the webhook mutations. Same records as the REST Webhooks entity.
Queries
Fields of entities { webhook { … } }.
Each operation opens an example built from the schema and checked against it on every build. Replace the placeholders, such as <webhook id>, with values from your space.
| Kind | Field | Returns |
|---|---|---|
| QUERY | getById(entityId: ID!)Returns the record with the given id, or null when there is none. Deleted records are returned as well. | WebhookEntity |
Example | ||
| QUERY | getByIds(entityIds: [ID!]!)Returns the records with the given ids; ids without a record are left out. Deleted records are returned as well. | [WebhookEntity!]! |
Example | ||
| QUERY | getAll(limit: Int, offset: Int, filter: WebhookFilterInput, orderBy: [WebhookOrderByInput!], includeDeleted: Boolean)Returns the records that match the filter, paged with limit and offset. | [WebhookEntity!]! |
Example | ||
| QUERY | getByCriteria(filter: WebhookFilterInput, orderBy: [WebhookOrderByInput!], includeDeleted: Boolean, before: String, after: String, first: Int, last: Int)Returns the records that match the filter as a cursor-paginated connection. | WebhookEntityConnection |
Example | ||
| QUERY | getChangedFieldsSinceRevision(id: UUID!, revision: Int!)Returns the ids of the fields of a record that changed after the given revision. Returns an empty list for entities without change tracking. | [UUID!]! |
Example | ||
Mutations
| Kind | Mutation | Does | Returns |
|---|---|---|---|
| MUTATION | createWebhook(input: CreateWebhookInput!, validationLevel: [ValidationLevel!]) | Create one record | CreateWebhookPayload |
Example | |||
| MUTATION | updateWebhook(input: UpdateWebhookInput!, validationLevel: [ValidationLevel!], sessionIdToUpdate: String) | Update fields | UpdateWebhookPayload |
Example | |||
| MUTATION | bulkUpdateWebhook(input: [CreateOrUpdateWebhookInput!]!, deleteInput: [DeleteWebhookInput!], validationLevel: [ValidationLevel!], rollbackMethod: RollbackMethod, match: MatchingInput) | Create or update many; per-item results | BulkUpdateWebhookPayload |
Example | |||
| MUTATION | deleteWebhook(input: DeleteWebhookInput!) | Soft-delete | DeleteWebhookPayload |
Example | |||
Types
The types this repository uses, each with its fields and their descriptions. Types several repositories share, such as PageInfo and the filter fields, are in the types index.
WebhookEntity object 15 fields: isDeleteProtected, id, isDeleted, …
Registered webhook urls will be called when subscribed events occur with access level corresponding to the Webhook owner. Recipient has to receive the webhook in 10 seconds and respond with HTTP 200 (2XX) status.
| Field | Type | Description |
|---|---|---|
isDeleteProtected | Boolean! | True when the record is protected against deletion because it must always exist in the space. Deleting a record that is not protected can still fail on other checks. Read-only. |
id | ID! | Unique identifier of entity. |
isDeleted | Boolean | Specifies if the entity is considered deleted. |
modified | DateTime | Last modification time. |
created | DateTime | Creation time. |
application | ApplicationEntity | OAuth application that registered this webhook. Set automatically when the webhook is created using OAuth credentials; empty when a team-space API key was used. |
client | ClientEntity | Client who defined the Webhook. Only those notifications are sent which this Client has permission to see. If empty, all space notification are send, even for events of private records. Value is automatically set to authenticated user who created the webhook. |
applicationId | ID | Id of the OAuth application that registered the Webhook. |
clientId | ID | Id of the user who defined the Webhook. |
insecureSsl | Boolean! | If True, remote side ssl certificate will not be validated when delivering notifications. |
options | JSONString | Params in REST API format (snake case), to modify the content of the WebHook. You can set "entity" options of the main entity on which the event occurs. E.g. Account for events like Account.Create, Account.Update, Account.Delete. |
signature | ID | Signature to verify webhook (has to be UUID). When signature is set, then all webhook requests will be signed using HMAC-SHA256. This signature will be used as key and request body as message. Signature will be located in "WebHook-Signature" header. |
url | String! | Target URL that webhook event payloads are POSTed to. |
events | [EventEnum!]! | Event types this webhook subscribes to (e.g. Account.Create, Lead.Update). At least one event is required; the webhook fires whenever any subscribed event occurs in the team space. |
instancePermissions | [EntityPermsEnum!]! (1 args) | Permissions the current user has on this record, out of the requested ones. |
WebhookEntityConnection object pageInfo: PageInfo!, edges: [WebhookEntityEdge]!, totalCount: Int
Paginated list of Webhook records.
| Field | Type | Description |
|---|---|---|
pageInfo | PageInfo! | Pagination data for this connection. |
edges | [WebhookEntityEdge]! | Contains the nodes in this connection. |
totalCount | Int | Total number of items in the connection. |
WebhookEntityEdge object node: WebhookEntity, cursor: String!
A Relay edge containing a WebhookEntity and its cursor.
| Field | Type | Description |
|---|---|---|
node | WebhookEntity | The item at the end of the edge |
cursor | String! | A cursor for use in pagination |
WebhookFilterInput input AND, OR, NOT, globalSearchQuery, one condition per field
Filter conditions for Webhook records. Conditions on different fields are combined with AND; use OR, AND and NOT for other combinations.
| Input field | Type | Description |
|---|---|---|
OR | [WebhookFilterInput!] | Matches records that meet at least one of the listed filters. |
AND | [WebhookFilterInput!] | Matches records that meet all of the listed filters. |
NOT | WebhookFilterInput | Matches records that do not meet this filter. |
globalSearchQuery | String | Search term matched against the fields that the global search covers for this entity. |
id | EntityFilterStringField | Unique identifier of entity. |
isDeleted | Boolean | Specifies if the entity is considered deleted. |
modified | EntityFilterDateTimeField | Last modification time. |
created | EntityFilterDateTimeField | Creation time. |
applicationId | EntityFilterStringField | Id of the OAuth application that registered the Webhook. |
clientId | EntityFilterStringField | Id of the user who defined the Webhook. |
insecureSsl | Boolean | If True, remote side ssl certificate will not be validated when delivering notifications. |
signature | EntityFilterStringField | Signature to verify webhook (has to be UUID). When signature is set, then all webhook requests will be signed using HMAC-SHA256. This signature will be used as key and request body as message. Signature will be located in "WebHook-Signature" header. |
url | EntityFilterStringField | Target URL that webhook event payloads are POSTed to. |
application | ApplicationFilterInput | OAuth application that registered this webhook. Set automatically when the webhook is created using OAuth credentials; empty when a team-space API key was used. Matches records where a related record meets these conditions. |
client | ClientFilterInput | Client who defined the Webhook. Only those notifications are sent which this Client has permission to see. If empty, all space notification are send, even for events of private records. Value is automatically set to authenticated user who created the webhook. |
WebhookOrderByInput input Asc or Desc per field
Sorting of Webhook records. Set exactly one field in each item; list several items to sort by more fields, in order of priority.
| Input field | Type | Description |
|---|---|---|
id | OrderByEnum | Unique identifier of entity. |
isDeleted | OrderByEnum | Specifies if the entity is considered deleted. |
modified | OrderByEnum | Last modification time. |
created | OrderByEnum | Creation time. |
application | [ApplicationOrderByNestedInput!] | OAuth application that registered this webhook. Set automatically when the webhook is created using OAuth credentials; empty when a team-space API key was used. Sorts by fields of the related record, listed in order of priority. |
client | [ClientOrderByNestedInput!] | Client who defined the Webhook. Only those notifications are sent which this Client has permission to see. If empty, all space notification are send, even for events of private records. Value is automatically set to authenticated user who created the webhook. |
applicationId | OrderByEnum | Id of the OAuth application that registered the Webhook. |
clientId | OrderByEnum | Id of the user who defined the Webhook. |
insecureSsl | OrderByEnum | If True, remote side ssl certificate will not be validated when delivering notifications. |
url | OrderByEnum | Target URL that webhook event payloads are POSTed to. |
CreateOrUpdateWebhookInput input 9 fields: clientMutationId, id, modified, …
Field values of a Webhook record to create, or to update when its id is set.
| Input field | Type | Description |
|---|---|---|
clientMutationId | String | Optional client-supplied identifier passed on a mutation input and echoed back unchanged on its payload, so a client can correlate the response with its request (Relay convention). |
id | ID | Unique identifier of entity. |
modified | DateTime | Last modification time. |
created | DateTime | Creation time. |
insecureSsl | Boolean | If True, remote side ssl certificate will not be validated when delivering notifications. |
options | JSONString | Params in REST API format (snake case), to modify the content of the WebHook. You can set "entity" options of the main entity on which the event occurs. E.g. Account for events like Account.Create, Account.Update, Account.Delete. |
signature | ID | Signature to verify webhook (has to be UUID). When signature is set, then all webhook requests will be signed using HMAC-SHA256. This signature will be used as key and request body as message. Signature will be located in "WebHook-Signature" header. |
url | String | Target URL that webhook event payloads are POSTed to. |
events | [EventEnum!] | Event types this webhook subscribes to (e.g. Account.Create, Lead.Update). At least one event is required; the webhook fires whenever any subscribed event occurs in the team space. |
CreateWebhookInput input 8 fields: clientMutationId, modified, created, …
Field values of a new Webhook record.
| Input field | Type | Description |
|---|---|---|
clientMutationId | String | Optional client-supplied identifier passed on a mutation input and echoed back unchanged on its payload, so a client can correlate the response with its request (Relay convention). |
modified | DateTime | Last modification time. |
created | DateTime | Creation time. |
insecureSsl | Boolean! | If True, remote side ssl certificate will not be validated when delivering notifications. |
options | JSONString | Params in REST API format (snake case), to modify the content of the WebHook. You can set "entity" options of the main entity on which the event occurs. E.g. Account for events like Account.Create, Account.Update, Account.Delete. |
signature | ID | Signature to verify webhook (has to be UUID). When signature is set, then all webhook requests will be signed using HMAC-SHA256. This signature will be used as key and request body as message. Signature will be located in "WebHook-Signature" header. |
url | String! | Target URL that webhook event payloads are POSTed to. |
events | [EventEnum!]! | Event types this webhook subscribes to (e.g. Account.Create, Lead.Update). At least one event is required; the webhook fires whenever any subscribed event occurs in the team space. |
DeleteWebhookInput input clientMutationId: String, id: ID!
Id of the Webhook record to delete.
| Input field | Type | Description |
|---|---|---|
clientMutationId | String | Optional client-supplied identifier passed on a mutation input and echoed back unchanged on its payload, so a client can correlate the response with its request (Relay convention). |
id | ID! | Unique identifier of entity. |
UpdateWebhookInput input 9 fields: clientMutationId, id, modified, …
Id of a Webhook record and the field values to change.
| Input field | Type | Description |
|---|---|---|
clientMutationId | String | Optional client-supplied identifier passed on a mutation input and echoed back unchanged on its payload, so a client can correlate the response with its request (Relay convention). |
id | ID! | Unique identifier of entity. |
modified | DateTime | Last modification time. |
created | DateTime | Creation time. |
insecureSsl | Boolean | If True, remote side ssl certificate will not be validated when delivering notifications. |
options | JSONString | Params in REST API format (snake case), to modify the content of the WebHook. You can set "entity" options of the main entity on which the event occurs. E.g. Account for events like Account.Create, Account.Update, Account.Delete. |
signature | ID | Signature to verify webhook (has to be UUID). When signature is set, then all webhook requests will be signed using HMAC-SHA256. This signature will be used as key and request body as message. Signature will be located in "WebHook-Signature" header. |
url | String | Target URL that webhook event payloads are POSTed to. |
events | [EventEnum!] | Event types this webhook subscribes to (e.g. Account.Create, Lead.Update). At least one event is required; the webhook fires whenever any subscribed event occurs in the team space. |
BulkUpdateWebhookPayload object result: BulkUpdateResults!
Result of the bulkUpdateWebhook mutation.
| Field | Type | Description |
|---|---|---|
result | BulkUpdateResults! | Ids of the created, updated and deleted records, and the items that failed. |
CreateWebhookPayload object webhook: WebhookEntity, clientMutationId: String
Result of the createWebhook mutation.
| Field | Type | Description |
|---|---|---|
webhook | WebhookEntity | The created record. |
clientMutationId | String | Optional client-supplied identifier passed on a mutation input and echoed back unchanged on its payload, so a client can correlate the response with its request (Relay convention). |
DeleteWebhookPayload object webhook: WebhookEntity, clientMutationId: String
Result of the deleteWebhook mutation.
| Field | Type | Description |
|---|---|---|
webhook | WebhookEntity | The deleted record. |
clientMutationId | String | Optional client-supplied identifier passed on a mutation input and echoed back unchanged on its payload, so a client can correlate the response with its request (Relay convention). |
UpdateWebhookPayload object webhook: WebhookEntity, clientMutationId: String
Result of the updateWebhook mutation.
| Field | Type | Description |
|---|---|---|
webhook | WebhookEntity | The updated record. |
clientMutationId | String | Optional client-supplied identifier passed on a mutation input and echoed back unchanged on its payload, so a client can correlate the response with its request (Relay convention). |