quantix-mcp 0.4.5 → 0.4.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (84) hide show
  1. package/.claude/commands/opsx/apply.md +152 -0
  2. package/.claude/commands/opsx/archive.md +157 -0
  3. package/.claude/commands/opsx/bulk-archive.md +242 -0
  4. package/.claude/commands/opsx/continue.md +114 -0
  5. package/.claude/commands/opsx/explore.md +174 -0
  6. package/.claude/commands/opsx/ff.md +94 -0
  7. package/.claude/commands/opsx/new.md +69 -0
  8. package/.claude/commands/opsx/onboard.md +525 -0
  9. package/.claude/commands/opsx/sync.md +134 -0
  10. package/.claude/commands/opsx/verify.md +164 -0
  11. package/.claude/skills/openspec-apply-change/SKILL.md +156 -0
  12. package/.claude/skills/openspec-archive-change/SKILL.md +114 -0
  13. package/.claude/skills/openspec-bulk-archive-change/SKILL.md +246 -0
  14. package/.claude/skills/openspec-continue-change/SKILL.md +118 -0
  15. package/.claude/skills/openspec-explore/SKILL.md +290 -0
  16. package/.claude/skills/openspec-ff-change/SKILL.md +101 -0
  17. package/.claude/skills/openspec-new-change/SKILL.md +74 -0
  18. package/.claude/skills/openspec-onboard/SKILL.md +529 -0
  19. package/.claude/skills/openspec-sync-specs/SKILL.md +138 -0
  20. package/.claude/skills/openspec-verify-change/SKILL.md +168 -0
  21. package/.gemini/commands/opsx/apply.toml +149 -0
  22. package/.gemini/commands/opsx/archive.toml +154 -0
  23. package/.gemini/commands/opsx/bulk-archive.toml +239 -0
  24. package/.gemini/commands/opsx/continue.toml +111 -0
  25. package/.gemini/commands/opsx/explore.toml +171 -0
  26. package/.gemini/commands/opsx/ff.toml +91 -0
  27. package/.gemini/commands/opsx/new.toml +66 -0
  28. package/.gemini/commands/opsx/onboard.toml +522 -0
  29. package/.gemini/commands/opsx/sync.toml +131 -0
  30. package/.gemini/commands/opsx/verify.toml +161 -0
  31. package/.gemini/skills/openspec-apply-change/SKILL.md +156 -0
  32. package/.gemini/skills/openspec-archive-change/SKILL.md +114 -0
  33. package/.gemini/skills/openspec-bulk-archive-change/SKILL.md +246 -0
  34. package/.gemini/skills/openspec-continue-change/SKILL.md +118 -0
  35. package/.gemini/skills/openspec-explore/SKILL.md +290 -0
  36. package/.gemini/skills/openspec-ff-change/SKILL.md +101 -0
  37. package/.gemini/skills/openspec-new-change/SKILL.md +74 -0
  38. package/.gemini/skills/openspec-onboard/SKILL.md +529 -0
  39. package/.gemini/skills/openspec-sync-specs/SKILL.md +138 -0
  40. package/.gemini/skills/openspec-verify-change/SKILL.md +168 -0
  41. package/.qwen/commands/opsx-apply.toml +149 -0
  42. package/.qwen/commands/opsx-archive.toml +154 -0
  43. package/.qwen/commands/opsx-bulk-archive.toml +239 -0
  44. package/.qwen/commands/opsx-continue.toml +111 -0
  45. package/.qwen/commands/opsx-explore.toml +171 -0
  46. package/.qwen/commands/opsx-ff.toml +91 -0
  47. package/.qwen/commands/opsx-new.toml +66 -0
  48. package/.qwen/commands/opsx-onboard.toml +522 -0
  49. package/.qwen/commands/opsx-sync.toml +131 -0
  50. package/.qwen/commands/opsx-verify.toml +161 -0
  51. package/.qwen/skills/openspec-apply-change/SKILL.md +156 -0
  52. package/.qwen/skills/openspec-archive-change/SKILL.md +114 -0
  53. package/.qwen/skills/openspec-bulk-archive-change/SKILL.md +246 -0
  54. package/.qwen/skills/openspec-continue-change/SKILL.md +118 -0
  55. package/.qwen/skills/openspec-explore/SKILL.md +290 -0
  56. package/.qwen/skills/openspec-ff-change/SKILL.md +101 -0
  57. package/.qwen/skills/openspec-new-change/SKILL.md +74 -0
  58. package/.qwen/skills/openspec-onboard/SKILL.md +529 -0
  59. package/.qwen/skills/openspec-sync-specs/SKILL.md +138 -0
  60. package/.qwen/skills/openspec-verify-change/SKILL.md +168 -0
  61. package/AGENTS.md +117 -0
  62. package/GEMINI.md +59 -0
  63. package/QWEN.md +117 -0
  64. package/dist/tools/transactions.d.ts.map +1 -1
  65. package/dist/tools/transactions.js +33 -3
  66. package/dist/tools/transactions.js.map +1 -1
  67. package/dist/types/schemas.d.ts +66 -7
  68. package/dist/types/schemas.d.ts.map +1 -1
  69. package/dist/types/schemas.js +36 -10
  70. package/dist/types/schemas.js.map +1 -1
  71. package/openapi.yaml +212 -54
  72. package/openspec/changes/separate-credit-card-transaction-tools/.openspec.yaml +2 -0
  73. package/openspec/changes/separate-credit-card-transaction-tools/design.md +60 -0
  74. package/openspec/changes/separate-credit-card-transaction-tools/proposal.md +25 -0
  75. package/openspec/changes/separate-credit-card-transaction-tools/specs/credit-card-transactions/spec.md +46 -0
  76. package/openspec/changes/separate-credit-card-transaction-tools/specs/transactions/spec.md +42 -0
  77. package/openspec/changes/separate-credit-card-transaction-tools/tasks.md +22 -0
  78. package/openspec/config.yaml +20 -0
  79. package/package.json +1 -1
  80. package/src/tools/transactions.ts +47 -3
  81. package/src/types/schemas.ts +40 -10
  82. package/tests/tools/accounts.test.ts +1 -1
  83. package/tests/tools/credit-cards.test.ts +1 -1
  84. package/tests/tools/transactions.test.ts +1 -1
