OSF CLI Go

io.github.edithatogo由 GitHub 帳號 edithatogo 發布v0.3.2更新於 Oct 24, 2026

Read-only MCP tools for authenticated Open Science Framework projects and files.

已驗證STDIO僅桌面檔案與儲存知識與記憶

概覽

AI 產生的概覽

一個本機 stdio MCP 伺服器,提供唯讀工具,用來存取需驗證的 Open Science Framework 專案、檔案、預印本與 DOI 查詢。

可以做什麼
辨識目前驗證的 OSF 帳號,列出或檢視專案及其元件,包括貢獻者與 OSF Storage 檔案(僅列出)。檢索 OSF 文獻與預印本,結果數量有上限,回傳含 ID、標題、摘要、關鍵字、年份與連結的結構化 JSON。解析 OSF DOI 指向的目標位址。所有對外提供的工具皆為唯讀,不會執行寫入操作。
適用情境
適合助理在研究或文獻回顧過程中直接查詢 OSF 專案、元件、貢獻者、檔案、預印本或 DOI 目標,不必離開對話。不適用於上傳、刪除或建立 OSF 內容,因為 MCP 工具是唯讀的。
執行需求
以 stdio 本機程序執行,以 OCI 映像散布;若從原始碼建置,底層 CLI 需要 Go 1.26 或更新版本。需要 OSF 帳號憑證:優先使用 OSF_TOKEN,OSF_USERNAME 與 OSF_PASSWORD 為選用的備援。需要能連線至 OSF API 的網路存取。
安裝前請注意
需要 OSF 個人存取權杖或帳號憑證;請勿將權杖寫入專案檔案或提交至版本庫。使用者名稱/密碼備援方式不適合自動化,也不適合使用 SSO 或雙因素驗證的帳號。MCP 工具為唯讀,但隨附的 CLI 可上傳、刪除、建立註冊與修改專案,應限制助理可執行的指令範圍。

安裝

在 SourceWeft 中

  1. 開啟 儀表板中的 OSF CLI Go,將其新增到工作區。
  2. 為需要使用其工具的對話啟用該服務。

Desktop only,透過 STDIO。 STDIO 服務會啟動本機處理程序,因此需要 SourceWeft 桌面主機。

其他 MCP 客戶端

參照 儲存庫 中的啟動說明。

README

osf-cli-go

A Go command-line client for the Open Science Framework (OSF).

[CI] [Lint] [Security] [Go Reference] [License] [Go Version] [Release] [OSF CLI Go MCP server]

Features

  • osf auth whoami — Identify the authenticated OSF account
  • osf auth login — Guided personal-access-token bootstrap for username/password users
  • osf projects list|get — List and inspect projects
  • osf components list — List project components
  • osf files list|download|upload|mkdir|rm — Browse, download, upload, create folders, and delete OSF Storage files
  • osf search, osf search --bibtex, osf preprints list|search, and osf resolve — Search/export OSF literature metadata, discover preprints, and resolve OSF DOI destinations
  • osf registrations create — Create draft registrations for an existing node
  • osf export — Export a node snapshot as JSON or a summary table
  • osf validate — Check OSF node metadata with deterministic research-output or preregistration profiles
  • osf-mcp — Stdio MCP server exposing read-only OSF tools for agent clients
  • osf completion bash|zsh|fish|powershell — Shell completion scripts
  • JSON and human-readable output modes
  • Safe, atomic file downloads with conflict policy (fail/skip/overwrite)

Install

Requirements:

  • Go 1.26 or newer
powershell
go install github.com/edithatogo/osf-cli-go/cmd/osf@latestgo install github.com/edithatogo/osf-cli-go/cmd/osf-mcp@latest

Or from a local checkout:

powershell
go build -o bin\osf.exe ./cmd/osfgo build -o bin\osf-mcp.exe ./cmd/osf-mcp.\scripts\build.ps1

Authentication

Set OSF_TOKEN in your shell session. Do not commit the token or write it into project files. OSF_USERNAME and OSF_PASSWORD are supported as an opt-in fallback credential source, but personal access tokens remain preferred for automation and for accounts using SSO or two-factor authentication.

powershell
$env:OSF_TOKEN = '<your-token>'

For guided token setup:

powershell
osf auth login

Quick Start

powershell
osf --helposf auth whoamiosf projects listosf projects get https://osf.io/abc12/osf components list abc12osf files list abc12osf files download --file <file-id> ./output/osf files download --tree abc12 ./output/osf files upload --node abc12 ./report.pdfosf search "open science"osf search "open science" --bibtexosf preprints listosf preprints search "open science" --provider osfosf resolve 10.1234/exampleosf registrations create abc12 --schema <schema-id> --title "Analysis plan"osf export abc12 --json

MCP Server

osf-mcp runs a stdio MCP server with read-only tools: osf_whoami, osf_projects_list, osf_project_get, osf_components_list, osf_files_list, osf_contributors_list, osf_search, osf_preprints_list, osf_preprints_search, and osf_doi_resolve.

The parity discovery tools are bounded and deterministic: osf_search requires a non-empty query and accepts a limit from 1 to 100, while osf_preprints_list accepts an optional provider and the same bounded limit. osf_preprints_search requires a title query, accepts an optional provider, and returns publication date, published state, DOI, and OSF HTML URL with a limit from 1 to 100. These tools return structured JSON through the MCP server and never perform writes.

OSF search results include stable IDs, title, abstract, keywords, year, and URL. Use osf search <query> --bibtex to emit deterministic BibTeX records for literature-review workflows. The command does not resolve contributor names or download PDFs automatically.

For DataLad workflows, OSF CLI Go provides the general-purpose OSF API and safe file primitives used around a dataset, including osf export and osf files download --tree. It does not install or configure DataLad, Git remotes, or git-annex special remotes; those integrations remain a separately scoped interoperability boundary.

Local development configs are included for GitHub Copilot, VS Code, Claude, Codex, Gemini CLI, and Qwen Code. Public registry metadata is in server.json and registry/.

Related MCP Servers

Other maintained servers in the same Glama portfolio:

  • FYI MCP for freedom-of-information request workflows.
  • Healthpoint MCP for licensed health-service directory data.
  • SourceRight for reference and citation verification.

Related OSF ecosystem servers:

Output Modes

All commands support --output table|json and --json shorthand:

powershell
osf projects list --jsonosf auth whoami --output json

Project Status

The CLI is offline-tested for read-only operations, file downloads, WaterButler write primitives, search, preprint listing, draft registration creation, project create/update/delete operations, and node export. All Conductor tracks are reconciled against their per-track plans with closeout review evidence; live OSF validation remains opt-in because it requires credentials and network access.

Documentation

License

Apache 2.0 — see LICENSE.

Citation

If you use this software in your research, please cite it using the metadata in CITATION.cff.

來源:README.md,提交 61627db

工具

0
SourceWeft 尚未在沙箱中啟動過該軟體包,因此其工具未知。

版本歷史

1
  1. v0.3.2最新Sep 16, 2026

評分

已滿足適用檢查項的 50%

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

  • 近 30 天內可連通25 分

    請保持端點能夠回應 MCP 握手;SourceWeft 每 30 天探測一次。

  • 已宣告認證方式10 分

    請在註冊中心條目中宣告憑證請求標頭,或保持端點能夠回應探測,以便判定其認證方式。

  • 已列出工具15 分

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

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