get_payee_location
Retrieve specific payee location details by ID from YNAB budgets to track transaction origins and manage financial data.
Instructions
[1 API call] Get a single payee location by ID
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| budget_id | No | Budget ID or 'last-used' | last-used |
| payee_location_id | Yes | The payee location ID |
Implementation Reference
- src/tools/payee-locations.ts:28-46 (handler)The handler implementation and registration for the 'get_payee_location' MCP tool.
server.registerTool("get_payee_location", { title: "Get Payee Location", description: "[1 API call] Get a single payee location by ID", inputSchema: { budget_id: z.string().default("last-used").describe("Budget ID or 'last-used'"), payee_location_id: z.string().describe("The payee location ID"), }, annotations: { readOnlyHint: true }, }, async ({ budget_id, payee_location_id }) => { try { const response = await getClient().payeeLocations.getPayeeLocationById(budget_id, payee_location_id); const l = response.data.payee_location; return textResult( `Payee Location:\n Payee ID: ${l.payee_id}\n Latitude: ${l.latitude}\n Longitude: ${l.longitude}\n ID: ${l.id}` ); } catch (e: any) { return errorResult(e.message); } });