Tanda Workforce MCP Server
This server does not currently have a deployable release on Glama. Follow the repository's setup instructions to install and configure it for your MCP client, including any required credentials and local dependencies.
Tanda Workforce MCP Server v4.0.1
A read-only MCP (Model Context Protocol) server for the Tanda / Workforce.com API, with four guarded exceptions: creating employees, deactivating them, updating their pay rate and similar fields, and approving timesheets. It exposes 12 consolidated read tools and two read-only staffing apps (interactive MCP App views), plus four write tools (tanda_create_user, tanda_deactivate_user, tanda_update_user, tanda_approve_timesheets) when TANDA_WRITES_ENABLED=true. Every tool is privacy-filtered and returns at most 25 KB, so assistants like Claude can answer workforce questions without overflowing their context.
Security
Auth on every MCP route.
POST /mcp,GET /mcpandPOST /require an OAuth JWT orAuthorization: Bearer <MCP_SHARED_SECRET>. Unauthenticated calls get401.Read-only, with four guarded exceptions. The Tanda client refuses any non-GET request except
POST /users,POST /users/{id}/invite,DELETE /users/{id},PUT /users/{id},PUT /timesheets/{id}andPUT /shifts/{id}, and refuses those too unlessTANDA_WRITES_ENABLED=true(off by default).Least-privilege scopes. The server requests
me roster timesheet department user cost leave. It never requestsfinancialorpersonal.unavailabilityis off by default because Workforce.com's OAuth fails when it is requested; add it toTANDA_SCOPESonly if your OAuth app supports it.Privacy by default. User records are whitelisted, and
date_of_birth,phone,email,legal_*andhourly_rateare returned only when thefieldsparameter names them.passcode,tax_*,bank_*andsuper_*are never returned.
See docs/SECURITY.md.
Which Tanda identity each write tool may run as is set by ADR 0001.
Related MCP server: TrackingTime MCP
Tools (13)
Every list tool returns { summary, rows, page }. rows holds at most 50 entries and the whole response is at most 25 KB. When rows are cut, the response sets truncated: true and includes page.next_offset and a how_to_page hint. Time fields come as unix seconds plus *_iso strings in America/New_York, and hours is a decimal. from/to ranges up to 62 days are split into 7-day Tanda calls internally.
Tool | Returns / when to use |
| Locations with departments nested, staff counts, bookkeeping and Supervisor flags. Use it first to resolve names to ids. Cached for 24h, then revalidated with ETag. |
| Privacy-filtered staff, filtered by department, site, status or name. |
| Rostered shifts ( |
| Worked time from |
| Who is clocked in now ( |
|
|
| Scheduled vs actual hours and cost, with variance, grouped by |
| Supervisor coverage. |
| Checks proposed shifts against rosters, leave, unavailability, the 12h shift limit, the 40h week and double-booking. Each check fails soft: a missing scope skips that check and adds |
| Audit list: shifts open more than 12h, zero-length shifts, pending leave already in the past, unapproved timesheet $ by site, active staff with no award template, calendar workweeks over 40h, and |
| Payroll export preview with |
| Version history from |
| Data-quality audit in one call (at most 12 Tanda reads). For each check, a count plus up to 20 sample ids: active staff with no award template, no |
Staffing apps (conversation_to_site_schedule, staff_allocation_board)
Two read-only tools that render an interactive view in hosts that support MCP Apps (Claude does). Each returns a plain-text summary in content and the data in structuredContent; a host without MCP Apps still gets the summary. They only GET /locations, /departments, /users and /schedules. Nothing is written to Tanda, no shift is published and nobody is notified.
Tool | Returns / when to use |
| A draft weekly plan for a site from the fields of a client conversation: days, start and end time, cleaners per shift, supervisor checks, weekly and monthly labor hours, the Tanda site it matches by name, and suggested cleaners, supervisor and trainer. |
| A board of supervisors, trainers, cleaners and trainees to assign to a site, with a suggested team. |
How people are described and chosen:
Tenure is whole years and months since
employment_start_date, shown on every person astenure(years,months,total_months) andtenure_label(for example3y 2m). Someone with no start date hastenure: nulland is never counted as experienced.Load is the hours rostered for the whole target workweek (
WORKWEEK_START), read from every shift in that week, not one day or one page. The week is the one containingweek_of, or the one containing tomorrow.Supervisor: on the staff list of a
Supervisor/Supervisorsdepartment, or with a user level containingmanagerorsupervisor.COVERAGE_EXCLUDE_USER_IDSare left out.Trainer: the users in
TRAINER_USER_IDSwhen it is set, otherwise staff of anAmbassadororTRAININGdepartment; either way only those with 12 or more months of tenure.Trainee: under 3 months of tenure. Everyone else is a cleaner.
Left out of every list: people whose only site is
Administrative Office(unless listed inSTAFFING_OFFICE_ALLOW_USER_IDS), and test users (name startingZZorTest) or anyone with noemployment_start_date.warningssays how many were left out.Suggestions: the lowest load first, and people the new site would push past 40 hours last. The first cleaner is the lead and has 12 or more months of tenure when anyone does. The trainer always has 12 or more months: a
TRAINER_USER_IDSperson with less is left off the trainer list and named inwarnings. A site that already exists in Tanda gets no trainer inconversation_to_site_schedule.Names are first name plus last initial.
The views are served as ui://tanda-workforce/schedule.html and ui://tanda-workforce/allocation.html (text/html;profile=mcp-app). They contain no Tanda data, load nothing from the network (their CSP declares no domains) and need the same auth as every other MCP method.
Creating employees (tanda_create_user, off by default)
Only listed and callable when TANDA_WRITES_ENABLED=true. It creates a plain employee (POST /users, user scope) in two calls:
Call with
name,emailand optionallyphone,employment_start_date,department_ids,award_template_id(default 42, orTANDA_DEFAULT_AWARD_TEMPLATE_ID),send_inviteandsource_ref(e.g. the Monday item id). Nothing is created. The response isstatus: "preview"with the exactpayloadand aconfirm_tokenvalid for 15 minutes. Addfields: ["email","phone"]to see those in the preview.Call again with the same arguments plus
confirm_token. The response isstatus: "created"withuser_id, the user astanda_peoplereturns it, andinvite(not_requested,sentorfailed; a failed invite is a warning, not an error).
The token is bound to the arguments and to the Tanda identity that asked for the preview. Changed arguments, another identity or an expired token are refused. Both calls first check for duplicates among active and inactive users. A user with the same email, or with the same name and start date, returns status: "exists" with existing_user_id and active, and creates nothing. Tanda hides an inactive user's email (it comes back null) but still refuses to create a second user with it, so an inactive user with the same name and a hidden email also returns exists (matched_on: "name_inactive"). Rehire that person in Tanda, or pass not_a_rehire: true if it is someone else. The tool never reactivates anyone. Unknown department_ids are refused. Only the employee level can be set, and date of birth, passcode, tax, bank and role fields are never sent. hourly_rate (above 0, at most 100; needs the cost scope) is optional, but without it the user's timesheets cost $0, so the preview warns when it's missing. The preview only says pay_rate_set: true; the value is never echoed. Each creation is logged with the new user id, the caller's Tanda user id and source_ref. Calls made with the shared server token (scheduled tasks) must pass source_ref; see ADR 0001.
Deactivating employees (tanda_deactivate_user, off by default)
Tanda's DELETE /users/{id} does not erase anyone. It marks the user inactive, and Tanda's rehire reverses it. Use this tool to remove test hires and leavers from the active, billed headcount. It works in the same two steps as tanda_create_user: call with user_id (plus source_ref, which is required under the shared server token; see ADR 0001) to preview the user and get a confirm_token, then repeat the call with the token. An inactive user returns status: "already_inactive". The tool refuses anyone with a level other than employee, and it refuses the caller's own account; it fails closed if the caller can't be identified. Each deactivation is logged with the user id, the caller and source_ref.
Updating employees (tanda_update_user, off by default)
Sets hourly_rate, award_template_id, employment_start_date, department_ids (replaces the user's teams) or employee_id through Tanda's PUT /users/{id}. No other field can be sent. Use it to backfill pay rates for staff created without one: tanda_exceptions lists them under missing_pay_rate. Pass one user (user_id plus fields) or up to 50 in updates: [{user_id, hourly_rate, ...}]. The first call returns a before/after diff per user and a confirm_token. Repeat the call with the token to apply it. Each user's outcome is reported as updated, not_applied (Tanda kept the old value), failed, unchanged or refused. Rates must be above 0 and at most 100, and a change of more than 25% against the current rate is flagged in the preview. The tool refuses managers, admins, inactive users and the caller, and fails closed if the caller can't be identified. Rates in the diff show as hidden unless the call passes show_wages: true or fields: ["hourly_rate"], the same opt-in as tanda_people, and current rates are visible only with the cost scope. Each update is logged with the user id, the changed field names, the caller and source_ref, which is required under the shared server token (ADR 0001).
Approving timesheets (tanda_approve_timesheets, off by default)
Approves Tanda timesheets for a pay period, or returns them to pending (action: "unapprove"). Applying needs a person's own Tanda login, so Tanda's history always shows who approved. The shared server token (MCP_SHARED_SECRET + TANDA_ACCESS_TOKEN) can only preview: it gets no confirm_token, and an apply is refused. The staging release gate uses that preview (ADR 0001).
Call with
from/to(the pay period) and optionallytimesheet_ids,user_idsorlocation_ids. Nothing changes. Each timesheet row showswill_changeor askip_reason, any data-qualityflags, and theshift_changesthat would be made. Aconfirm_tokencomes back with the preview.Repeat the call with
confirm_token. Each timesheet's shift changes are applied first, then its status. A failure on one timesheet is reported in its row (outcome: "failed"), and the others carry on.
Data-quality handling:
Missing clock-out: the finish is filled from the user's rostered finish that day when exactly one roster entry matches (
fill_missing_clock_out, default true).Flags: a missing clock-out that couldn't be filled, a zero-length shift, a shift over 12h, a shift with no pay code, or a workweek over 40h. Flagged timesheets are still approved, and each affected shift gets an
MCP-EXCEPTION <date>: <reasons>note in itsmetadata, which is visible in Workforce. Existing metadata is kept.Skipped: exported timesheets are never touched. Periods that ended more than 14 days ago need
allow_past_period: true. At most 100 timesheets change per call.Token: it covers the exact changes. If the data changes between preview and confirm, the token is refused and you preview again.
A supervisor is any user rostered to a department named Supervisor or Supervisors (case-insensitive). The bookkeeping sites 281737 (One Time Projects), 301754 (Floater) and 396358 (MCP Test) are flagged, and analytics tools exclude them by default.
Deprecated names (one release)
The v3 tool names (for example tanda_get_daily_stats, tanda_get_staff_by_department, tanda_get_timesheets) and the interim action-based names (tanda_users, tanda_reference, …) still work. They are translated to the new tools, and the response carries a deprecation notice. Each use is logged, and the counts appear under deprecated_alias_usage in GET /stats. Aliases are not listed in tools/list unless MCP_LIST_ALIASES=true.
tanda_get_shift_limits is removed: Tanda's endpoint returns first/last shifts, not limits. Use tanda_exceptions instead.
Quick Start
git clone https://github.com/hakeemrabiuDFW/Tanda-Workforce-MCP-Server.git
cd Tanda-Workforce-MCP-Server
npm install
cp .env.example .env # fill in values
npm run build && npm startEnvironment
Variable | Required | Purpose |
| yes | Tanda OAuth app |
| prod | OAuth callback (auto-detected on Railway) |
| yes | ≥ 32 chars |
| no | Default |
| no | Bearer-secret auth for server-to-server, Claude Desktop and the smoke test |
| for export preview | Payroll export format name |
| no | Default |
| no | Comma-separated user ids never counted or suggested as supervisors (e.g. bookkeeping and admin-only users) |
| no | Default |
| no | Sites one roving supervisor covers at once. Default 5 |
| no | Comma-separated Tanda user ids who may train at a new site ( |
| no | Comma-separated Tanda user ids of office-only staff ( |
| no | First day of the overtime workweek ( |
| no |
|
| no | How far back |
| no | Default |
| no | Client-side limit, default 80 (Tanda allows 100/min shared across password tokens) |
| no |
|
| no |
|
| no | Award template for new users when none is given. Default 42 |
Connecting to Claude
Claude.ai: add https://your-domain.com/mcp as a connector. The 401 response with WWW-Authenticate: Bearer resource_metadata=… starts the OAuth flow (discovery, dynamic registration, PKCE).
Claude Desktop / scripts:
{
"mcpServers": {
"tanda-workforce": {
"url": "https://your-domain.com/mcp",
"headers": { "Authorization": "Bearer <MCP_SHARED_SECRET or JWT from /auth/login>" }
}
}
}Development
npx playwright install chromium # once: the MCP App view tests render the pages headless
npm test # unit + integration tests (Tanda stubbed; includes an 84-site / 70-user size check)
npm run build
MCP_URL=https://your-domain.com/mcp MCP_TOKEN=<secret> npm run smoke [from] [to]
MCP_URL=https://your-domain.com/mcp MCP_TOKEN=<secret> npm run smoke:writesnpm run smoke calls all 12 read tools and the two staffing apps against a running server and prints only the shape and size of each response (no row values). It exits non-zero if a tool errors, exceeds 25 KB, or returns date_of_birth/passcode.
npm run smoke:writes exercises every write tool with the shared secret. Each run creates its own test hire ("ZZ MCP Smoke ", zz.mcp.smoke.<run id>@example.com, no invite). It then checks that a duplicate is caught, updates and deactivates the hire, previews approval on an old pay period (SMOKE_FROM/SMOKE_TO), and checks that the shared token can't apply an approval. It prints step results only. The hire always ends inactive, even when a step fails, so it never counts towards the billed headcount. Each run leaves one inactive test user, because Tanda refuses to reuse an email even for an inactive user.
Releasing
Changes reach production through staging first:
Open a pull request into
staging. CI runs typecheck, tests and build.Merge it. Build and deploy (
.github/workflows/deploy.yml) tests again, pushes the image as:stagingand:<commit>, redeploys thetanda-mcp-stageRailway service, and waits until its/healthreports the new commit.Check staging (
https://tanda-mcp-stage-production.up.railway.app) withnpm run smokeandnpm run smoke:writes.Hard requirement: the Staging gate check (
.github/workflows/staging-gate.yml) must be green on the release pull request. It waits until staging serves the release commit, checks that auth is enforced, then runs both smoke tests against staging. It needs theSTAGING_MCP_TOKENrepository secret (the stagingMCP_SHARED_SECRET). Markstaging-gateas a required check formainin branch protection.Merge the release pull request from
stagingintomain. The Release PR workflow (.github/workflows/release-pr.yml) opens it as soon asstaginghas changesmainlacks, lists the change PRs it carries, and keeps it updated; each release gets its own PR. Merging it ships:productionto the production service.
The deploy step needs a Railway project token as the RAILWAY_TOKEN repository secret; without it the image is pushed but not deployed. To require approval for production, add reviewers to the production environment in the repository's settings. To roll back, redeploy an earlier deployment in Railway, or point the service at an earlier :<commit> image.
Project Structure
src/
auth/ OAuth + MCP route auth (JWT or shared secret)
config/ environment, scopes
mcp/
handler.ts JSON-RPC (initialize, tools/*, resources/*, prompts/*)
tools/ one file per tool + aliases.ts + index.ts
guard.ts 50-row / 25 KB response guard
privacy.ts user field whitelist + recursive redaction
context.ts cached org/people lookups
tanda/ read-only client (ETag cache, rate limiter, 7-day chunking)
utils/ logger, time (unix seconds <-> America/New_York)
scripts/smoke.mjsSee CHANGELOG-v4.0.md and DEPLOYMENT.md.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
This server cannot be deployed
Maintenance
Related MCP Connectors
Connect AI assistants to Talentflake for time, attendance, leave, and expenses.
Connects AI assistants to TrackingTime for querying time entries, projects, tasks, customers, and team data using natural language.
TidyRox boards, My Day, booking pages, and time tracking for AI assistants (OAuth 2.1).
Run your TalentoHQ company from an AI agent: people, time, absences, hiring, and more.
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceEnables AI assistants to interact with BambooHR's API through natural language queries. Provides access to employee data, time off management, company files, and HR operations with comprehensive tools for workforce management.108 npm1MIT

TrackingTime MCPofficial
FlicenseNot gradedqualityBmaintenanceConnects AI assistants to TrackingTime for querying time entries, projects, tasks, customers, and team data using natural language.-- AlicenseAqualityBmaintenanceEnables AI assistants to access Time Doctor employee time-tracking data, including companies, users, projects, tasks, and time-use statistics, while handling authentication internally.11Apache 2.0
- AlicenseNot gradedqualityCmaintenanceEnables AI assistants to find employees, clock them in and out, read work entries, and review or answer vacation and absence requests through the official public API.32 npmMIT