Authn8

io.github.authn8由 GitHub 帳號 authn8 發布v1.1.3更新於 Nov 5, 2026

Shared 2FA for teams: let AI agents get TOTP codes for the accounts your Authn8 token can see.

已驗證Streamable HTTP可網頁執行開發者工具安全與監控

概覽

AI 產生的概覽

Authn8 的 MCP 伺服器,讓 AI 代理列出團隊共享的 2FA 帳號並取得 TOTP 驗證碼,以完成登入。

可以做什麼
  • 列出此權杖可存取的 2FA 帳號,包含名稱與簽發網域
  • 依帳號 ID 或以名稱/簽發網域模糊搜尋取得目前的 TOTP 驗證碼,多筆符合時回傳候選以便重試
  • 檢視目前權杖資訊:權杖名稱、企業、限定群組、到期時間與帳號數量
  • 所有工具都回傳結構化結果,並附帶文字區塊
適用情境
當代理需要完成需要 TOTP 驗證碼的登入,而該帳號由團隊在 Authn8 中共用時使用,不必有人從手機讀出驗證碼。適合已在用 Authn8、希望代理存取受權杖限定並留下紀錄的團隊。
執行需求
需要付費方案下的 Authn8 企業帳號;免費方案不提供 MCP 權杖,訂閱結束後權杖即失效。需要以 pat_ 開頭的 MCP 權杖,在設定的 MCP Tokens 頁面建立;託管端點以 Authorization 標頭帶入 Bearer,npm 套件則透過 AUTHN8_API_KEY 環境變數帶入。只有本機 npm 套件需要 Node.js 18 以上版本,託管端點無需安裝任何東西。
安裝前請注意
此權杖可取得即時的第二因素驗證碼,持有者即可為權杖涵蓋的帳號完成登入,應限定到指定群組並設定到期日。每次取得驗證碼都會以權杖名稱記入 Authn8 的存取紀錄。權杖屬於機密,請勿放入共用設定檔或版本控制。需付費訂閱,訂閱結束後權杖停止運作。

安裝

在 SourceWeft 中

  1. 開啟 儀表板中的 Authn8,將其新增到工作區。
  2. 連接 Authorization token 憑證。它們會被私密儲存,絕不會在公開頁面上展示。
  3. 為需要使用其工具的對話啟用該服務。

Web executable,透過 Streamable HTTP。 遠端服務在工作區中設定後即可從網頁執行環境執行。

交給代理程式安裝

把這段提示詞貼上到 Claude Code、Codex、Cursor 等代理程式,或 SourceWeft 對話中。代理程式會讀取該伺服器的安裝指南,先向你展示發布者、端點和登入方式,經你同意後再把它新增到你的客戶端。金鑰不會寫進任何命令。

閱讀 https://sourceweft.com/mcp/io.github.authn8%2Fmcp-server/install.md,並按其中說明把這個 MCP 伺服器接入我的客戶端。修改任何設定之前,先告訴我它的發布者、端點和登入方式,等我確認。不要把 API 金鑰寫進命令或我會提交的檔案;問我金鑰應從哪裡取得。

檢視代理程式所依據的安裝指南

其他 MCP 客戶端

把它新增到你客戶端的 mcpServers 設定中。

{
  "mcpServers": {
    "authn8": {
      "type": "http",
      "url": "https://api.authn8.com/mcp",
      "headers": {
        "Authorization": "Bearer <YOUR_TOKEN>"
      }
    }
  }
}

README

@authn8/mcp-server

MCP server for Authn8, shared 2FA for teams. It lets AI agents fetch TOTP codes for the 2FA accounts your team shares in Authn8, so an agent can finish a sign-in without anyone reading a code out of a phone. Every code it fetches is recorded in Authn8's access log with the name of the token that asked for it.

Listed in the MCP Registry as io.github.authn8/mcp-server.

Requirements

  • An Authn8 business on a paid plan. MCP tokens are not available on the Free plan, and a business's tokens stop working if its subscription ends.
  • An MCP token. Create one in Authn8 under Settings → MCP Tokens (how to create an MCP token). Tokens start with pat_. A token only reaches the 2FA accounts its creator can already access, and you can narrow it further to chosen groups and give it an expiry date.
  • Node.js 18 or later, if you run the npm package. The hosted endpoint needs nothing installed.

Two ways to connect