@@ -0,0 +1,46 @@
1
+ ## ADDED Requirements
2
+
3
+ ### Requirement: Create credit card transaction
4
+ The system SHALL provide a `create_credit_transaction` tool that sends a POST request to `/transactions/credit` with a schema specific to credit card transactions.
5
+
6
+ #### Scenario: Successful creation
7
+ - **WHEN** the user provides `name`, `amount`, `purchaseDate`, and `creditCardId`
8
+ - **THEN** the system calls `POST /transactions/credit` and returns the created transaction
9
+
10
+ #### Scenario: Creation with installments
11
+ - **WHEN** the user provides `installments` > 1
12
+ - **THEN** the transaction is split into installments with the due date calculated from the card closing day
13
+
14
+ #### Scenario: Creation with target due month
15
+ - **WHEN** the user provides `targetDueMonth` in YYYY-MM format
16
+ - **THEN** the first installment's due date is set to the target month
17
+
18
+ #### Scenario: Creation with recurrence
19
+ - **WHEN** the user provides `recurrence` with one of the 7 supported frequencies (WEEKLY, BIWEEKLY, MONTHLY, BIMONTHLY, QUARTERLY, SEMIANNUALLY, ANNUALLY)
20
+ - **THEN** the system includes the recurrence object in the request body
21
+
22
+ ### Requirement: Update credit card transaction
23
+ The system SHALL provide an `update_credit_transaction` tool that sends a PATCH request to `/transactions/credit/:id` with a schema specific to credit card transactions.
24
+
25
+ #### Scenario: Successful update
26
+ - **WHEN** the user provides a valid transaction ID and one or more updateable fields
27
+ - **THEN** the system calls `PATCH /transactions/credit/:id` and returns the updated transaction
28
+
29
+ #### Scenario: Recalculation of due date
30
+ - **WHEN** the user changes `purchaseDate` or `targetDueMonth`
31
+ - **THEN** the due date is recalculated by the API
32
+
33
+ #### Scenario: Update with recurrence
34
+ - **WHEN** the user modifies the `recurrence` field
35
+ - **THEN** the recurrence object is updated with one of the 7 supported frequencies
36
+
37
+ ### Requirement: Credit card transaction input schema
38
+ The input schema for credit card transaction tools SHALL include the following fields: `name` (required), `amount` (required, min 0), `purchaseDate` (required, YYYY-MM-DD), `creditCardId` (required), `categoryId` (optional), `installments` (optional, min 1), `targetDueMonth` (optional, YYYY-MM), `isPaid` (optional, default false), `recurrence` (optional, CreditCardRecurrenceDto with 7 frequencies).
39
+
40
+ #### Scenario: Validation rejects missing required fields
41
+ - **WHEN** any of `name`, `amount`, `purchaseDate`, or `creditCardId` is missing
42
+ - **THEN** the MCP SDK rejects the input with a validation error
43
+
44
+ #### Scenario: Validation rejects invalid frequency
45
+ - **WHEN** the user provides a recurrence frequency not in the 7 supported values
46
+ - **THEN** the input is rejected by the Zod schema
@@ -0,0 +1,42 @@
1
+ ## ADDED Requirements
2
+
3
+ ### Requirement: Create direct transaction only
4
+ The `create_transaction` tool SHALL only support direct payment methods: CASH, PIX, and DEBIT. It SHALL send a POST request to `/transactions` and SHALL NOT accept credit-card-specific fields.
5
+
6
+ #### Scenario: Successful direct transaction creation
7
+ - **WHEN** the user provides `type`, `name`, `amount`, `date`, `paymentMethod` (CASH, PIX, or DEBIT), and `accountId`
8
+ - **THEN** the system calls `POST /transactions` and returns the created transaction
9
+
10
+ #### Scenario: Validation rejects credit card fields
11
+ - **WHEN** the user attempts to provide `creditCardId`, `targetDueMonth`, or `purchaseDate`
12
+ - **THEN** the Zod schema rejects the input as those fields are not part of the direct transaction schema
13
+
14
+ #### Scenario: Validation rejects CREDIT payment method
15
+ - **WHEN** the user provides `paymentMethod` as "CREDIT"
16
+ - **THEN** the Zod schema rejects the input as the enum only allows CASH, PIX, DEBIT
17
+
18
+ ### Requirement: Update direct transaction only
19
+ The `update_transaction` tool SHALL only support updating direct payment method transactions. It SHALL send a PATCH request to `/transactions/:id` and SHALL NOT accept credit-card-specific fields.
20
+
21
+ #### Scenario: Successful direct transaction update
22
+ - **WHEN** the user provides a valid transaction ID and one or more updateable fields (type, name, amount, date, categoryId, paymentMethod, accountId, isPaid)
23
+ - **THEN** the system calls `PATCH /transactions/:id` and returns the updated transaction
24
+
25
+ #### Scenario: Recurring transaction update mode
26
+ - **WHEN** the user provides `mode` as SINGLE, PENDING, or ALL
27
+ - **THEN** the update is applied according to the mode (only this transaction, this and future pending, or all in the series)
28
+
29
+ #### Scenario: Validation rejects credit card fields
30
+ - **WHEN** the user attempts to provide `creditCardId`, `targetDueMonth`, or `purchaseDate`
31
+ - **THEN** the Zod schema rejects the input as those fields are not part of the direct transaction schema
32
+
33
+ ### Requirement: Direct transaction recurrence
34
+ The recurrence for direct transactions SHALL support only 3 frequencies: WEEKLY, MONTHLY, YEARLY.
35
+
36
+ #### Scenario: Valid recurrence frequencies
37
+ - **WHEN** the user provides a recurrence with WEEKLY, MONTHLY, or YEARLY
38
+ - **THEN** the request is accepted
39
+
40
+ #### Scenario: Invalid recurrence frequency
41
+ - **WHEN** the user provides BIWEEKLY, BIMONTHLY, QUARTERLY, SEMIANNUALLY, or ANNUALLY
42
+ - **THEN** the Zod schema rejects the input
@@ -0,0 +1,22 @@
1
+ ## 1. Schema definitions
2
+
3
+ - [x] 1.1 Create `CreditCardRecurrenceSchema` in `src/types/schemas.ts` with 7 frequencies (WEEKLY, BIWEEKLY, MONTHLY, BIMONTHLY, QUARTERLY, SEMIANNUALLY, ANNUALLY)
4
+ - [x] 1.2 Create `CreateCreditCardTransactionInput` schema with required fields (name, amount, purchaseDate, creditCardId) and optional fields (categoryId, installments, targetDueMonth, isPaid, recurrence)
5
+ - [x] 1.3 Create `UpdateCreditCardTransactionInput` schema with all fields optional
6
+ - [x] 1.4 Remove `paymentMethod: "CREDIT"`, `creditCardId`, `targetDueMonth` from `CreateTransactionInput`; keep `installments`
7
+ - [x] 1.5 Remove `paymentMethod: "CREDIT"`, `creditCardId`, `targetDueMonth`, `purchaseDate` from `UpdateTransactionInput`; keep `installments`
8
+
9
+ ## 2. Transaction tools (direct payments)
10
+
11
+ - [x] 2.1 Update `create_transaction` tool to POST to `/transactions` with cleaned schema; update description to clarify "CASH, PIX, or DEBIT only"
12
+ - [x] 2.2 Update `update_transaction` tool to PATCH `/transactions/:id` with cleaned schema; update description to clarify "CASH, PIX, or DEBIT only"
13
+
14
+ ## 3. Credit card transaction tools (new)
15
+
16
+ - [x] 3.1 Register `create_credit_transaction` tool that POSTs to `/transactions/credit` with `CreateCreditCardTransactionInput` schema
17
+ - [x] 3.2 Register `update_credit_transaction` tool that PATCHes `/transactions/credit/:id` with `UpdateCreditCardTransactionInput` schema
18
+
19
+ ## 4. Verification
20
+
21
+ - [x] 4.1 Run `npm run build` and confirm no TypeScript errors
22
+ - [x] 4.2 Run `npm test` and confirm all tests pass
@@ -0,0 +1,20 @@
1
+ schema: spec-driven
2
+
3
+ # Project context (optional)
4
+ # This is shown to AI when creating artifacts.
5
+ # Add your tech stack, conventions, style guides, domain knowledge, etc.
6
+ # Example:
7
+ # context: |
8
+ # Tech stack: TypeScript, React, Node.js
9
+ # We use conventional commits
10
+ # Domain: e-commerce platform
11
+
12
+ # Per-artifact rules (optional)
13
+ # Add custom rules for specific artifacts.
14
+ # Example:
15
+ # rules:
16
+ # proposal:
17
+ # - Keep proposals under 500 words
18
+ # - Always include a "Non-goals" section
19
+ # tasks:
20
+ # - Break tasks into chunks of max 2 hours
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "quantix-mcp",
3
- "version": "0.4.5",
3
+ "version": "0.4.6",
4
4
  "type": "module",
