-
Notifications
You must be signed in to change notification settings - Fork 317
Webhook API documentation + announcement blog + changelog #2875
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from 2 commits
1168a17
fca019e
a5136b6
83fb41c
b7a83de
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,98 @@ | ||
| --- | ||
| layout: post | ||
| title: "Announcing the Webhooks API: Manage webhooks programmatically with Server SDKs" | ||
| description: Webhooks are no longer console-only. Create, update, and delete webhooks using the Appwrite Server SDKs and API keys with the new webhooks.read and webhooks.write scopes. | ||
| date: 2026-04-10 | ||
| cover: /images/blog/announcing-webhooks-api/cover.png | ||
| timeToRead: 4 | ||
| author: matej-baco | ||
| category: announcement | ||
| featured: false | ||
| callToAction: true | ||
| --- | ||
|
|
||
| Webhooks have always been a core part of how developers integrate Appwrite into their workflows. Subscribe to an event, receive an HTTP POST, and let your server handle the rest. Until now, managing those webhooks meant logging into the Appwrite Console and configuring them by hand. | ||
|
|
||
| Today, we are announcing the **Webhooks API**, a fully programmable interface for managing webhooks through Server SDKs and API keys. | ||
|
|
||
| # Why this matters | ||
|
|
||
| If you have ever needed to set up webhooks across multiple projects, automate webhook provisioning as part of a deployment pipeline, or manage webhook lifecycles from code, you know the friction of doing it through a UI. | ||
|
|
||
| The Webhooks API removes that friction entirely. Webhooks become just another resource you can create, update, and delete programmatically, the same way you already manage databases, functions, and storage buckets. | ||
|
|
||
| This is especially valuable for: | ||
|
|
||
| - **CI/CD pipelines** that need to register webhooks as part of environment setup | ||
| - **Multi-tenant platforms** that provision webhooks per customer or workspace | ||
| - **Migration and seeding scripts** that replicate webhook configurations across environments | ||
| - **Admin dashboards** that let non-technical team members manage webhooks without Console access | ||
|
|
||
| # How it works | ||
|
atharvadeosthale marked this conversation as resolved.
|
||
|
|
||
| The Webhooks API introduces two new [API key scopes](/docs/advanced/platform/api-keys#scopes): | ||
|
|
||
| - **`webhooks.read`** for listing and retrieving webhooks | ||
| - **`webhooks.write`** for creating, updating, and deleting webhooks | ||
|
|
||
| Once your API key has the appropriate scopes, you can manage webhooks through any Appwrite Server SDK. | ||
|
|
||
| ## Create a webhook | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Might be worth having some more examples:
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. It might be better to have a separate blog on this showcasing a real-world use-case |
||
|
|
||
| ```server-nodejs | ||
| const sdk = require('node-appwrite'); | ||
|
atharvadeosthale marked this conversation as resolved.
Outdated
|
||
|
|
||
| const client = new sdk.Client() | ||
| .setEndpoint('https://<REGION>.cloud.appwrite.io/v1') | ||
| .setProject('<PROJECT_ID>') | ||
| .setKey('<YOUR_API_KEY>'); | ||
|
|
||
| const webhooks = new sdk.Webhooks(client); | ||
|
|
||
| const result = await webhooks.create({ | ||
| webhookId: sdk.ID.unique(), | ||
| url: 'https://example.com/webhook', | ||
| name: 'My Webhook', | ||
| events: ['users.*.create', 'users.*.update'], | ||
| security: true | ||
| }); | ||
|
atharvadeosthale marked this conversation as resolved.
|
||
| ``` | ||
|
|
||
| ## Update a webhook | ||
|
|
||
| ```server-nodejs | ||
| const result = await webhooks.update({ | ||
| webhookId: '<WEBHOOK_ID>', | ||
| name: 'Updated Webhook', | ||
| url: 'https://example.com/webhook-v2', | ||
| events: ['users.*.create', 'users.*.update', 'users.*.delete'], | ||
| security: true | ||
| }); | ||
| ``` | ||
|
|
||
| ## Delete a webhook | ||
|
|
||
| ```server-nodejs | ||
| await webhooks.delete({ | ||
| webhookId: '<WEBHOOK_ID>' | ||
| }); | ||
| ``` | ||
|
|
||
|
atharvadeosthale marked this conversation as resolved.
|
||
| The API supports all the same configuration options available in the Console, including event selection, SSL/TLS certificate verification, and HTTP basic authentication. | ||
|
|
||
| # Get started | ||
|
|
||
| The Webhooks API is available on **Appwrite Cloud** today. | ||
|
|
||
| 1. Navigate to **Overview** > **Integration** > **API keys** and create or update an API key with the `webhooks.read` and `webhooks.write` scopes. | ||
| 2. Initialize a Server SDK with your API key. | ||
| 3. Use the `Webhooks` service to manage your webhooks from code. | ||
|
Comment on lines
+587
to
+593
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Not sure if this makes sense after the code examples |
||
|
|
||
| Full documentation, including examples for all supported SDKs, is available on the [webhooks documentation page](/docs/advanced/platform/webhooks). | ||
|
|
||
| # Resources | ||
|
|
||
| - [Webhooks documentation](/docs/advanced/platform/webhooks) | ||
| - [API keys and scopes](/docs/advanced/platform/api-keys) | ||
| - [Webhook events reference](/docs/advanced/platform/events) | ||
| - [Appwrite Webhooks: triggering events the right way](/blog/post/appwrite-webhooks) | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,14 @@ | ||
| --- | ||
| layout: changelog | ||
| title: "Webhooks API: manage webhooks with Server SDKs" | ||
| date: 2026-04-10 | ||
|
atharvadeosthale marked this conversation as resolved.
|
||
| cover: /images/blog/announcing-webhooks-api/cover.png | ||
| --- | ||
|
|
||
| Webhooks can now be created, updated, and deleted programmatically using the Appwrite Server SDKs. Two new API key scopes, `webhooks.read` and `webhooks.write`, control access to the new endpoints. | ||
|
|
||
| This makes it possible to provision webhooks as part of CI/CD pipelines, migration scripts, or any workflow where managing webhooks through the Console is not practical. | ||
|
|
||
| {% arrow_link href="/blog/post/announcing-webhooks-api" %} | ||
| Read the announcement | ||
| {% /arrow_link %} | ||
Uh oh!
There was an error while loading. Please reload this page.