mcpField
N
Nworks

Nworks

本地服务
github.com/yjcho9317通信协作286 周前更新

关于 Nworks

nworks 是面向 NAVER WORKS(LINE WORKS)的命令行工具与 MCP 服务,可供外部 AI Agent 和终端操作消息、日历、云盘、邮件、任务与公告板。项目为社区维护的非官方项目,与 NAVER WORKS 无关联。

主要功能

  1. 01命令行与 MCP 服务双重接口
  2. 02覆盖消息、日历、云盘、邮件、任务、公告板等模块
  3. 03支持 --json 输出,便于脚本与 Agent 解析
  4. 04消息发送支持 --dry-run 测试模式
  5. 05通过 Service Account 或用户 OAuth 进行认证

适用场景

  1. 01AI Agent 查询日程并创建会议
  2. 02CI/CD 部署完成后向团队频道发送通知
  3. 03脚本批量向组织成员发送消息

MCP 相关

以 MCP 服务形式对外提供 36 个工具,供 Claude Desktop、Cursor 等 MCP 客户端调用,涵盖消息、日历、云盘、邮件、任务、公告板与通讯录。

配置

本地服务的配置在各客户端中通用,复制后粘贴到客户端的 MCP 配置文件即可。

暂未收录安装方式

我们还没有获取到这个服务的安装包或远程地址,请按项目 README 中的说明安装。

代码仓库

工具

还没有获取到工具列表

本地服务需要在你的电脑上运行后才能读取工具,维护者暂未提供工具列表。

详细介绍

nworks

npm version license npm downloads nworks MCP server

收录于 awesome-mcp-servers

🇺🇸 English | 🇰🇷 한국어 | 🇯🇵 日本語

nworks 演示

功能齐全的 LINE WORKS(NAVER WORKS)MCP 服务。 CLI + MCP 服务,提供 36 个工具,涵盖消息、日历、网盘、邮件、任务和公告板。

nworks 让外部 AI Agent(Claude、Cursor)和终端能够从外部操作 LINE WORKS,与 LINE WORKS 自带的产品内 AI(AiStudio、WORKS AI)互为补充,并非替代。此项目为非官方项目,由社区维护;与 LINE WORKS / NAVER WORKS 无关联。

快速入门

npm install -g nworks
nworks login --user
nworks calendar list

首次使用? 首先需要创建 Developer Console 应用(Client ID/Secret)、注册重定向 URL;如果要发送机器人消息,还需要管理员批准。请参阅入门与管理员设置指南。

AI Agent 实际使用方式
User: Show me today's schedule

Claude → nworks_calendar_list
  → 3 events: Standup (10:00), Lunch meeting (12:00), Code review (15:00)

User: Send a deploy complete message to the team channel

Claude → nworks_message_send
  { "channel": "C001", "text": "v1.2.0 deploy complete" }
  → Message sent

User: Check my unread emails and summarize them

Claude → nworks_mail_list (unread)
  → 3 unread emails
Claude → nworks_mail_read (each)
  → "3 unread: 1) Deploy approval from CTO, 2) Meeting invite for Friday, 3) Weekly report reminder"

安装

npx nworks             # Run directly
npm install -g nworks  # Global install

登录

# User OAuth (calendar, drive, mail, tasks, boards)
nworks login --user --scope "calendar calendar.read file file.read mail mail.read task task.read board board.read user.read"

# Bot messaging (Service Account)
nworks login

# Check auth status
nworks whoami

# Logout
nworks logout

nworks login --user 只需要 CLIENT_ID + CLIENT_SECRET。通过环境变量或现有配置设置的值不会再次询问。

Developer Console:要使用 User OAuth,请在 Developer Console 中将 http://localhost:9876/callback 注册为 Redirect URL。


AI Agent 集成(MCP 服务)

兼容 Claude Desktop、Cursor 和其他支持 MCP 的客户端。

设置

请先登录:

nworks login --user --scope "calendar calendar.read file file.read mail mail.read task task.read board board.read user.read"

然后将其添加到 MCP 配置(~/.config/claude/claude_desktop_config.json):

