webhooks.create
Create webhook endpoints in Ryft MCP to receive real-time notifications for payment events, customer updates, and subscription changes.
Instructions
Create a Ryft webhook endpoint.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| url | Yes | ||
| active | Yes | ||
| eventTypes | Yes |
Implementation Reference
- src/tools/webhooks.ts:20-20 (handler)The handler function for webhooks.create tool, which calls the HTTP client's POST method.
async (args) => client.post('/webhooks', webhookSchema.parse(args)), - src/tools/webhooks.ts:16-21 (registration)Registration of the webhooks.create tool.
registerTool( 'webhooks.create', 'Create a Ryft webhook endpoint.', webhookSchema.shape, async (args) => client.post('/webhooks', webhookSchema.parse(args)), ); - src/tools/webhooks.ts:5-9 (schema)Schema definition for the webhook input parameters.
const webhookSchema = z.object({ url: z.string().url(), active: z.boolean(), eventTypes: z.array(z.string().min(1)).min(1), });