pinme-auth
仓库创建 2025年4月13日最近提交 2 天前SkillHot 收录 21 天前
▸ 精选理由
为 PinMe 项目提供标准化的用户管理与验证实现范例。
▸ 风险提示
需要项目 API Key 与处理用户敏感信息
这个 Skill 做什么
指导在 PinMe Worker (TypeScript) 中接入身份验证代理 API 的用法。
教你在 PinMe Worker(TypeScript)里接入 Identity Platform 的 auth proxy API,包含创建邮箱/密码用户、验证 id_tokens、查询用户信息或列出用户等操作。适合在 PinMe 项目里实现用户登录、鉴权或用户管理时使用。会说明需要的环境变量(如 API_KEY、PROJECT_NAME)和调用示例,方便直接落地到 Worker 服务中。
▸ 展开 SKILL.md 英文原文
Use when a PinMe project (Worker TypeScript) needs to integrate user authentication — creating email/password users, verifying id_tokens, querying user info, or listing users via Identity Platform auth proxy APIs.
3.7k
Stars
272
Forks
7
仓库内 Skill
+26
7 日增星
安装 / 使用
给你的 Agent 一句话(通用)
帮我安装这个 skill:https://raw.githubusercontent.com/glitternetwork/pinme/main/skills/pinme-auth/SKILL.md或 curl 直取 SKILL.md
curl -fsSL "https://raw.githubusercontent.com/glitternetwork/pinme/main/skills/pinme-auth/SKILL.md"SKILL.MD 节选查看完整文件 ↗
# PinMe Worker Auth API Integration
Guides how to call PinMe platform's Identity Platform auth proxy APIs in a PinMe Worker (TypeScript).
## Environment Variables
```typescript
// backend/src/worker.ts
export interface Env {
DB: D1Database;
API_KEY: string; // 项目 API Key — 用于所有 auth 接口认证
PROJECT_NAME: string; // 项目名 — 所有 auth 接口必须同时传递
BASE_URL?: string; // 可选,默认 https://pinme.cloud
}
```
> `API_KEY` 和 `PROJECT_NAME` 是所有 auth 接口的必填凭证,缺一不可。
---
## 认证方式(所有接口通用)
| 参数 | 传递方式 | 必填 | 说明 |
|------|---------|------|------|
| `X-API-Key` | 请求头 | 是 | 项目 API Key |
| `project_name` | Query 参数 | 是 | 必须与 `X-API-Key` 对应同一个项目 |
服务端会先校验这两个字段是否匹配同一个项目,再从项目配置中取出 `tenant_id`,然后转调 Identvia SKILL·HOT · 数据来自 GitHub 公开信息 · 原文版权归作者所有