@nannykeeper/mcp-server 1.3.0 → 1.5.0
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.
- package/CLAUDE.md +13 -1
- package/README.md +23 -2
- package/dist/index.js +29 -7
- package/dist/tools/preview-payroll.d.ts +1 -1
- package/dist/tools/preview-payroll.js +2 -1
- package/dist/tools/run-payroll.d.ts +3 -1
- package/dist/tools/run-payroll.js +8 -1
- package/manifest.json +2 -2
- package/package.json +1 -1
package/CLAUDE.md
CHANGED
|
@@ -7,7 +7,19 @@ Calculate nanny taxes for all 50 US states.
|
|
|
7
7
|
- `calculate_nanny_taxes` — Full federal + state tax breakdown
|
|
8
8
|
- `check_threshold` — Whether wages trigger employer tax obligations
|
|
9
9
|
- `preview_payroll` — Dry-run payroll calc, returns taxes/net pay without creating a record (Starter+ required)
|
|
10
|
-
- `run_payroll` —
|
|
10
|
+
- `run_payroll` — End-to-end payroll: create, approve, and process (or schedule) in a single call. Finalized response reflects real status (`processing` / `pending_funding` / `completed` / **`scheduled`** as of 1.5.0). No UI intervention needed. (Starter+ required)
|
|
11
|
+
|
|
12
|
+
## Pay-date handling (run_payroll, preview_payroll)
|
|
13
|
+
- `pay_date` is optional. When omitted, the server picks the earliest valid pay date based on ACH submission lead time (5 business days ahead, holiday-aware) and echoes it back in the response.
|
|
14
|
+
- If `pay_date` is supplied and past the submission deadline, the API rejects with HTTP 400 and includes `next_valid_pay_date` in the error details for self-correction.
|
|
15
|
+
- **v1.5.0**: If `pay_date` is more than 5 business days in the future on a DD payroll, the response status is `scheduled`. The payroll will auto-fire at `scheduled_send_at` (5 biz days before `pay_date`). The `net_pay` and tax amounts in the response are estimates — they're recomputed at fire time if YTD or rate configs changed. `is_estimated: true` is set when this happens so callers can surface that to users.
|
|
16
|
+
|
|
17
|
+
## Confirmation flags (run_payroll)
|
|
18
|
+
API callers with direct-deposit payments must tick the same safety gates the UI does:
|
|
19
|
+
- `confirm_large_payroll: true` when total net pay >$5,000 OR any single net pay >$3,000
|
|
20
|
+
- `confirm_ach_debit: true` for the first-ever DD payroll on an employer, or when >30 days have elapsed since the last DD authorization
|
|
21
|
+
|
|
22
|
+
These flags exist even for server-to-server callers as a safety measure. Agents should only set them after verifying the amounts with the user.
|
|
11
23
|
|
|
12
24
|
## Setup
|
|
13
25
|
Requires API key (free): https://www.nannykeeper.com/developers/keys
|
package/README.md
CHANGED
|
@@ -46,22 +46,43 @@ Check if annual wages cross the household employer tax threshold.
|
|
|
46
46
|
- `annual_wages` (required) — Annual wages to check
|
|
47
47
|
- `tax_year` (optional) — Tax year (default: current year)
|
|
48
48
|
|
|
49
|
+
### `preview_payroll`
|
|
50
|
+
|
|
51
|
+
Dry-run payroll calculation. Returns the full tax breakdown, net pay, and employer costs WITHOUT creating a payroll record. Use to validate your request before calling `run_payroll`. Requires a Starter+ subscription.
|
|
52
|
+
|
|
53
|
+
**Parameters:**
|
|
54
|
+
- `employer_id` (required) — Employer UUID from your NannyKeeper account
|
|
55
|
+
- `employee_id` (required) — Employee UUID
|
|
56
|
+
- `pay_period_start` (required) — Start of pay period (YYYY-MM-DD)
|
|
57
|
+
- `pay_period_end` (required) — End of pay period (YYYY-MM-DD)
|
|
58
|
+
- `pay_date` (optional) — Date employee is paid (YYYY-MM-DD). When omitted, the server picks the earliest valid pay date based on ACH submission lead time and echoes it back in the response.
|
|
59
|
+
- `pay_frequency` (required) — weekly, biweekly, semimonthly, or monthly
|
|
60
|
+
- `regular_hours` (optional) — Regular hours worked
|
|
61
|
+
- `overtime_hours` (optional) — Overtime hours worked
|
|
62
|
+
- `bonus` (optional) — Bonus amount
|
|
63
|
+
- `other_earnings` (optional) — Other earnings
|
|
64
|
+
|
|
49
65
|
### `run_payroll`
|
|
50
66
|
|
|
51
|
-
Run payroll for a household employee
|
|
67
|
+
Run payroll for a household employee **end-to-end in a single call** — creates, approves, and processes (or schedules) the payroll. Response reflects the finalized status (`processing`, `pending_funding`, `completed`, or `scheduled` as of v1.5.0); no dashboard intervention needed. Requires a Starter+ subscription.
|
|
68
|
+
|
|
69
|
+
**Scheduled payrolls (v1.5.0):** When `pay_date` is more than 5 business days in the future on a direct-deposit payroll, the response status is `scheduled`. Two additional fields come back: `scheduled_send_at` (ISO UTC timestamp — when the payroll will auto-fire) and `is_estimated: true` (the returned net pay and tax amounts will be recomputed against current YTD and rate configs at fire time, so they may shift slightly). In-window pay dates fire immediately as before.
|
|
52
70
|
|
|
53
71
|
**Parameters:**
|
|
54
72
|
- `employer_id` (required) — Employer UUID from your NannyKeeper account
|
|
55
73
|
- `employee_id` (required) — Employee UUID to run payroll for
|
|
56
74
|
- `pay_period_start` (required) — Start of pay period (YYYY-MM-DD)
|
|
57
75
|
- `pay_period_end` (required) — End of pay period (YYYY-MM-DD)
|
|
58
|
-
- `pay_date` (
|
|
76
|
+
- `pay_date` (optional) — Date employee is paid (YYYY-MM-DD). When omitted, the server picks the earliest valid pay date from today + ACH submission lead time. If supplied and past the submission deadline, the request is rejected with HTTP 400 + `next_valid_pay_date` in the error details so you can retry with a valid date.
|
|
59
77
|
- `pay_frequency` (required) — weekly, biweekly, semimonthly, or monthly
|
|
60
78
|
- `regular_hours` (optional) — Regular hours worked
|
|
61
79
|
- `overtime_hours` (optional) — Overtime hours worked
|
|
62
80
|
- `bonus` (optional) — Bonus amount
|
|
81
|
+
- `other_earnings` (optional) — Other earnings
|
|
63
82
|
- `payment_method` (optional) — direct_deposit, check, or cash (default: check)
|
|
64
83
|
- `notes` (optional) — Use "catch-up" for retroactive payrolls
|
|
84
|
+
- `confirm_large_payroll` (optional) — Required for direct-deposit payrolls with total net pay >$5,000 or any single net pay >$3,000
|
|
85
|
+
- `confirm_ach_debit` (optional) — Required for first-ever DD payroll or when >30 days have elapsed since the last DD authorization
|
|
65
86
|
- `idempotency_key` (optional) — Prevent duplicate payroll creation
|
|
66
87
|
|
|
67
88
|
## Examples
|
package/dist/index.js
CHANGED
|
@@ -69,13 +69,17 @@ server.tool("preview_payroll", "Preview payroll for a household employee WITHOUT
|
|
|
69
69
|
"Returns the full tax breakdown (federal, state, FICA, FUTA), net pay, and employer costs. " +
|
|
70
70
|
"Use this to validate your request before calling run_payroll. " +
|
|
71
71
|
"Same parameters as run_payroll. Requires a Starter+ subscription. " +
|
|
72
|
+
"pay_date is optional — when omitted, the server picks the earliest valid pay date " +
|
|
73
|
+
"based on ACH submission lead time and echoes it back in the response. " +
|
|
74
|
+
"v1.5.0: if pay_date is more than 5 business days in the future, the response includes " +
|
|
75
|
+
"is_estimated=true — those numbers will be recomputed at fire time if the user schedules. " +
|
|
72
76
|
"To get your employer_id and employee_id, call the NannyKeeper API: " +
|
|
73
77
|
"GET /api/v1/employees?employer_id=YOUR_ID (employer_id is visible in your dashboard URL).", {
|
|
74
78
|
employer_id: z.string().uuid().describe("Employer UUID — visible in your NannyKeeper dashboard URL or from GET /api/v1/employees"),
|
|
75
79
|
employee_id: z.string().uuid().describe("Employee UUID — from GET /api/v1/employees response"),
|
|
76
80
|
pay_period_start: z.string().describe("Start of pay period in YYYY-MM-DD format (e.g., 2026-04-07)"),
|
|
77
81
|
pay_period_end: z.string().describe("End of pay period in YYYY-MM-DD format (e.g., 2026-04-13)"),
|
|
78
|
-
pay_date: z.string().describe("Date employee is paid
|
|
82
|
+
pay_date: z.string().optional().describe("Date employee is paid (YYYY-MM-DD). Optional — server picks the earliest valid date if omitted."),
|
|
79
83
|
pay_frequency: z
|
|
80
84
|
.enum(["weekly", "biweekly", "semimonthly", "monthly"])
|
|
81
85
|
.describe("How often the employee is paid"),
|
|
@@ -94,11 +98,21 @@ server.tool("preview_payroll", "Preview payroll for a household employee WITHOUT
|
|
|
94
98
|
return { content: [{ type: "text", text: result }] };
|
|
95
99
|
});
|
|
96
100
|
// Register run_payroll tool
|
|
97
|
-
server.tool("run_payroll", "Run payroll for a household employee
|
|
98
|
-
"with year-to-date
|
|
99
|
-
"
|
|
100
|
-
"
|
|
101
|
-
"
|
|
101
|
+
server.tool("run_payroll", "Run payroll for a household employee end-to-end in a single call. Creates the " +
|
|
102
|
+
"record, runs all tax calculations (federal, state, FICA, FUTA) with year-to-date " +
|
|
103
|
+
"tracking, approves the payroll, and kicks off payment processing. " +
|
|
104
|
+
"Returns the finalized status (processing/pending_funding/completed/scheduled) plus full tax breakdown, " +
|
|
105
|
+
"net pay, employer costs, and the payroll ID for reference. " +
|
|
106
|
+
"Requires a Starter+ subscription. " +
|
|
107
|
+
"pay_date is optional — when omitted, the server picks the earliest valid pay date " +
|
|
108
|
+
"based on ACH submission lead time and echoes it back. If supplied and past the " +
|
|
109
|
+
"submission deadline, the request is rejected with next_valid_pay_date in the error. " +
|
|
110
|
+
"If pay_date is more than 5 business days in the future on a DD payroll, status=scheduled " +
|
|
111
|
+
"and the payroll will auto-fire at scheduled_send_at (5 biz days before pay_date). " +
|
|
112
|
+
"Scheduled responses include is_estimated=true — numbers may shift slightly at fire time " +
|
|
113
|
+
"if YTD or rate configs change between approve and fire. " +
|
|
114
|
+
"Direct deposit callers: set confirm_large_payroll=true for totals >$5,000 or any single " +
|
|
115
|
+
"net pay >$3,000; set confirm_ach_debit=true for first-time DD or if no DD in 30 days. " +
|
|
102
116
|
"Tip: use preview_payroll first to validate your request and see results before committing. " +
|
|
103
117
|
"To get your employer_id and employee_id, call the NannyKeeper API: " +
|
|
104
118
|
"GET /api/v1/employees?employer_id=YOUR_ID (employer_id is visible in your dashboard URL).", {
|
|
@@ -106,7 +120,7 @@ server.tool("run_payroll", "Run payroll for a household employee. Calculates all
|
|
|
106
120
|
employee_id: z.string().uuid().describe("Employee UUID — from GET /api/v1/employees response"),
|
|
107
121
|
pay_period_start: z.string().describe("Start of pay period in YYYY-MM-DD format (e.g., 2026-04-07)"),
|
|
108
122
|
pay_period_end: z.string().describe("End of pay period in YYYY-MM-DD format (e.g., 2026-04-13)"),
|
|
109
|
-
pay_date: z.string().describe("Date employee is paid
|
|
123
|
+
pay_date: z.string().optional().describe("Date employee is paid (YYYY-MM-DD). Optional — server picks the earliest valid date if omitted."),
|
|
110
124
|
pay_frequency: z
|
|
111
125
|
.enum(["weekly", "biweekly", "semimonthly", "monthly"])
|
|
112
126
|
.describe("How often the employee is paid"),
|
|
@@ -119,6 +133,14 @@ server.tool("run_payroll", "Run payroll for a household employee. Calculates all
|
|
|
119
133
|
.optional()
|
|
120
134
|
.describe("How the employee is paid (default: check)"),
|
|
121
135
|
notes: z.string().optional().describe("Notes (use 'catch-up' for retroactive payrolls that auto-complete)"),
|
|
136
|
+
confirm_large_payroll: z
|
|
137
|
+
.boolean()
|
|
138
|
+
.optional()
|
|
139
|
+
.describe("Required for direct-deposit payrolls with total net pay >$5,000 or any single net pay >$3,000."),
|
|
140
|
+
confirm_ach_debit: z
|
|
141
|
+
.boolean()
|
|
142
|
+
.optional()
|
|
143
|
+
.describe("Required for first-time direct-deposit payroll or when the last DD authorization is >30 days old."),
|
|
122
144
|
idempotency_key: z
|
|
123
145
|
.string()
|
|
124
146
|
.optional()
|
|
@@ -23,7 +23,8 @@ export async function executePreviewPayroll(args) {
|
|
|
23
23
|
employer_id: args.employer_id,
|
|
24
24
|
pay_period_start: args.pay_period_start,
|
|
25
25
|
pay_period_end: args.pay_period_end,
|
|
26
|
-
pay_date
|
|
26
|
+
// Omit pay_date when unset so the API computes a default
|
|
27
|
+
...(args.pay_date ? { pay_date: args.pay_date } : {}),
|
|
27
28
|
pay_frequency: args.pay_frequency,
|
|
28
29
|
employees: [
|
|
29
30
|
{
|
|
@@ -9,7 +9,7 @@ export declare function executeRunPayroll(args: {
|
|
|
9
9
|
employee_id: string;
|
|
10
10
|
pay_period_start: string;
|
|
11
11
|
pay_period_end: string;
|
|
12
|
-
pay_date
|
|
12
|
+
pay_date?: string;
|
|
13
13
|
pay_frequency: string;
|
|
14
14
|
regular_hours?: number;
|
|
15
15
|
overtime_hours?: number;
|
|
@@ -17,5 +17,7 @@ export declare function executeRunPayroll(args: {
|
|
|
17
17
|
other_earnings?: number;
|
|
18
18
|
payment_method?: string;
|
|
19
19
|
notes?: string;
|
|
20
|
+
confirm_large_payroll?: boolean;
|
|
21
|
+
confirm_ach_debit?: boolean;
|
|
20
22
|
idempotency_key?: string;
|
|
21
23
|
}): Promise<string>;
|
|
@@ -27,7 +27,8 @@ export async function executeRunPayroll(args) {
|
|
|
27
27
|
employer_id: args.employer_id,
|
|
28
28
|
pay_period_start: args.pay_period_start,
|
|
29
29
|
pay_period_end: args.pay_period_end,
|
|
30
|
-
pay_date
|
|
30
|
+
// Omit pay_date when unset so the API computes a default
|
|
31
|
+
...(args.pay_date ? { pay_date: args.pay_date } : {}),
|
|
31
32
|
pay_frequency: args.pay_frequency,
|
|
32
33
|
employees: [
|
|
33
34
|
{
|
|
@@ -40,6 +41,12 @@ export async function executeRunPayroll(args) {
|
|
|
40
41
|
},
|
|
41
42
|
],
|
|
42
43
|
notes: args.notes,
|
|
44
|
+
...(args.confirm_large_payroll !== undefined
|
|
45
|
+
? { confirm_large_payroll: args.confirm_large_payroll }
|
|
46
|
+
: {}),
|
|
47
|
+
...(args.confirm_ach_debit !== undefined
|
|
48
|
+
? { confirm_ach_debit: args.confirm_ach_debit }
|
|
49
|
+
: {}),
|
|
43
50
|
}),
|
|
44
51
|
});
|
|
45
52
|
const data = await response.json();
|
package/manifest.json
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"manifest_version": "0.3",
|
|
3
3
|
"name": "nannykeeper",
|
|
4
|
-
"version": "1.
|
|
5
|
-
"description": "Calculate US household employer (nanny) taxes
|
|
4
|
+
"version": "1.5.0",
|
|
5
|
+
"description": "Calculate US household employer (nanny) taxes for all 50 states. Preview and run payroll, generate W-2s and pay stubs. 4 tools: calculate, threshold, preview, run.",
|
|
6
6
|
"author": {
|
|
7
7
|
"name": "imaznation",
|
|
8
8
|
"url": "https://github.com/imaznation"
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nannykeeper/mcp-server",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.5.0",
|
|
4
4
|
"mcpName": "com.nannykeeper.www/mcp-server",
|
|
5
5
|
"description": "MCP server for calculating US household employer (nanny) taxes. All 50 states. Works with Claude, ChatGPT, and any MCP-compatible AI agent.",
|
|
6
6
|
"keywords": [
|