Get multiple coins
zora_get_coinsRetrieve multiple Zora Coins data by providing collection addresses and chain IDs to fetch token information from the Base mainnet.
Instructions
Batch fetch coins by address and chainId.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| coins | Yes |
Implementation Reference
- src/index.ts:117-138 (registration)Registration of the 'zora_get_coins' MCP tool, including input schema and inline handler function.
server.registerTool( "zora_get_coins", { title: "Get multiple coins", description: "Batch fetch coins by address and chainId.", inputSchema: { coins: z .array( z.object({ collectionAddress: z.string(), chainId: z.number().default(DEFAULT_CHAIN.id), }) ) .min(1), }, }, async ({ coins }) => { // @ts-expect-error - TypeScript can't resolve barrel exports properly const resp = await CoinsSDK.getCoins({ coins }); return { content: [{ type: "text", text: json(resp) }] }; } ); - src/index.ts:119-132 (schema)Input schema definition for the 'zora_get_coins' tool using Zod, specifying an array of coin objects with collectionAddress and optional chainId.
{ title: "Get multiple coins", description: "Batch fetch coins by address and chainId.", inputSchema: { coins: z .array( z.object({ collectionAddress: z.string(), chainId: z.number().default(DEFAULT_CHAIN.id), }) ) .min(1), }, }, - src/index.ts:133-137 (handler)Handler function for 'zora_get_coins' that delegates to CoinsSDK.getCoins and formats the response as MCP content.
async ({ coins }) => { // @ts-expect-error - TypeScript can't resolve barrel exports properly const resp = await CoinsSDK.getCoins({ coins }); return { content: [{ type: "text", text: json(resp) }] }; }