{
  "mcpServers": {
    "nworks": {
      "command": "nworks",
      "args": ["mcp"]
    }
  }
}

登录一次即可启用全部 36 个工具。无需额外设置环境变量。

如果未通过 CLI 登录,AI Agent 可以调用 nworks_setup → nworks_login_user,直接通过浏览器完成身份验证。Client Secret 和 Private Key 路径必须通过 MCP 配置的 env 字段或系统环境变量预先设置。

MCP 工具(32 个)
工具描述身份验证
设置 / 身份验证
nworks_setup配置 API 凭据(客户端 ID 等)。客户端密钥通过环境变量设置—
nworks_login_user用户通过 OAuth 浏览器登录(包含所有权限范围)—
nworks_logout删除凭据和令牌—
nworks_whoami检查身份验证状态—
nworks_doctor诊断连接(身份验证、令牌、API 健康状况)—
消息
nworks_message_send向用户 / 频道发送消息服务账号
nworks_message_members列出频道成员服务账号
nworks_directory_members列出组织成员服务账号
日历
nworks_calendar_list列出日历活动用户 OAuth(calendar.read)
nworks_calendar_create创建日历活动用户 OAuth(calendar + calendar.read)
nworks_calendar_update更新日历活动用户 OAuth(calendar + calendar.read)
nworks_calendar_delete删除日历活动用户 OAuth(calendar + calendar.read)
云盘
nworks_drive_list列出云盘文件 / 文件夹用户 OAuth(file.read)
nworks_drive_upload将文件上传到云盘用户 OAuth(file)
nworks_drive_download下载文件(超过 5MB 时保存到本地)用户 OAuth(file.read)
nworks_sharedrive_list列出共享云盘用户 OAuth(file.read)
nworks_sharedrive_files列出共享云盘中的文件 / 文件夹用户 OAuth(file.read)
nworks_sharedrive_download下载共享云盘文件(超过 5MB 时保存到本地)用户 OAuth(file.read)
邮件
nworks_mail_send发送邮件用户 OAuth(mail)
nworks_mail_list列出邮箱邮件用户 OAuth(mail.read)
nworks_mail_read阅读邮件详情用户 OAuth(mail.read)
nworks_mail_download_attachment下载邮件附件(超过 5MB 时保存到本地)用户 OAuth(mail.read)
任务
nworks_task_list列出任务用户 OAuth(task.read)
nworks_task_create创建任务用户 OAuth(task + user.read)
nworks_task_update更新 / 完成任务用户 OAuth(task + user.read)
nworks_task_delete删除任务用户 OAuth(task + user.read)
看板
nworks_board_list列出看板用户 OAuth(board.read)
nworks_board_posts列出看板帖子用户 OAuth(board.read)
nworks_board_read阅读看板帖子详情用户 OAuth(board.read)
nworks_board_create创建看板帖子用户 OAuth(board)
联系人
nworks_contact_list列出联系人用户 OAuth(contact.read)
nworks_contact_get获取联系人详情用户 OAuth(contact.read)
nworks_contact_create创建联系人用户 OAuth(contact)
nworks_contact_update更新联系人用户 OAuth(contact)
nworks_contact_delete删除联系人用户 OAuth(contact)
nworks_contact_list_tags列出联系人标签用户 OAuth(contact.read)
AI Agent 使用示例
User: Schedule a meeting tomorrow at 2pm and notify the team channel

Claude → nworks_calendar_create
  { "summary": "Meeting", "start": "2026-03-15T14:00:00", "end": "2026-03-15T15:00:00" }
  → Event created

Claude → nworks_message_send
  { "channel": "C001", "text": "Meeting scheduled tomorrow at 14:00" }
  → Message sent

User: Check my unread emails and summarize them

Claude → nworks_mail_list (unread)
  → 3 unread emails
Claude → nworks_mail_read (each)
  → "3 unread: 1) Deploy approval from CTO, 2) Meeting invite for Friday, 3) Weekly report reminder"

CLI 使用方法

