路由:POST /api/user/register
注册处理器:github.com/QuantumNous/new-api/controller.Register。
鉴权:匿名。路由未挂 UserAuth;仍受限流、Turnstile、一次性 flow token 或服务端业务校验约束。
字段状态:controller-confirmed。字段为动态上游数据或回调负载时,文档会明确标记,不能补造 Schema。
页面/功能:注册页创建本地账号。该接口不会自动登录。
前端传参:必传 username 与 password;email/verification_code 只在 status.email_verification=true 时必传;aff_code 可选。Turnstile 启用时附带 turnstile query。password 仅提交,不能持久化。
前端展示:仅显示 success/message;成功后引导用户前往登录,不得假定返回 access token。
调试:使用本操作的 x-debug 里的占位符;示例不含真实密码、API Key、签名、Cookie 或 Provider 密钥。