create_webhook
Set up webhooks in Basecamp by specifying a project ID, payload URL, and event types to automate notifications and streamline project management workflows.
Instructions
Create a webhook
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| payload_url | Yes | Payload URL | |
| project_id | Yes | Project ID | |
| types | No | Event types |
Implementation Reference
- src/index.ts:486-498 (registration)Registration of the 'create_webhook' tool including name, description, and input schema in the listTools response.{ name: 'create_webhook', description: 'Create a webhook', inputSchema: { type: 'object', properties: { project_id: { type: 'string', description: 'Project ID' }, payload_url: { type: 'string', description: 'Payload URL' }, types: { type: 'array', items: { type: 'string' }, description: 'Event types' }, }, required: ['project_id', 'payload_url'], }, },
- src/index.ts:489-498 (schema)Input schema definition for the create_webhook tool.inputSchema: { type: 'object', properties: { project_id: { type: 'string', description: 'Project ID' }, payload_url: { type: 'string', description: 'Payload URL' }, types: { type: 'array', items: { type: 'string' }, description: 'Event types' }, }, required: ['project_id', 'payload_url'], }, },
- src/lib/basecamp-client.ts:396-402 (helper)Core implementation of webhook creation in BasecampClient class, making the POST API request to Basecamp.async createWebhook(projectId: string, payloadUrl: string, types?: string[]): Promise<Webhook> { const data: any = { payload_url: payloadUrl }; if (types) data.types = types; const response = await this.client.post(`/buckets/${projectId}/webhooks.json`, data); return response.data; }
- src/types/basecamp.ts:170-176 (schema)TypeScript interface definition for Webhook object returned by the createWebhook method.export interface Webhook { id: string; payload_url: string; types: string[]; created_at: string; updated_at: string; }