list_pinterest_boards
List Pinterest boards for a connected account by providing the account ID to retrieve board names and identifiers.
Instructions
List Pinterest boards for a connected Pinterest account
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| socialMediaId | Yes | Pinterest account ID (from list_accounts) |
Implementation Reference
- src/tools/accounts.ts:30-48 (registration)Registration of the 'list_pinterest_boards' tool via server.tool() with schema and handler.
server.tool( 'list_pinterest_boards', 'List Pinterest boards for a connected Pinterest account', { socialMediaId: z .string() .uuid() .describe('Pinterest account ID (from list_accounts)'), }, async (input) => { const data = await client.get<PinterestBoard[]>( `/social-media/${input.socialMediaId}/pinterest-boards`, ); return { content: [{ type: 'text' as const, text: JSON.stringify(data, null, 2) }], }; }, ); - src/tools/accounts.ts:39-47 (handler)Handler function for list_pinterest_boards: calls GET /social-media/{socialMediaId}/pinterest-boards and returns results as JSON text.
async (input) => { const data = await client.get<PinterestBoard[]>( `/social-media/${input.socialMediaId}/pinterest-boards`, ); return { content: [{ type: 'text' as const, text: JSON.stringify(data, null, 2) }], }; }, - src/tools/accounts.ts:33-38 (schema)Input schema for list_pinterest_boards: requires 'socialMediaId' (UUID) described as 'Pinterest account ID (from list_accounts)'.
{ socialMediaId: z .string() .uuid() .describe('Pinterest account ID (from list_accounts)'), }, - src/types.ts:62-68 (schema)PinterestBoard type definition with fields: id, boardId, name, description, imageUrl.
export interface PinterestBoard { id: string; boardId: string; name: string; description: string | null; imageUrl: string | null; } - src/index.ts:18-19 (registration)The registerAccountTools function (which registers list_pinterest_boards) is called in the main entry point.
registerAccountTools(server, client); registerFileTools(server, client);