pylon_create_tag
Create custom tags to categorize and organize accounts, contacts, or issues within the Pylon customer support platform.
Instructions
Create a new tag
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| value | Yes | The tag name/value | |
| object_type | Yes | Type of object this tag applies to | |
| hex_color | No | Hex color code for the tag (e.g., #FF5733) |
Implementation Reference
- src/index.ts:530-549 (registration)Registration of the MCP tool 'pylon_create_tag' including input schema and handler function that delegates to PylonClient.server.tool( 'pylon_create_tag', 'Create a new tag', { value: z.string().describe('The tag name/value'), object_type: z .enum(['account', 'issue', 'contact']) .describe('Type of object this tag applies to'), hex_color: z .string() .optional() .describe('Hex color code for the tag (e.g., #FF5733)'), }, async (params) => { const result = await client.createTag(params); return { content: [{ type: 'text', text: JSON.stringify(result.data, null, 2) }], }; }, );
- src/index.ts:543-548 (handler)MCP tool handler for pylon_create_tag: calls PylonClient.createTag and formats response.async (params) => { const result = await client.createTag(params); return { content: [{ type: 'text', text: JSON.stringify(result.data, null, 2) }], }; },
- src/index.ts:533-542 (schema)Zod input schema for pylon_create_tag tool.{ value: z.string().describe('The tag name/value'), object_type: z .enum(['account', 'issue', 'contact']) .describe('Type of object this tag applies to'), hex_color: z .string() .optional() .describe('Hex color code for the tag (e.g., #FF5733)'), },
- src/pylon-client.ts:397-403 (handler)PylonClient.createTag method: performs POST request to /tags API endpoint.async createTag(data: { value: string; object_type: 'account' | 'issue' | 'contact'; hex_color?: string; }): Promise<SingleResponse<Tag>> { return this.request<SingleResponse<Tag>>('POST', '/tags', data); }
- src/pylon-client.ts:95-100 (schema)TypeScript interface for Tag object used in createTag response.export interface Tag { id: string; value: string; object_type: 'account' | 'issue' | 'contact'; hex_color?: string; }