fluentcrm_delete_campaign
Delete a marketing campaign from FluentCRM by specifying its campaign ID. This tool removes campaigns from the WordPress plugin's automation system.
Instructions
Usuwa kampanię
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| campaignId | Yes | ID kampanii |
Implementation Reference
- src/fluentcrm-mcp-server.ts:985-986 (handler)MCP CallTool handler case that extracts the campaignId from input arguments and calls FluentCRMClient.deleteCampaign to execute the deletion, returning the JSON-stringified result.case 'fluentcrm_delete_campaign': return { content: [{ type: 'text', text: JSON.stringify(await client.deleteCampaign((args as any)?.campaignId), null, 2) }] };
- src/fluentcrm-mcp-server.ts:735-741 (schema)Input schema definition specifying that campaignId (number) is required.inputSchema: { type: 'object', properties: { campaignId: { type: 'number', description: 'ID kampanii' }, }, required: ['campaignId'], },
- src/fluentcrm-mcp-server.ts:732-742 (registration)Tool registration in the ListTools response, defining the tool name, description, and input schema.{ name: 'fluentcrm_delete_campaign', description: 'Usuwa kampanię', inputSchema: { type: 'object', properties: { campaignId: { type: 'number', description: 'ID kampanii' }, }, required: ['campaignId'], }, },
- src/fluentcrm-mcp-server.ts:223-226 (helper)FluentCRMClient helper method that performs the actual HTTP DELETE request to the /campaigns/{campaignId} endpoint using axios and returns the API response data.async deleteCampaign(campaignId: number) { const response = await this.apiClient.delete(`/campaigns/${campaignId}`); return response.data; }