Get Cases
pega.get_casesRetrieve and list cases from Pega systems with optional limit parameter for managing case operations.
Instructions
Use this tool to list cases. Optional input: limit. Returns: { ok: true, data: { cases: [...] } } on success. Standard failure format: { ok: false, error: { code, message, suggestion? } }.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| limit | No | Optional max number of cases to return. |
Implementation Reference
- src/tools/getCases.ts:5-23 (handler)Definition and execution logic for pega.get_cases tool.
export const getCasesToolDefinition = defineTool({ name: "pega.get_cases", title: "Get Cases", description: [ "Use this tool to list cases.", "Optional input: limit.", "Returns: { ok: true, data: { cases: [...] } } on success." ].join(" "), inputSchema: getCasesSchema, invalidInputMessage: "Invalid input. Use optional field: limit", execute: async ({ pegaClient }, input) => { const cases = await pegaClient.getCases(); const limited = typeof input.limit === "number" ? cases.slice(0, input.limit) : cases; return toolSuccess({ cases: limited }); } });