UNPKG

@baruchiro/actual-mcp

Version:

Actual Budget MCP server exposing API functionality

24 lines 781 B
// ---------------------------- // UPDATE RULE TOOL // ---------------------------- import { successWithJson, errorFromCatch } from '../../../utils/response.js'; import { updateRule } from '../../../actual-api.js'; import { RuleInputSchema } from '../input-schema.js'; export const schema = { name: 'update-rule', description: 'Update a rule', inputSchema: RuleInputSchema, }; export async function handler(args) { try { if (!args.id || typeof args.id !== 'string') { return errorFromCatch('id is required and must be a string'); } await updateRule(args); return successWithJson('Successfully updated rule ' + args.id); } catch (err) { return errorFromCatch(err); } } //# sourceMappingURL=index.js.map