Deputy MCP

io.github.augbastos由 GitHub 账号 augbastos 发布v0.4.2更新于 Nov 5, 2026

Deputy workforce data for AI agents: rosters, timesheets and shifts; read-only by default

已验证STDIO仅桌面效率与工作流商业与电商

概览

AI 生成的概览

本地 MCP 服务器,让 AI 助手读取你在 Deputy 的班次、排班表和工时表,并可选启用打卡等写入操作。

可以做什么
  • 读取个人 Deputy 数据:身份、个人排班、下一次班次、工时表、同事、日历链接和区域
  • 以经理权限查询团队信息:团队排班、当前在岗人员、员工资料、班次搜索
  • 仅在启用写入时操作班次:上班打卡、下班打卡、设置不可用时间、认领空缺班次
  • 通过浏览器 OAuth 登录工具完成登录
适用场景
适用于公司使用 Deputy 排班、希望让助手回答“下次什么时候上班”“上周工作了多少小时”“现在谁在岗”等问题,并可选在对话中打卡上下班的场景。
运行要求
通过 uvx 在本地运行,需要 uv 和 Python 3.11 或更高版本。三种访问模式只能选一种:OAuth(个人应用的 DEPUTY_OAUTH_CLIENT_ID 与 DEPUTY_OAUTH_CLIENT_SECRET,并需浏览器登录)、管理员 API 令牌(DEPUTY_API_TOKEN 配合 DEPUTY_BASE_URL),或个人 iCal 订阅(DEPUTY_CALENDAR_URL)。需要访问 Deputy 的网络;OAuth 令牌默认存入操作系统钥匙串。
安装前请注意
只有将 DEPUTY_ALLOW_WRITES 设为 true 才会注册写入工具;认领空缺班次会跳过 Deputy 的审批步骤,执行前应先确认。API 令牌、OAuth 客户端密钥和日历链接都是机密,日历链接内含私人令牌。若系统没有钥匙串,DEPUTY_TOKEN_STORE 会以明文保存 OAuth 令牌。经理工具、写入操作和令牌刷新尚未在真实环境验证。

安装

在 SourceWeft 中

  1. 打开 控制台中的 Deputy MCP,将其添加到工作区。
  2. 为需要使用其工具的对话启用该服务。

Desktop only,通过 STDIO。 STDIO 服务会启动本地进程,因此需要 SourceWeft 桌面宿主。

其他 MCP 客户端

参照 仓库 中的启动说明。

README

Deputy MCP

[CI] [Security] [License: MIT]

Ask Claude "when do I work next?" and get the answer from your Deputy roster.

Deputy MCP is a local MCP server that lets AI agents read your shifts, timesheets and team schedule, and, only if you turn it on, act on them. It runs on your machine, connects to Deputy, and works with a regular employee account.

What you can ask

  • "When do I work next?"
  • "How many hours did I work last week?"
  • "Who's on shift right now?" (manager access)
  • "Clock me in." (writes enabled)
  • "Take the open shift on Saturday." (writes enabled; asks you to confirm first)

Install

Needs uv and Python 3.11 or newer. Choose your access mode first:

ModeWho it's forStart here
OAuthAny employeeEmployee sign-in
API tokenDeputy adminsAdmin setup
Calendar feedNo API accessSet DEPUTY_CALENDAR_URL using the client setup; your own roster only, read-only

Employee OAuth

Create a personal app at https://once.deputy.com/my/oauth_clients with the redirect URI http://localhost:8823/callback. Create it there, not under your install's Settings → Developer: an app made inside an install fails sign-in with invalid_client. In Bash, replace the placeholders, sign in, then register the server with Claude Code:

bash
export DEPUTY_OAUTH_CLIENT_ID='your-client-id'export DEPUTY_OAUTH_CLIENT_SECRET='your-client-secret'uvx deputy-mcp loginclaude mcp add deputy \  -e DEPUTY_OAUTH_CLIENT_ID="$DEPUTY_OAUTH_CLIENT_ID" \  -e DEPUTY_OAUTH_CLIENT_SECRET="$DEPUTY_OAUTH_CLIENT_SECRET" \  -- uvx deputy-mcp

Login opens your browser and stores OAuth tokens in your OS keychain by default. Run login and Claude Code as the same OS user. No terminal (for example, the Claude Desktop bundle)? Set the two OAuth values and ask the assistant to sign you in: the deputy_login tool opens the same browser sign-in.

Admin API token

With your Deputy API token and install URL, register directly; no OAuth login is needed:

bash
claude mcp add deputy \  -e DEPUTY_API_TOKEN=your-deputy-token \  -e DEPUTY_BASE_URL=https://your-company.eu.deputy.com \  -- uvx deputy-mcp

Codex CLI

For your own roster, replace ... with your private calendar feed URL:

bash
codex mcp add deputy --env DEPUTY_CALENDAR_URL=... -- uvx deputy-mcp

The first uvx run downloads dependencies; if Codex reports the tools as unavailable, set startup_timeout_sec = 60 under [mcp_servers.deputy] in ~/.codex/config.toml.

Claude Desktop users: download the .mcpb bundle from the Releases page and drag it onto Settings → Extensions (double-clicking may not open it on Windows). Fill in one access mode under Configure, then ask Claude to sign you in. Other MCP clients and Docker: see other ways to install. All settings are listed in .env.example.

Tools

  • Your data (any account): deputy_whoami, deputy_get_my_roster, deputy_next_shift, deputy_get_my_timesheets, deputy_get_my_colleagues, deputy_get_my_calendar_url, deputy_get_areas
  • Team (manager access): deputy_get_team_roster, deputy_who_is_working, deputy_get_employee_info, deputy_search_shifts
  • Actions (only with DEPUTY_ALLOW_WRITES=true): deputy_clock_in, deputy_clock_out, deputy_set_unavailability, deputy_claim_open_shift

Safe by default

  • Read-only unless you set DEPUTY_ALLOW_WRITES=true; until then the action tools don't exist for the agent.
  • You confirm before a shift is claimed, since that skips Deputy's approval step.
  • No guessing: if a name matches several people, you get the list, not the first one.
  • Credential protection: by default, tokens go only to https://*.deputy.com and OAuth tokens live in your OS keychain; errors are scrubbed of secrets before an agent sees them.

Status

The everyday read tools and OAuth sign-in were tested against a real Deputy install with an employee account. Manager tools, actions and the OAuth token refresh are covered by automated tests but not yet verified on a live install. Not affiliated with Deputy.

More

License

MIT

来源:README.md,提交 4b9c7d4

工具

0
SourceWeft 曾在隔离沙箱中以无凭据方式启动该软件包一次,以列出其工具,但未能完成:服务器未能启动。

版本历史

2
  1. v0.4.2最新Oct 21, 2026
  2. v0.4.0Oct 21, 2026

评分

已满足适用检查项的 50%

该评分衡量此收录条目的完整程度,依据注册中心条目、端点与公开来源计算得出。它不是对服务器本身的评价,也不表示服务器安全或当前可用:可连通性是带日期的检查结果,评分也不包含安装量或用户评价。

  • 近 30 天内可连通25 分

    请保持端点能够响应 MCP 握手;SourceWeft 每 30 天探测一次。

  • 已声明认证方式10 分

    请在注册中心条目中声明凭据请求头,或保持端点能够响应探测,以便判定其认证方式。

  • 已列出工具15 分

    请让服务器在无凭据时响应 tools/list,或发布可在沙箱中无凭据启动的软件包。

  • 描述必需15 分
  • 图标10 分
  • 文档15 分
  • 许可证10 分