所有命令都支持 --json,便于通过管道 / 脚本 / Agent 解析。message send、mail send 和 drive upload 支持 --dry-run,可在不发送的情况下进行测试。

消息(Bot API)
# Send text to user
nworks message send --to <userId> --text "Hello"

# Send text to channel
nworks message send --channel <channelId> --text "Announcement"

# Button message
nworks message send --to <userId> --type button --text "PR review request" \
  --actions '[{"type":"message","label":"Approve","postback":"approve"}]'

# List message
nworks message send --to <userId> --type list --text "Today's tasks" \
  --elements '[{"title":"Code review","subtitle":"PR #382"}]'

# List channel members
nworks message members --channel <channelId>
目录
nworks directory members   # List organization members
日历(用户 OAuth)
# List today's events
nworks calendar list

# Specify date range
nworks calendar list --from "2026-03-14T00:00:00+09:00" --until "2026-03-14T23:59:59+09:00"

# Create event
nworks calendar create --title "Meeting" --start "2026-03-14T14:00+09:00" --end "2026-03-14T15:00+09:00"

# With location/description
nworks calendar create --title "Lunch" --start "2026-03-14T12:00+09:00" --end "2026-03-14T13:00+09:00" \
  --location "Conference Room" --description "Quarterly review"

# With attendees + notification
nworks calendar create --title "Team meeting" --start "2026-03-14T10:00+09:00" --end "2026-03-14T11:00+09:00" \
  --attendees "[email protected],[email protected]" --notify

# Update event
nworks calendar update --id <eventId> --title "Updated title"

# Delete event
nworks calendar delete --id <eventId>
云盘(用户 OAuth)
# List files/folders
nworks drive list

# Upload file
nworks drive upload --file ./report.pdf

# Upload to specific folder
nworks drive upload --file ./report.pdf --folder <folderId>

# Download file
nworks drive download --file-id <fileId>

# Specify output path/name
nworks drive download --file-id <fileId> --out ./downloads --name report.pdf

# List shared drives
nworks drive sharedrive-list

# List files in a shared drive (root)
nworks drive sharedrive-files --sharedrive <sharedriveId>

# List files in a shared drive folder
nworks drive sharedrive-files --sharedrive <sharedriveId> --folder <fileId>

# Download a shared drive file
nworks drive sharedrive-download --sharedrive <sharedriveId> --file-id <fileId>
邮件(用户 OAuth)
# Send mail
nworks mail send --to "[email protected]" --subject "Subject" --body "Body"

# With CC/BCC
nworks mail send --to "[email protected]" --cc "[email protected]" --subject "Subject" --body "Body"

# List inbox
nworks mail list

# Unread only
nworks mail list --unread

# Read mail detail
nworks mail read --id <mailId>

# Download a mail attachment
nworks mail download-attachment --id <mailId> --attachment-id <attachmentId>

# Specify output path/name
nworks mail download-attachment --id <mailId> --attachment-id <attachmentId> --out ./downloads --name invoice.pdf
任务(用户 OAuth)
# List tasks
nworks task list

# Incomplete only
nworks task list --status TODO

# Create task
nworks task create --title "Code review" --body "Review PR #382"

# With due date
nworks task create --title "Deploy" --due 2026-03-20

# Mark as done
nworks task update --id <taskId> --status done

# Delete task
nworks task delete --id <taskId>
看板(用户 OAuth)
# List boards
nworks board list

# List posts
nworks board posts --board <boardId>

# Read post detail
nworks board read --board <boardId> --post <postId>

# Create post
nworks board create --board <boardId> --title "Announcement" --body "Content"

# With notification + disable comments
nworks board create --board <boardId> --title "Notice" --body "Content" --notify --no-comment
联系人(用户 OAuth)
# List contacts
nworks contact list

# Filter by tag
nworks contact list --tag <contactTagId>

# Get contact detail
nworks contact get --id <contactId>

# Create contact
nworks contact create --payload '{"contactName":{"lastName":"Kim","firstName":"Chulsoo"},"emails":[{"email":"[email protected]","primary":true}],"permission":{"accessibleRange":"MEMBER","isCoEditing":false,"accessibleMembers":[{"id":"<yourUserId>","type":"USER"}]}}'

