{
  "openapi": "3.0.3",
  "info": {
    "title": "认证模块 - 客户端用户注册",
    "version": "1.1.0",
    "description": "认证模块相关接口文档"
  },
  "paths": {
    "/auth/client/register": {
      "post": {
        "summary": "客户端用户注册",
        "description": "客户端用户注册接口。如果 individualism=true，会为用户创建独立站点和独立数据库，并自动创建超级管理员角色。",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "description": "string｜必填，客户端用户姓名"
                  },
                  "phone": {
                    "type": "string",
                    "description": "string｜必填，手机号"
                  },
                  "password": {
                    "type": "string",
                    "description": "string｜必填，登录密码"
                  }
                },
                "required": [
                  "name",
                  "phone",
                  "password"
                ]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "成功响应",
            "content": {
              "application/json": {
                "example": {
                  "success": {
                    "code": "0000",
                    "message": "注册成功",
                    "data": {
                      "clientUserId": "CU0001",
                      "token": "jwt-token",
                      "scopeKeys": [
                        {
                          "key": "uuid-personal",
                          "type": "personal",
                          "label": "个人"
                        },
                        {
                          "key": "uuid-org",
                          "type": "organization",
                          "organizationId": 1,
                          "label": "示例公司"
                        }
                      ],
                      "defaultScopeKey": "uuid-org"
                    }
                  },
                  "failure": {
                    "code": "4000",
                    "message": "注册失败",
                    "data": null
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}