5
5
  "bin": {
6
6
  "quantix-mcp": "./dist/index.js"
@@ -1,6 +1,12 @@
1
1
  import { McpServer } from '@modelcontextprotocol/sdk/server/mcp.js';
2
2
  import { z } from 'zod';
3
- import { CreateTransactionInput, GetTransactionsInput, UpdateTransactionInput } from '../types/schemas.js';
3
+ import {
4
+ CreateTransactionInput,
5
+ GetTransactionsInput,
6
+ UpdateTransactionInput,
7
+ CreateCreditCardTransactionInput,
8
+ UpdateCreditCardTransactionInput
9
+ } from '../types/schemas.js';
4
10
  import { apiClient } from '../services/apiClient.js';
5
11
  import { handleToolError } from '../utils/toolHelpers.js';
6
12
 
@@ -9,7 +15,7 @@ export function registerTransactionTools(server: McpServer) {
9
15
  'create_transaction',
10
16
  {
11
17
  title: 'Create Transaction',
12
- description: 'Record a new income or expense (DEBIT|CREDIT|PIX|CASH)',
18
+ description: 'Record a new income or expense using direct payment methods (CASH, PIX, or DEBIT only). For credit card purchases, use create_credit_transaction instead.',
13
19
  inputSchema: CreateTransactionInput
14
20
  },
15
21
  async (args) => {
@@ -77,7 +83,7 @@ export function registerTransactionTools(server: McpServer) {
77
83
  'update_transaction',
78
84
  {
79
85
  title: 'Update Transaction',
80
- description: 'Update a transaction',
86
+ description: 'Update a transaction using direct payment methods (CASH, PIX, or DEBIT only). For credit card transactions, use update_credit_transaction instead.',
81
87
  inputSchema: UpdateTransactionInput
82
88
  },
83
89
  async ({ id, mode, ...data }) => {
@@ -153,4 +159,42 @@ export function registerTransactionTools(server: McpServer) {
153
159
  }
154
160
  }
155
161
  );
162
+
163
+ server.registerTool(
164
+ 'create_credit_transaction',
165
+ {
166
+ title: 'Create Credit Card Transaction',
167
+ description: 'Record a new credit card purchase. The due date is automatically calculated based on the purchase date and the card closing day. Use targetDueMonth to specify a particular billing month.',
168
+ inputSchema: CreateCreditCardTransactionInput
169
+ },
170
+ async (args) => {
171
+ try {
172
+ const transaction = await apiClient.post('/transactions/credit', args);
173
+ return {
174
+ content: [{ type: 'text', text: `Credit card transaction created: ${JSON.stringify(transaction, null, 2)}` }]
175
+ };
176
+ } catch (error) {
177
+ return handleToolError(error);
178
+ }
179
+ }
180
+ );
181
+
182
+ server.registerTool(
183
+ 'update_credit_transaction',
184
+ {
185
+ title: 'Update Credit Card Transaction',
186
+ description: 'Update a credit card transaction. If purchaseDate or targetDueMonth is changed, the due date is recalculated.',
187
+ inputSchema: UpdateCreditCardTransactionInput
188
+ },
189
+ async ({ id, ...data }) => {
190
+ try {
191
+ const transaction = await apiClient.patch(`/transactions/credit/${id}`, data);
192
+ return {
193
+ content: [{ type: 'text', text: `Credit card transaction updated: ${JSON.stringify(transaction, null, 2)}` }]
194
+ };
195
+ } catch (error) {
196
+ return handleToolError(error);
197
+ }
198
+ }
199
+ );
156
200
  }
@@ -158,11 +158,9 @@ export const CreateTransactionInput = z.object({
158
158
  amount: z.number().nonnegative().describe("Transaction amount (required — must ask the user if not provided, do not assume or default)"),
159
159
  date: z.string().describe("ISO date string YYYY-MM-DD"),
160
160
  categoryId: z.string().describe("ID da categoria associada (use a ferramenta get_categories para encontrar o ID correto)").optional(),
161
- paymentMethod: z.enum(["CASH", "PIX", "DEBIT", "CREDIT"]).optional(),
162
- creditCardId: z.string().describe("ID do cartão de crédito (obrigatório se o método de pagamento for CREDIT; use get_credit_cards para encontrar o ID)").optional(),
163
- accountId: z.string().describe("ID da conta bancária (obrigatório se o método de pagamento NÃO for CREDIT; use get_accounts para encontrar o ID)").optional(),
161
+ paymentMethod: z.enum(["CASH", "PIX", "DEBIT"]).describe("Método de pagamento direto (CASH, PIX ou DEBIT — para cartão de crédito, use create_credit_transaction)").optional(),
162
+ accountId: z.string().describe("ID da conta bancária (use get_accounts para encontrar o ID)").optional(),
164
163
  installments: z.number().int().min(1).optional(),
165
- targetDueMonth: z.string().regex(/^\d{4}-\d{2}$/).optional(),
166
164
  isPaid: z.boolean().describe("Indica se a transação já foi paga ou recebida (use este campo em vez de 'paid')").optional(),
167
165
  recurrence: z.object({
168
166
  frequency: z.enum(["MONTHLY", "WEEKLY", "YEARLY"]),
@@ -178,15 +176,12 @@ export const UpdateTransactionInput = z.object({
178
176
  type: z.enum(["INCOME", "EXPENSE"]).optional(),
179
177
  name: z.string().optional(),
180
178
  amount: z.number().nonnegative().optional(),
181
- date: z.string().describe("ISO date string YYYY-MM-DD").optional().describe("Date of the transaction (if CREDIT paymentMethod, this represents the due date of credit card statement)"),
179
+ date: z.string().describe("ISO date string YYYY-MM-DD").optional(),
182
180
  categoryId: z.string().describe("ID da categoria associada (use a ferramenta get_categories para encontrar o ID correto)").optional(),
183
- paymentMethod: z.enum(["CASH", "PIX", "DEBIT", "CREDIT"]).optional(),
184
- creditCardId: z.string().describe("ID do cartão de crédito (obrigatório se o método de pagamento for CREDIT; use get_credit_cards para encontrar o ID)").optional(),
185
- accountId: z.string().describe("ID da conta bancária (obrigatório se o método de pagamento NÃO for CREDIT; use get_accounts para encontrar o ID)").optional(),
181
+ paymentMethod: z.enum(["CASH", "PIX", "DEBIT"]).describe("Método de pagamento direto (CASH, PIX ou DEBIT — para cartão de crédito, use update_credit_transaction)").optional(),
182
+ accountId: z.string().describe("ID da conta bancária (use get_accounts para encontrar o ID)").optional(),
186
183
  installments: z.number().int().min(1).optional(),
187
- targetDueMonth: z.string().regex(/^\d{4}-\d{2}$/).optional(),
188
184
  isPaid: z.boolean().optional(),
189
- purchaseDate: z.string().regex(/^\d{4}-\d{2}-\d{2}$/).describe("Purchase date (CREDIT paymentMethod only), YYYY-MM-DD").optional(),
190
185
  recurrence: z.object({
191
186
  frequency: z.enum(["MONTHLY", "WEEKLY", "YEARLY"]).optional(),
192
187
  interval: z.number().int().min(1).optional(),
@@ -195,6 +190,41 @@ export const UpdateTransactionInput = z.object({
195
190
  }).optional()
196
191
  });
197
192
 
193
+ // --- Credit Card Transaction Tool Inputs ---
194
+
195
+ export const CreditCardRecurrenceSchema = z.object({
196
+ frequency: z.enum(["WEEKLY", "BIWEEKLY", "MONTHLY", "BIMONTHLY", "QUARTERLY", "SEMIANNUALLY", "ANNUALLY"]),
197
+ interval: z.number().int().min(1).default(1).optional(),
198
+ startDate: z.string().regex(/^\d{4}-\d{2}-\d{2}$/).describe("Start date for recurrence (defaults to purchase date)").optional(),
199
+ endDate: z.string().optional(),
200
+ occurrences: z.number().int().min(2).describe("Number of occurrences (optional)").optional()
201
+ });
202
+
203
+ export const CreateCreditCardTransactionInput = z.object({
204
+ name: z.string().describe("Name or description of the transaction"),
205
+ amount: z.number().min(0).describe("Total amount of the transaction (required — must ask the user if not provided, do not assume or default)"),
206
+ purchaseDate: z.string().regex(/^\d{4}-\d{2}-\d{2}$/, "Purchase date in YYYY-MM-DD format").describe("Actual purchase date (the day you bought the item)"),
207
+ creditCardId: z.string().describe("ID of the credit card to charge (use get_credit_cards to find the ID)"),
208
+ categoryId: z.string().describe("ID of the associated category (use get_categories to find the ID)").optional(),
209
+ installments: z.number().int().min(1).describe("Number of installments (optional)").optional(),
210
+ targetDueMonth: z.string().regex(/^\d{4}-\d{2}$/, "Target month in YYYY-MM format").describe("Target month for due date (optional)").optional(),
211
+ isPaid: z.boolean().describe("Whether the transaction has been paid").optional(),
212
+ recurrence: CreditCardRecurrenceSchema.optional()
213
+ });
214
+
215
+ export const UpdateCreditCardTransactionInput = z.object({
216
+ id: z.string().describe("Credit card transaction ID"),
217
+ name: z.string().describe("Name or description of the transaction").optional(),
218
+ amount: z.number().min(0).describe("Total amount of the transaction").optional(),
219
+ purchaseDate: z.string().regex(/^\d{4}-\d{2}-\d{2}$/, "Purchase date in YYYY-MM-DD format").describe("Actual purchase date").optional(),
220
+ creditCardId: z.string().describe("ID of the credit card").optional(),
221
+ categoryId: z.string().describe("ID of the associated category").optional(),
222
+ installments: z.number().int().min(1).describe("Number of installments").optional(),
223
+ targetDueMonth: z.string().regex(/^\d{4}-\d{2}$/, "Target month in YYYY-MM format").describe("Target month for due date").optional(),
224
+ isPaid: z.boolean().optional(),
225
+ recurrence: CreditCardRecurrenceSchema.optional()
226
+ });
227
+
198
228
  export const CreateAccountInput = z.object({
199
229
  name: z.string(),
200
230
  type: z.enum(["BANK_ACCOUNT", "WALLET", "SAVINGS_ACCOUNT", "INVESTMENT_ACCOUNT", "OTHER"]),
@@ -38,7 +38,7 @@ describe('Account Tools', () => {
38
38
 
39
39
  it('should register all account tools', () => {
40
40
  registerAccountTools(mockServer);
41
- expect(mockServer.registerTool).toHaveBeenCalledTimes(7);
41
+ expect(mockServer.registerTool).toHaveBeenCalledTimes(6);
42
42
  expect(registeredTools['create_account']).toBeDefined();
43
43
  expect(registeredTools['get_accounts']).toBeDefined();
44
44
  expect(registeredTools['get_account']).toBeDefined();
@@ -38,7 +38,7 @@ describe('Credit Card Tools', () => {
38
38
 
39
39
  it('should register all credit card tools', () => {
40
40
  registerCreditCardTools(mockServer);
41
- expect(mockServer.registerTool).toHaveBeenCalledTimes(9);
41
+ expect(mockServer.registerTool).toHaveBeenCalledTimes(10);
42
42
  expect(registeredTools['create_credit_card']).toBeDefined();
43
43
  expect(registeredTools['get_credit_cards']).toBeDefined();
44
44
  expect(registeredTools['get_statement']).toBeDefined();
@@ -38,7 +38,7 @@ describe('Transaction Tools', () => {
38
38
 
39
39
  it('should register transaction tools', () => {
40
40
  registerTransactionTools(mockServer);
41
- expect(mockServer.registerTool).toHaveBeenCalledTimes(7); // create, get_all, get_one, update, pay, unpay, delete
41
+ expect(mockServer.registerTool).toHaveBeenCalledTimes(9); // create, get_all, get_one, update, pay, unpay, delete, create_credit, update_credit
42
42
  });
43
43
 
44
44
  describe('create_transaction', () => {