API Reference
Scalars
Roles
Common objects
Slots
Projects
Services
Bookings
Spaces
Locations
Assets
Team
Reviews
Reminders
Webhooks
Denylist
Schema
JS SDK
Timerise © 2022
Webhooks overview
Webhooks are a way to connect and communicate between applications.
Object types
Webhook
Represents details of a webhook.
type Webhook {
projectId: ID!
webhookId: ID!
event: WebhookEvent!
url: URL!
labels: [NonEmptyString]
createdAt: DateTime!
updatedAt: DateTime!
}
Field name | Value type | Non-null | Description |
---|---|---|---|
projectId | ID | true | A globally-unique identifier. |
webhookId | ID | true | A globally-unique identifier. |
event | WebhookEvent | true | |
url | URL | true | |
labels | [NonEmptyString] | false | |
createdAt | DateTime | true | The date and time when a webhook was created. |
updatedAt | DateTime | true | The date and time when a webhook was updated. |
Enums
WebhookEvent
enum WebhookEvent {
BOOKING_CREATE
BOOKING_UPDATE
}
Queries
webhooks
Returns a list of webhooks.
webhooks(
projectId: ID!
limit: NonNegativeInt
cursor: ID
): [Webhook]
Field name | Value type | Required | Description |
---|---|---|---|
projectId | ID | true | A globally-unique identifier. |
limit | NonNegativeInt | false | |
cursor | ID | false | A globally-unique identifier. |
Minimal role required:
ADMIN
/ APIADMIN
webhook
Returns an Webhook resource by project & webhook ID.
webhook(
projectId: ID!
webhookId: ID!
): Webhook
Field name | Value type | Required | Description |
---|---|---|---|
projectId | ID | true | A globally-unique identifier. |
webhookId | ID | true | A globally-unique identifier. |
Minimal role required:
ADMIN
/ APIADMIN
Mutations
webhookCreate
Creates a webhook.
webhookCreate(
projectId: ID!
event: WebhookEvent!
url: URL!
labels: [NonEmptyString]
): Webhook
Field name | Value type | Required | Description |
---|---|---|---|
projectId | ID | true | A globally-unique identifier. |
event | WebhookEvent | true | |
url | URL | true | |
labels | [NonEmptyString] | false | A list of webhook labels. |
Minimal role required:
ADMIN
/ APIADMIN
webhookDelete
Removes a webhook.
webhookDelete(
projectId: ID!
webhookId: ID!
): String
Field name | Value type | Required | Description |
---|---|---|---|
projectId | ID | true | A globally-unique identifier. |
webhookId | ID | true | A globally-unique identifier. |
Minimal role required:
ADMIN
/ APIADMIN