pylon_get_tag
Retrieve a specific tag by its ID from the Pylon customer support platform.
Instructions
Get a specific tag by ID
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| id | Yes | The tag ID |
Implementation Reference
- src/index.ts:1066-1071 (handler)The handler function for pylon_get_tag. It calls client.getTag(id) and returns the result as JSON.
async ({ id }) => { const result = await client.getTag(id); return { content: [{ type: 'text', text: JSON.stringify(result.data, null, 2) }], }; }, - src/index.ts:1063-1065 (schema)The input schema for pylon_get_tag, which requires only an 'id' string parameter describing the tag ID.
{ id: z.string().describe('The tag ID'), }, - src/index.ts:1060-1072 (registration)Registration of the 'pylon_get_tag' tool via server.tool() with name, description, schema, and handler.
server.tool( 'pylon_get_tag', 'Get a specific tag by ID', { id: z.string().describe('The tag ID'), }, async ({ id }) => { const result = await client.getTag(id); return { content: [{ type: 'text', text: JSON.stringify(result.data, null, 2) }], }; }, ); - src/pylon-client.ts:569-571 (helper)The client.getTag() helper method that sends a GET request to /tags/{id} to fetch a tag by its ID.
async getTag(id: string): Promise<SingleResponse<Tag>> { return this.request<SingleResponse<Tag>>('GET', `/tags/${id}`); } - src/pylon-client.ts:248-253 (helper)The Tag interface definition describing the shape of a tag object (id, value, object_type, optional hex_color).
export interface Tag { id: string; value: string; object_type: 'account' | 'issue' | 'contact'; hex_color?: string; }