urantia-papers
Official尤里西亚之书 API
一个对开发者和 AI 代理友好的《尤里西亚之书》API。提供全文搜索、结构化内容访问,以及涵盖 197 篇论文中 14,500 多个段落的音频 URL。
API 端点
方法 | 路径 | 描述 |
GET |
| 目录(部分 → 论文) |
GET |
| 列出所有 197 篇论文 |
GET |
| 获取单篇论文及其所有段落 |
GET |
| 论文内的章节 |
GET |
| 随机段落 |
GET |
| 通过任意 ID 格式获取段落 |
GET |
| 获取带有上下文的段落 |
POST |
| 带分页的全文搜索 |
GET |
| 段落的音频信息 |
POST |
| 语义(向量)搜索 |
GET |
| 列出实体(人物、地点、概念等) |
GET |
| 实体详情 |
GET |
| 提及某实体的段落 |
GET |
| 生成引用(APA, MLA, Chicago, BibTeX) |
GET |
| 动态 Open Graph 图像 |
POST |
| 段落的向量嵌入 |
GET |
| 用户资料(需授权) |
POST |
| 创建书签(需授权) |
GET |
| 列出书签(需授权) |
GET |
| 列出笔记(需授权) |
POST |
| 创建笔记(需授权) |
GET |
| 阅读进度(需授权) |
GET |
| 用户偏好(需授权) |
POST |
| 获取授权码(需授权) |
POST |
| 交换令牌的授权码 |
GET |
| 获取 OAuth 应用信息 |
交互式文档可在 /docs (Swagger UI) 查看。OpenAPI 规范位于 /openapi.json。
Related MCP server: mnemex
SDK
官方 TypeScript SDK 可在 npm 上获取:
npm install @urantia/api # Typed client for all endpoints
npm install @urantia/auth # OAuth client for accounts.urantiahub.com请参阅 urantia.dev/sdks 获取文档。
段落 ID 格式
API 接受三种引用格式——从字符串中自动检测:
格式 | 示例 | 结构 |
globalId |
|
|
standardReferenceId |
|
|
paperSectionParagraphId |
|
|
搜索
curl -X POST https://api.urantia.dev/search \
-H "Content-Type: application/json" \
-d '{"q": "Universal Father", "limit": 10, "type": "and"}'搜索模式:and(所有词,默认)、or(任意词)、phrase(精确匹配)。可选过滤器:paperId, partId。
音频
段落包含一个 audio 字段——一个按模型和语音键入的嵌套对象,如果没有音频则为 null:
{
"audio": {
"tts-1-hd": {
"nova": { "format": "mp3", "url": "https://audio.urantia.dev/tts-1-hd-nova-3:119.1.5.mp3" },
"echo": { "format": "mp3", "url": "https://audio.urantia.dev/tts-1-hd-echo-3:119.1.5.mp3" }
}
}
}可用的模型和语音因段落而异。专用的 /audio/:paragraphId 端点仅返回给定段落的音频数据。
缓存
响应包含 Cache-Control 标头。Cloudflare 的 CDN 通过 s-maxage 在边缘进行缓存:
路由 | CDN (s-maxage) | 浏览器 (max-age) |
| 24 小时 | 1 小时 |
| 1 小时 | 5 分钟 |
| no-store | no-store |
| 1 小时 | 5 分钟 |
面向 AI 代理
推荐流程:
GET /toc— 理解书籍结构POST /search— 查找相关段落GET /paragraphs/:ref/context?window=3— 获取周围上下文GET /papers/:id— 阅读完整论文
MCP 服务器
该 API 在 https://api.urantia.dev/mcp 包含一个内置的 MCP 服务器——连接 Claude Desktop、Cursor 或任何 MCP 客户端以访问:
13 个工具 — 搜索、段落查找、论文导航、实体浏览、音频
2 个资源模板 —
urantia://paper/{id}(markdown) 和urantia://entity/{id}2 个提示词模板 —
study_assistant,comparative_theology
通过 Smithery 一键安装。
身份验证
公共端点无需授权。用户端点 (/me/*) 需要 JWT。OAuth 流程:
通过
POST /auth/apps(管理员) 或在 accounts.urantiahub.com/developer 自助注册应用用户在 accounts.urantiahub.com 登录
通过
POST /auth/token将授权码交换为访问令牌将令牌作为
Authorization: Bearer <token>传递
访问令牌是有效期为 7 天的 HS256 JWT。基于浏览器的应用支持 PKCE。
可观测性
日志记录: 通过
@logtail/edge使用 BetterStack — 带有请求元数据的结构化 JSON 日志错误跟踪: 全局错误处理程序将堆栈跟踪发送到 BetterStack
健康检查:
GET /health— 验证数据库连接正常运行时间: BetterStack 正常运行时间监控
技术栈
运行时: Bun (开发) / Cloudflare Workers (生产)
框架: Hono + @hono/zod-openapi
数据库: Supabase (PostgreSQL + pgvector)
ORM: Drizzle
可观测性: BetterStack (日志记录、正常运行时间)
开发
# Install dependencies
bun install
# Set up environment
cp .env.example .env
# Edit .env with your Supabase DATABASE_URL
# Push schema to database
bun run db:push
# Set up full-text search (run after db:push)
bun scripts/run-fts-setup.ts
# Generate audio manifest (requires ../urantia-hub-api)
bun run generate-manifest
# Seed database from urantia-papers-json
bun run seed
# Start dev server (hot reload)
bun run dev服务器默认在 http://localhost:3000 运行。
部署
部署到 Cloudflare Workers。首次设置:
npx wrangler login
npx wrangler secret put DATABASE_URL
# paste your Supabase connection string (use pooler port 6543)
npx wrangler secret put APP_JWT_SECRET
# paste a 64-byte hex secret: node -e "console.log(require('crypto').randomBytes(64).toString('hex'))"
npx wrangler secret put ADMIN_USER_IDS
# comma-separated Supabase user UUIDs for admin access部署:
bun run deploy数据
内容来源于 urantia-papers-json — 197 篇论文、1,626 个章节、14,500 多个段落,通过 audio.urantia.dev 提供音频叙述。
许可证
本项目采用 MIT 许可证 授权。
免责声明
这是一个由 Adams Technologies LLC 发起的独立社区项目。它与尤里西亚基金会(Urantia Foundation)无关,未得到其认可或关联。《尤里西亚之书》的原始英文文本属于公有领域(Michael Foundation v. Urantia Foundation, 10th Cir. 2003)。所有对“Urantia”的使用均为识别主题的提名性合理使用。
This server cannot be deployed
Maintenance
Related MCP Connectors
MCP server for Project Gutenberg — 75,000+ public-domain ebooks with full plain-text retrieval.
Free, no-key Bible MCP server — 86 translations in 32 languages, from any MCP client.
Bible corpus MCP server: scripture, Greek/Hebrew interlinear data, cross-refs, semantic search.
Related MCP Servers
- AlicenseAqualityAmaintenanceFree, no-key MCP server for reading scripture from 35+ public-domain translations in 8 languages. Lets users fetch verses, chapters, and passages via natural language from any MCP client.7136 npm1MIT
- AlicenseNot gradedqualityCmaintenanceAn MCP server that ingests books into a structured, cross-linked wiki of sources, entities, concepts, and syntheses, managed by an LLM.41 npm2MIT
- AlicenseNot gradedqualityAmaintenanceSemantic search and comparative retrieval over a multi-tradition corpus of sacred and foundational texts, exposed as an MCP server.MIT
- FlicenseNot gradedqualityAmaintenanceAn MCP server for Christian scholarship and research, providing read-only access to a SQLite corpus of 66-book BSB and 83-book WEB Bibles, original-language Greek/Hebrew word studies with Strong's and morphology, cross-references, patristic citations (Irenaeus, Justin Martyr, Apostolic Fathers), verse alignments, semantic and hybrid search over ~55,800 embeddings, and multi-work passage retrieval, interlinear lookup, and research-brief synthesis prompts.3-