products_list
Retrieve available products and bundles from the Pickaxe studio to manage AI agent offerings and configurations.
Instructions
List all available products/bundles in the Pickaxe studio.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| studio | No | Studio name to use. Available: STAGING, MAIN, DEV, PRODUCTION. Default: PRODUCTION |
Implementation Reference
- src/index.ts:577-580 (handler)The handler function for the 'products_list' tool. It makes a GET request to the Pickaxe API endpoint '/studio/product/list' using the provided studio and returns the JSON-formatted result.case "products_list": { const result = await pickaxeRequest("/studio/product/list", "GET", undefined, studio); return JSON.stringify(result, null, 2); }
- src/index.ts:399-408 (registration)Registration of the 'products_list' tool in the tools array, including its name, description, and input schema which accepts an optional 'studio' parameter.{ name: "products_list", description: "List all available products/bundles in the Pickaxe studio.", inputSchema: { type: "object", properties: { studio: studioParam, }, }, },
- src/index.ts:402-407 (schema)Input schema definition for the 'products_list' tool, defining an optional 'studio' parameter.inputSchema: { type: "object", properties: { studio: studioParam, }, },
- src/index.ts:69-98 (helper)Helper function used by the handler to make authenticated API requests to Pickaxe, including the one for products_list.async function pickaxeRequest( endpoint: string, method: "GET" | "POST" | "PATCH" | "DELETE" = "GET", body?: Record<string, unknown>, studio?: string ): Promise<unknown> { const apiKey = getApiKey(studio); const url = endpoint.startsWith("http") ? endpoint : `${PICKAXE_BASE_URL}${endpoint}`; const options: RequestInit = { method, headers: { "Content-Type": "application/json", "Authorization": `Bearer ${apiKey}`, }, }; if (body && method !== "GET") { options.body = JSON.stringify(body); } const response = await fetch(url, options); if (!response.ok) { const errorText = await response.text(); throw new Error(`Pickaxe API error (${response.status}): ${errorText}`); } return response.json(); }