fluentcrm_generate_smart_link_shortcode
Generate shortcodes for FluentCRM Smart Links to embed trackable marketing links in WordPress content.
Instructions
Generuje shortcode dla Smart Link
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| slug | Yes | Slug Smart Link | |
| linkText | No | Tekst linku (opcjonalny) |
Implementation Reference
- src/fluentcrm-mcp-server.ts:418-423 (handler)Core implementation of the tool logic: generates FluentCRM smart link shortcode either as plain shortcode or wrapped in an anchor tag with optional link text.generateSmartLinkShortcode(slug: string, linkText?: string): string { if (linkText) { return `<a href="{{fc_smart_link slug='${slug}'}}">${linkText}</a>`; } return `{{fc_smart_link slug='${slug}'}}`; }
- src/fluentcrm-mcp-server.ts:891-898 (schema)Input schema defining parameters: slug (required string) and optional linkText string.inputSchema: { type: 'object', properties: { slug: { type: 'string', description: 'Slug Smart Link' }, linkText: { type: 'string', description: 'Tekst linku (opcjonalny)' }, }, required: ['slug'], },
- src/fluentcrm-mcp-server.ts:888-899 (registration)Tool registration in the MCP server's tools list, specifying name, description, and input schema.{ name: 'fluentcrm_generate_smart_link_shortcode', description: 'Generuje shortcode dla Smart Link', inputSchema: { type: 'object', properties: { slug: { type: 'string', description: 'Slug Smart Link' }, linkText: { type: 'string', description: 'Tekst linku (opcjonalny)' }, }, required: ['slug'], }, },
- src/fluentcrm-mcp-server.ts:1015-1016 (handler)MCP server dispatch handler: switch case that calls the generateSmartLinkShortcode method and returns the result as JSON.case 'fluentcrm_generate_smart_link_shortcode': return { content: [{ type: 'text', text: JSON.stringify({ shortcode: client.generateSmartLinkShortcode((args as any)?.slug, (args as any)?.linkText) }, null, 2) }] };