Hosted endpointnpm package
InstallNonenpx runs it locally
TransportStreamable HTTPstdio
Addresshttps://api.authn8.com/mcpnpx -y @authn8/mcp-server
TokenAuthorization: Bearer pat_... headerAUTHN8_API_KEY environment variable

Both offer the same three tools: list_accounts, get_otp and whoami.

Hosted endpoint

Point any MCP client that supports streamable HTTP at https://api.authn8.com/mcp and send your token in the Authorization header as Bearer pat_your_token_here.

Claude Code

bash
claude mcp add --transport http --scope user authn8 https://api.authn8.com/mcp \  --header "Authorization: Bearer pat_your_token_here"

npm package

Claude Code

bash
claude mcp add --env AUTHN8_API_KEY=pat_your_token_here --transport stdio --scope user authn8 \  -- npx -y @authn8/mcp-server

--scope user makes the server available in all your projects. Leave it out to add it to the current project only.

Claude Desktop

Open Settings → Developer → Edit Config, or edit the file directly:

  • macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
  • Windows: %APPDATA%\Claude\claude_desktop_config.json
  • Linux: ~/.config/Claude/claude_desktop_config.json
json
{  "mcpServers": {    "authn8": {      "command": "npx",      "args": ["-y", "@authn8/mcp-server"],      "env": {        "AUTHN8_API_KEY": "pat_your_token_here"      }    }  }}

Quit and restart Claude Desktop after saving.

Cursor

Add this to ~/.cursor/mcp.json for all projects, or to .cursor/mcp.json in a project:

json
{  "mcpServers": {    "authn8": {      "command": "npx",      "args": ["-y", "@authn8/mcp-server"],      "env": {        "AUTHN8_API_KEY": "pat_your_token_here"      }    }  }}

Other clients

Run npx -y @authn8/mcp-server as a stdio server with AUTHN8_API_KEY set.

Environment variables

VariableRequiredDefaultDescription
AUTHN8_API_KEYYes-Your MCP token (pat_...)
AUTHN8_API_URLNohttps://api.authn8.comAPI base URL

On startup the server checks the token and prints the business name, token name, account count and expiry date to stderr. It exits if the token is missing or rejected.

Tools

All tools declare an output schema and return structuredContent alongside the text block, so clients get typed results without re-parsing JSON out of text.

list_accounts

Returns all 2FA accounts accessible to this token.

Example response:

json
{  "accounts": [    {      "id": "924c52a6-4457-4970-a39f-4dc620217683",      "name": "AWS Production",      "issuerDomain": "amazon.com"    }  ]}

get_otp

Generates a TOTP code for a specific account.

Parameters:

  • account_id (string, optional): UUID of the account
  • account_name (string, optional): name or issuer domain to search for (case-insensitive partial match)

Provide either account_id or account_name. If more than one account matches the name, the tool returns them in multipleMatches so you can retry with an account_id.

Example response:

json
{  "name": "AWS Production",  "code": "483920",  "length": 6}

Ambiguous match:

json
{  "error": "Multiple accounts match 'aws'. Please be more specific or use account_id.",  "length": 0,  "multipleMatches": [    {      "id": "924c52a6-4457-4970-a39f-4dc620217683",      "name": "AWS Production",      "issuerDomain": "amazon.com"    }  ]}

whoami

Returns information about the current token.

Example response:

json
{  "tokenName": "Claude Code",  "businessName": "Acme Ltd",  "scopedGroups": [    { "id": "cfeba14a-e990-49e8-b6e5-61d63f7d68c8", "name": "Engineering" }  ],  "expiresAt": "2027-06-30T23:59:59Z",  "accountCount": 12}

Links

來源:README.md,提交 b27179e

工具

0
該伺服器需要 API 金鑰等憑證,因此 SourceWeft 無法在沒有憑證的情況下讀取其工具,也未收錄。

版本歷史

1
  1. v1.1.3最新Nov 5, 2026

評分

已滿足適用檢查項的 85%

該評分衡量此收錄條目的完整程度,依據註冊中心條目、端點與公開來源計算得出。它不是對伺服器本身的評價,也不表示伺服器安全或目前可用:可連通性是帶日期的檢查結果,評分也不包含安裝量或使用者評價。

  • 近 30 天內可連通必需25 分
  • 已宣告認證方式必需10 分
  • 已列出工具15 分

    請讓伺服器在無憑證時回應 tools/list,或發布可在沙箱中無憑證啟動的軟體包。

  • 描述必需15 分
  • 圖示10 分
  • 文件15 分
  • 授權條款10 分