# Update contact
nworks contact update --id <contactId> --payload '{"telephones":[{"type":"CELLPHONE","telephone":"010-1234-5678","primary":true}]}'

# Delete contact
nworks contact delete --id <contactId>

# List contact tags
nworks contact list-tags

contact create 需要 contactName 和 permission;permission.accessibleMembers 必须至少列出一位成员(通常是你自己)。通过 nworks whoami 获取你自己的用户 ID。

CI/CD 部署通知
# Notify team channel after deployment in GitHub Actions
nworks message send --channel $CHANNEL_ID --text "v${VERSION} deployed"
团队自动化脚本
# Send daily standup reminder to all members
for userId in $(nworks directory members --json | jq -r '.users[].userId'); do
  nworks message send --to "$userId" --text "Standup at 10:00 today"
done

OAuth 权限范围

在 LINE WORKS Developer Console 中添加所需的权限范围。

权限范围用途认证方式适用于
botBot 消息收发服务账号message send
bot.read读取 Bot 频道/成员服务账号message members
calendar日历写入用户 OAuthcalendar create/update/delete(需要 calendar.read)
calendar.read日历读取用户 OAuthcalendar list,日历写入也需要此权限
fileDrive 读取/写入用户 OAuthdrive list/upload/download
file.readDrive 只读用户 OAuthdrive list/download
mail邮件读取/写入用户 OAuthmail send/list/read
mail.read邮件只读用户 OAuthmail list/read
task任务读取/写入用户 OAuthtask create/update/delete(需要 user.read)
task.read任务只读用户 OAuthtask list
user.read读取用户信息服务账号/用户 OAuthdirectory members,任务写入也需要此权限
boardBoard 读取/写入用户 OAuthboard list/posts/read/create
board.readBoard 只读用户 OAuthboard list/posts/read
contact联系人读取/写入用户 OAuthcontact create/update/delete(需要 contact.read)
contact.read联系人只读用户 OAuthcontact list/get/list-tags

预设比逐项列出权限范围更简单:

nworks login --user --preset all       # 默认:一次登录即可使用全部功能
nworks login --user --preset readonly  # 只读权限范围

default 是 all 的别名。消息发送使用服务账号(bot),因此不受预设影响。 重新登录不会缩小访问权限——新申请的权限范围会与现有令牌合并,因此切换预设只会增加功能。如需手动选择权限范围,请使用 --scope "calendar calendar.read"。


环境变量

设置环境变量即可在不运行 nworks login 的情况下使用 nworks(适用于 CI/Agent)。

# Required
NWORKS_CLIENT_ID=
NWORKS_CLIENT_SECRET=

# Bot messaging only (not needed for User OAuth)
NWORKS_SERVICE_ACCOUNT=
NWORKS_PRIVATE_KEY_PATH=
NWORKS_BOT_ID=

# Optional
NWORKS_DOMAIN_ID=
NWORKS_SCOPE=              # default: bot bot.read user.read
NWORKS_VERBOSE=1           # debug logging
使用环境变量的 MCP 服务

敏感值(Client Secret、Private Key 路径)必须通过 MCP 配置的 env 字段设置。Client ID 等非敏感值可由 AI Agent 通过 nworks_setup 工具配置。

{
  "mcpServers": {
    "nworks": {
      "command": "npx",
      "args": ["-y", "nworks", "mcp"],
      "env": {
        "NWORKS_CLIENT_SECRET": "<Client Secret>",
        "NWORKS_PRIVATE_KEY_PATH": "<Private Key file absolute path (for Service Account)>"
      }
    }
  }
}

许可证

Apache-2.0

评论

支持 Markdown

第一次接触 MCP?

从协议是什么,到在客户端里装上第一个服务,这几条回答覆盖了大多数入门问题。

一个开放协议,规定了 AI 应用如何以统一方式连接外部工具与数据源。客户端负责与模型对话,MCP 服务负责提供工具、资源和提示模板,两者通过标准消息通信,同一个服务可以被不同客户端复用。