deleteLoyaltyPrograms
Remove loyalty programs by specifying their unique IDs using the Mews MCP server. Streamline loyalty program management by deleting outdated or inactive programs efficiently.
Instructions
Deletes loyalty programs
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| LoyaltyProgramIds | Yes | Unique identifier of the loyalty programs to be deleted |
Implementation Reference
- The core handler function that executes the tool by calling mewsRequest to POST to '/api/connector/v1/loyaltyPrograms/delete' with the input arguments and returns the JSON result.async execute(config: MewsAuthConfig, args: unknown): Promise<ToolResult> { const result = await mewsRequest(config, '/api/connector/v1/loyaltyPrograms/delete', args); return { content: [{ type: 'text', text: JSON.stringify(result, null, 2) }] }; }
- Input schema defining the required 'LoyaltyProgramIds' as an array of strings (max 1000 items).inputSchema: { type: 'object', properties: { LoyaltyProgramIds: { type: 'array', items: { type: 'string' }, description: 'Unique identifier of the loyalty programs to be deleted', maxItems: 1000 } }, required: ['LoyaltyProgramIds'], additionalProperties: false },
- src/tools/index.ts:80-80 (registration)Import statement that brings in the tool definition for registration.import { deleteLoyaltyProgramsTool } from './loyalty/deleteLoyaltyPrograms.js';
- src/tools/index.ts:165-165 (registration)Includes the tool in the allTools array, which is exported for use in the MCP server.deleteLoyaltyProgramsTool,