API, máy chủ MCP và skill AI của Foundation
Kết nối một AI agent (Claude, Codex, Cursor hoặc agent của bạn) hay một script với Foundation. Mọi thứ dưới đây dùng API token cá nhân và chỉ làm được đúng những gì tài khoản của bạn làm được trong ứng dụng.
Các danh sách trên trang này lấy từ mã nguồn và được một bài kiểm tra tự động đối chiếu ở mỗi thay đổi.
1. Tạo API token
- Đăng nhập Foundation, mở Cài đặt → API tokens.
- Tạo token và sao chép ngay: token bắt đầu bằng efnd_ và chỉ hiện một lần.
- Giữ bí mật. Token hành động thay bạn ở mọi nơi bạn có quyền. Thu hồi ở cùng trang khi không cần nữa.
2. Kết nối AI agent
Claude Code (một lệnh, rồi khởi động lại Claude Code):
claude mcp add --transport http evnx-foundation https://mcp.foundation.evnx.community/mcp --header "Authorization: Bearer efnd_YOUR_TOKEN"Agent khác hỗ trợ máy chủ MCP từ xa (Claude Desktop, Cursor, Codex, agent của bạn): thêm máy chủ với các thông số sau.
{
"mcpServers": {
"evnx-foundation": {
"type": "http",
"url": "https://mcp.foundation.evnx.community/mcp",
"headers": {
"Authorization": "Bearer efnd_YOUR_TOKEN"
}
}
}
}Tuỳ chọn, cho Claude: thêm các skill để Claude biết cách dùng công cụ. Sao chép thư mục skills của plugin công khai vào ~/.claude/skills (hoặc thư mục .claude/skills của một dự án). https://github.com/Envision-Nexus/evnx-foundation-plugin
git clone https://github.com/Envision-Nexus/evnx-foundation-plugin.git
cp -r evnx-foundation-plugin/skills/* ~/.claude/skills/3. Kiểm tra
- Hỏi agent: “Liệt kê các tổ chức Foundation của tôi.” Agent sẽ gọi list_my_communities và hiện các tổ chức của bạn.
- 401 “Missing Authorization”: token không được gửi. Kiểm tra header Authorization.
- 401 token không hợp lệ: token sai hoặc đã bị thu hồi. Tạo token mới.
- 404 ở một Space hay tổ chức: bạn không phải thành viên, hoặc slug sai. API cố ý không nói rõ là lý do nào.
Hướng dẫn cho AI agent
Dán đoạn này cho agent để nó tự cài đặt:
Set up access to EVNX Foundation (project platform at https://foundation.evnx.community).
1. Ask me for my personal API token (I create it at Settings -> API tokens; it starts with efnd_). Never print it back, never store it in a file that is committed.
2. Add a remote MCP server named "evnx-foundation": transport Streamable HTTP, URL https://mcp.foundation.evnx.community/mcp, header "Authorization: Bearer <token>".
- Claude Code: claude mcp add --transport http evnx-foundation https://mcp.foundation.evnx.community/mcp --header "Authorization: Bearer <token>"
3. If you are Claude, install the skills: git clone https://github.com/Envision-Nexus/evnx-foundation-plugin.git && cp -r evnx-foundation-plugin/skills/* ~/.claude/skills/
Skills: foundation-tasks, foundation-knowledge-base, foundation-communities, foundation-my-tasks-triage, foundation-space-weekly-digest.
4. Restart if your client needs it, then call list_my_communities and show me the result to prove it works.
401 = token missing / wrong / revoked. 404 = not a member or wrong slug.
Tools (23): list_my_communities, list_community_members, search_people, list_space_tasks, get_task, create_task, update_task, list_task_comments, add_task_comment, list_space_milestones, create_space_milestone, update_space_milestone, list_space_sprints, create_space_sprint, update_space_sprint, list_space_approvals, list_my_approvals, list_knowledge_pages, get_knowledge_page, create_knowledge_page, update_knowledge_page_text, get_file, upload_file.
The token acts as me with my own permissions. Full reference: https://foundation.evnx.community/developersCông cụ MCP
Máy chủ MCP chỉ chuyển tiếp: mỗi công cụ gọi REST API bên dưới bằng token của bạn. Nó không lưu gì.
Tổ chức và mọi người
| Công cụ | Làm gì | Đầu vào | Gọi |
|---|---|---|---|
| list_my_communities | Your organizations. | — | GET /api/v1/organizations |
| list_community_members | Members of an organization. | slug | GET /api/v1/organizations/:slug/members |
| search_people | Search the people directory. | query?, limit? (1–50) | GET /api/v1/people |
Công việc và bình luận
| Công cụ | Làm gì | Đầu vào | Gọi |
|---|---|---|---|
| list_space_tasks | Tasks of a Space. | slug, status? | GET /api/v1/spaces/:slug/tasks |
| get_task | One task. | slug, taskId | GET /api/v1/spaces/:slug/tasks/:taskId |
| create_task | New task at the end of a column. | slug, title, status? | POST /api/v1/spaces/:slug/tasks |
| update_task | Change title, description (replaces it), priority, due date, status or assignees. | slug, taskId, title?, description?, priority?, due_date?, status?, assignees? | PATCH /api/v1/spaces/:slug/tasks/:taskId |
| list_task_comments | Comments of a task. | slug, taskId | GET /api/v1/spaces/:slug/tasks/:taskId/comments |
| add_task_comment | Post a comment; @username notifies. | slug, taskId, text | POST /api/v1/spaces/:slug/tasks/:taskId/comments |
Mốc và sprint
| Công cụ | Làm gì | Đầu vào | Gọi |
|---|---|---|---|
| list_space_milestones | Milestones of a Space. | slug | GET /api/v1/spaces/:slug/milestones |
| create_space_milestone | New milestone. | slug, title?, description?, due_date?, status? | POST /api/v1/spaces/:slug/milestones |
| update_space_milestone | Edit a milestone; done may start an approval. | slug, milestoneId, title?, description?, due_date?, status? | PATCH /api/v1/spaces/:slug/milestones/:milestoneId |
| list_space_sprints | Sprints of a Space. | slug | GET /api/v1/spaces/:slug/sprints |
| create_space_sprint | New planned sprint. | slug, name, goal, startDate, endDate | POST /api/v1/spaces/:slug/sprints |
| update_space_sprint | Edit a sprint. | slug, sprintId, name, goal, startDate, endDate | PATCH /api/v1/spaces/:slug/sprints/:sprintId |
Phê duyệt
| Công cụ | Làm gì | Đầu vào | Gọi |
|---|---|---|---|
| list_space_approvals | Approval requests of a Space. | slug | GET /api/v1/spaces/:slug/approvals |
| list_my_approvals | Your approvals: requested or waiting on you. | role? | GET /api/v1/approvals/mine |
Kho kiến thức
| Công cụ | Làm gì | Đầu vào | Gọi |
|---|---|---|---|
| list_knowledge_pages | Knowledge base page tree. | slug (organization) | GET /api/v1/organizations/:slug/kb/pages |
| get_knowledge_page | Read a page. | slug, pageId | GET /api/v1/organizations/:slug/kb/pages/:pageId |
| create_knowledge_page | New empty top-level page. | slug, title | POST /api/v1/organizations/:slug/kb/pages |
| update_knowledge_page_text | Replace a page's title and / or body with plain text. | slug, pageId, title?, text? | PATCH /api/v1/organizations/:slug/kb/pages/:pageId |
Tệp
| Công cụ | Làm gì | Đầu vào | Gọi |
|---|---|---|---|
| get_file | Read a picture or file (pictures under 8 MB come back as an image). | fileId, kind (kb | budget) | GET /api/kb-files/:fileId or /api/files/:fileId |
| upload_file | Upload a picture or PDF for a task or comment. | slug, fileName, mimeType, base64 | POST /api/v1/spaces/:slug/files |
Skill
Skill cho Claude biết khi nào và cách dùng các công cụ. Skill công cụ giải thích quy tắc; skill quy trình làm trọn một việc.
| Skill | Loại | Làm gì | Thử hỏi |
|---|---|---|---|
| foundation-tasks | Công cụ | Tasks, comments, milestones, sprints and approvals. | What's open in Space X? Move this task to done. |
| foundation-knowledge-base | Công cụ | Read and write knowledge base pages and their files. | What does our knowledge base say about onboarding? |
| foundation-communities | Công cụ | Organizations, their members and the people directory. | Who in our organization knows design? |
| foundation-my-tasks-triage | Quy trình | Sorts your open tasks into what to do first. | What should I focus on today? |
| foundation-space-weekly-digest | Quy trình | A one-week summary of one Space. | Summarize this week in Space X. |
REST API v1
Địa chỉ gốc https://foundation.evnx.community. Gửi Authorization: Bearer efnd_… ở mọi lần gọi. Nội dung dạng JSON. Lỗi trả về có dạng:
HTTP 404
{ "error": { "code": "not_found", "message": "Not found." } }GET/api/v1/organizations
Organizations you belong to.
GET/api/v1/organizations/:slug/members
Members of one organization.
GET/api/v1/people
Search the people directory (what you can see in the app).
- query (optional) – name, username, skill
- limit (optional, 1–50, default 24)
- offset (optional, default 0)
GET/api/v1/organizations/:slug/kb/pages
Knowledge base page tree (titles only).
POST/api/v1/organizations/:slug/kb/pages
Create an empty top-level knowledge base page.
- title (1–150 chars)
GET/api/v1/organizations/:slug/kb/pages/:pageId
One page: title, block document and plain text.
PATCH/api/v1/organizations/:slug/kb/pages/:pageId
Replace a page's title and/or document.
- title (optional, 1–150 chars)
- doc (optional) – block document JSON; replaces the whole body
GET/api/v1/spaces/:slug/tasks
Tasks of a Space.
- status (optional) – backlog | todo | in_progress | review | done
POST/api/v1/spaces/:slug/tasks
Create a task at the end of a board column.
- title (1–300 chars)
- status (optional, default todo)
GET/api/v1/spaces/:slug/tasks/:taskId
One task.
PATCH/api/v1/spaces/:slug/tasks/:taskId
Change a task. Leave a field out to keep it.
- title (1–200 chars)
- description – plain text, REPLACES the whole description (pictures and formatting are lost)
- priority – low | medium | high | urgent
- due_date – YYYY-MM-DD or null
- status – backlog | todo | in_progress | review | done
- assignees – usernames or user ids; people who are not Space members are dropped
GET/api/v1/spaces/:slug/tasks/:taskId/comments
Comments of a task, oldest first.
POST/api/v1/spaces/:slug/tasks/:taskId/comments
Post a plain-text comment. @username notifies that Space member.
- text (1–5,000 chars)
GET/api/v1/spaces/:slug/milestones
Milestones of a Space.
POST/api/v1/spaces/:slug/milestones
Create a milestone.
- title (1–120 chars)
- description (≤ 2,000)
- due_date (YYYY-MM-DD or null)
- status – planned | in_progress | done | missed
PATCH/api/v1/spaces/:slug/milestones/:milestoneId
Edit a milestone. Setting done may start an approval instead (see approvalRequested in the answer).
- Same fields as create, all optional
GET/api/v1/spaces/:slug/sprints
Sprints of a Space.
POST/api/v1/spaces/:slug/sprints
Create a planned sprint.
- name (1–80 chars)
- goal (≤ 500)
- startDate (YYYY-MM-DD)
- endDate (YYYY-MM-DD, not before startDate)
PATCH/api/v1/spaces/:slug/sprints/:sprintId
Edit a sprint's name, goal or dates.
- Same fields as create
GET/api/v1/spaces/:slug/approvals
Every approval request of a Space (needs the right to see the budget).
GET/api/v1/approvals/mine
Your own approvals across every Space.
- role (optional) – requested (default) | waiting (waiting on you to decide)
POST/api/v1/spaces/:slug/files
Upload a file for a task or comment. Returns a fileId.
- fileName
- mimeType
- base64 – the file; pictures and PDF up to 5 MB, videos are refused (use a YouTube link)
GET/api/kb-files/:fileId
A picture or file inside a task, comment or knowledge base page.
GET/api/files/:fileId
A budget receipt or attachment (needs the right to see the budget).
Chưa làm được
Định dạng phong phú trong kho kiến thức (chỉ văn bản thường), tải tệp thẳng vào trang kiến thức, việc con, nhãn, bắt đầu hay đóng sprint, ngân sách và đề nghị chi, điểm, cuộc họp và trợ lý AI. Hãy dùng ứng dụng web cho các việc này.