Yaonic Korea 0.2.1 로그인 · 모델 · 기존 Agent · 관리 명령 · MCP 사용법: yaonic [options] login [--base-url ORIGIN] [--write] [--no-browser] logout | whoami | devices [list|revoke --device-id ID] models [QUERY] | doctor | auth | env | update [--dry-run] docs | openapi | search QUERY claude|codex|opencode|hermes [--model MODEL] [--reasoning-effort LEVEL] [--no-mcp] [--dry-run] [-- agent-args] setup claude|codex|opencode [--model MODEL] keys list|create|revoke|budget usage [get] | billing get|budgets|budget-set org list|get|members|projects|invite|project-create org project-scope | org project-rename --body '{"name":"NAME"}' org project-archive security get|set|privacy|privacy-set audit list|export|export-revoke api METHOD PATH [--body JSON] mcp --params JSON --body JSON|@FILE --key-id ID --member-id ID --export-id ID --device-id ID --secret-file FILE (keys create / org invite; new 0600 file) --json --lang ko|en|zh-CN 기기 승인: 사용자 코드 600초, 폴링 간격 5초 이상. slow_down 응답마다 5초를 추가합니다. 관리 세션과 모델 Key는 따로 발급합니다. 권한: 기본 management:read. login --write로 management:write를 요청합니다. 서버에서 현재 멤버십, 역할, MFA, IP 정책을 확인합니다. 자격 증명: YAONIC_HOME/credentials.json 파일 0600, 디렉터리 0700. 로그인한 origin에만 전송하며 HTTPS와 로컬 루프백을 지원합니다. Agent: 설치된 도구를 실행합니다. dry-run은 비밀값을 가립니다. 모델 Key는 자식 프로세스 환경으로 전달합니다. Claude/Codex/OpenCode는 관리 MCP를 연결합니다. Hermes는 custom OpenAI 호환 엔드포인트를 사용합니다. 설정: 기존 설정을 백업한 뒤 원자적으로 저장합니다. JSON과 TOML을 지원합니다. Codex/OpenCode는 런처 또는 yaonic env가 YAONIC_MODEL_KEY를 제공합니다. MCP: whoami/openapi/api/models/docs/search. API 요청은 로그인한 조직과 프로젝트에서 실행되며 서버가 현재 권한을 적용합니다. 새 Key와 초대 토큰: keys create / org invite --secret-file FILE로 새 0600 파일에 저장합니다. 표준 출력은 비밀값을 가립니다. 공식 SDK 예제: examples/python, examples/typescript, examples/curl. 모델, 프롬프트, 토큰 상한이 같습니다. 사용 가능한 모델과 메타데이터는 yaonic models로 조회합니다. 금액은 KRW 문자열, 청구 시간대는 Asia/Seoul입니다. 관리 API: 조직, Key, 지갑, 사용량, 보안 및 감사 API가 연결되어 있습니다. 프로젝트: org project-scope로 기기에 연결된 프로젝트를 조회합니다. project-rename과 project-archive는 management:write 및 소유자/관리자 권한이 필요합니다. 보관 처리 후 새 요청은 차단되고 기존 사용량은 유지됩니다. 로그아웃: 서버의 기기 세션과 모델 Key를 해지한 뒤 로컬 자격 증명을 삭제합니다. 만료된 로컬 정보도 정리합니다. 빠른 시작: yaonic login → yaonic models → yaonic claude (또는 codex/opencode/hermes). 기본 모델은 현재 Key로 사용할 수 있고 도구의 API 형식을 지원하는 첫 번째 텍스트 모델입니다. --model로 직접 선택할 수 있습니다. 기기 승인에서 브라우저의 계정과 조직/프로젝트, management:read 및 model:invoke를 확인하세요. 쓰기 관리에는 login --write를 사용합니다. yaonic auth에서 origin, 범위, 만료 시각을 확인합니다. 프로젝트를 바꾸려면 logout 후 login에서 다시 선택하세요. 설정 후 직접 실행: yaonic setup codex 또는 setup opencode → eval "$(yaonic env)" → codex 또는 opencode. env는 Bash/Zsh용 자격 증명을 stdout에 출력하므로 셸에서 직접 사용하세요. Claude는 자격 증명 helper를 사용합니다. 런처는 기존 설정을 저장하지 않고 현재 실행만 연결합니다. Agent 인자: yaonic claude -p "README 요약"; yaonic codex --reasoning-effort high exec "README 요약". --no-mcp로 자동 관리 MCP를 제외합니다. Codex 0.36에서는 이번 실행의 모든 MCP 구성을 비웁니다. CI: YAONIC_API_KEY와 YAONIC_BASE_URL을 secret store로 주입합니다. 환경 Key는 모델 호출에 사용되며 관리 명령은 기기 세션으로 실행합니다. 문서 검색: search QUERY는 포함된 관리 API 문서를 검색합니다. docs/openapi는 오프라인으로 사용할 수 있습니다. 웹 문서: /connect, /llms.txt, /llms-full.txt, /openapi.json. 업데이트: yaonic update --dry-run으로 설치 명령을 보고 yaonic update로 현재 사이트의 패키지를 설치합니다. login_required: yaonic login으로 브라우저에서 기기를 승인하세요. session_expired_login_required: yaonic logout 후 yaonic login으로 다시 승인하세요. model_key_required: yaonic login을 실행하거나 CI에서 YAONIC_API_KEY와 YAONIC_BASE_URL을 설정하세요. agent_not_installed: 선택한 도구를 먼저 설치하세요. /connect의 공식 설치 안내와 yaonic doctor를 확인하세요. agent_start_failed: yaonic doctor로 도구 설치 상태를 확인하세요. model_unavailable: yaonic models에서 해당 도구의 API 형식을 지원하는 모델을 선택하세요. no_compatible_models: yaonic models와 프로젝트 Key의 모델 범위를 확인하세요. logout_existing_device_before_login: yaonic logout 후 login을 실행하고 새 조직/프로젝트를 선택하세요. insufficient_scope: yaonic logout 후 yaonic login --write로 관리 권한을 요청하세요. connection_failed: yaonic auth에서 주소를 확인하고 yaonic doctor를 실행하세요. 쓰기 요청은 서버 결과를 확인한 뒤 처리하세요. expired_token: yaonic login을 다시 실행해 새 기기 코드를 받으세요. access_denied: 브라우저의 계정·조직·프로젝트를 확인한 뒤 login을 다시 실행하세요. scope_forbidden: 승인한 조직/프로젝트와 멤버 권한을 확인하세요. yaonic auth로 현재 범위를 볼 수 있습니다. Yaonic Korea 0.2.1 Login · Models · Existing agents · Management · MCP Usage: yaonic [options] login [--base-url ORIGIN] [--write] [--no-browser] logout | whoami | devices [list|revoke --device-id ID] models [QUERY] | doctor | auth | env | update [--dry-run] docs | openapi | search QUERY claude|codex|opencode|hermes [--model MODEL] [--reasoning-effort LEVEL] [--no-mcp] [--dry-run] [-- agent-args] setup claude|codex|opencode [--model MODEL] keys list|create|revoke|budget usage [get] | billing get|budgets|budget-set org list|get|members|projects|invite|project-create org project-scope | org project-rename --body '{"name":"NAME"}' org project-archive security get|set|privacy|privacy-set audit list|export|export-revoke api METHOD PATH [--body JSON] mcp --params JSON --body JSON|@FILE --key-id ID --member-id ID --export-id ID --device-id ID --secret-file FILE (keys create / org invite; new 0600 file) --json --lang ko|en|zh-CN Device: user code 600s; poll >=5s; slow_down adds 5s. Session and model Key are separate. Permissions: management:read by default; login --write requests management:write. Server checks live membership, role, MFA and IP. Credentials: YAONIC_HOME/credentials.json (0600), directory 0700. Origin-bound, HTTPS or local loopback. Agents: existing installed tools; dry-run redacts secrets; model API Key goes to child environment. Claude/Codex/OpenCode attach management MCP. Hermes uses the custom OpenAI-compatible endpoint. Setup: backup before atomic replacement; JSON/TOML supported. Codex/OpenCode use YAONIC_MODEL_KEY supplied by the launcher or yaonic env. MCP: whoami/openapi/api/models/docs/search. API requests run in the signed-in organization and project with the current server permissions. New Keys/invitation tokens: keys create / org invite --secret-file FILE saves to a new 0600 file. Standard output redacts secrets. SDK: examples/python, examples/typescript, examples/curl use official OpenAI and Anthropic packages. Same model/prompt/token limit. yaonic models reads available models and supplied metadata. KRW amount strings, Asia/Seoul billing. Management: organization, Key, wallet, usage, security and audit APIs are integrated. Projects: org project-scope reads the device-bound project. project-rename and project-archive require management:write and an owner/admin role. Archiving blocks new requests and retains historical usage. Logout: server revokes session and device model Key, then removes local credentials. Expired local credentials are also cleared. Quick start: yaonic login → yaonic models → yaonic claude (or codex/opencode/hermes). The default is the first text model available to your Key that supports the tool's protocol. Select another with --model. In the browser, check the account, organization/project and requested management:read and model:invoke scopes. Use login --write for management writes. yaonic auth shows the origin, scope and expiry. To change projects, logout and select the new project during login. Start native tools after setup: yaonic setup codex or setup opencode → eval "$(yaonic env)" → codex or opencode. env prints credentials for Bash/Zsh on stdout; use it directly in your shell. Claude uses a credential helper. Launchers apply configuration to the current process. Agent arguments: yaonic claude -p "Summarize README"; yaonic codex --reasoning-effort high exec "Summarize README". --no-mcp excludes automatic management MCP. Codex 0.36 clears all MCP configuration for that run. CI: inject YAONIC_API_KEY and YAONIC_BASE_URL from your secret store. The environment Key invokes models; management commands use the device session. Documentation search: search QUERY searches packaged management API docs. docs/openapi work offline. Web docs: /connect, /llms.txt, /llms-full.txt, /openapi.json. Update: yaonic update --dry-run shows the install command; yaonic update installs the package from the current site. login_required: Run yaonic login and approve this device in your browser. session_expired_login_required: Run yaonic logout, then yaonic login to renew the device grant. model_key_required: Run yaonic login, or set YAONIC_API_KEY and YAONIC_BASE_URL in CI. agent_not_installed: Install the selected tool using its official link on /connect, then run yaonic doctor. agent_start_failed: Run yaonic doctor to check the installed executable. model_unavailable: Run yaonic models and select a model supporting this tool's protocol. no_compatible_models: Check yaonic models and the model scope of your project Key. logout_existing_device_before_login: Run yaonic logout, then login and select the new organization/project. insufficient_scope: Run yaonic logout, then yaonic login --write to request management access. connection_failed: Check the endpoint with yaonic auth and run yaonic doctor. Check the server result before repeating a write. expired_token: Run yaonic login again to obtain a new device code. access_denied: Check the browser account, organization and project, then run login again. scope_forbidden: Check membership in the approved organization/project. yaonic auth shows the current scope. Yaonic Korea 0.2.1 登录 · 模型 · 现成 Agent · 管理命令 · MCP 用法: yaonic [options] login [--base-url ORIGIN] [--write] [--no-browser] logout | whoami | devices [list|revoke --device-id ID] models [QUERY] | doctor | auth | env | update [--dry-run] docs | openapi | search QUERY claude|codex|opencode|hermes [--model MODEL] [--reasoning-effort LEVEL] [--no-mcp] [--dry-run] [-- agent-args] setup claude|codex|opencode [--model MODEL] keys list|create|revoke|budget usage [get] | billing get|budgets|budget-set org list|get|members|projects|invite|project-create org project-scope | org project-rename --body '{"name":"NAME"}' org project-archive security get|set|privacy|privacy-set audit list|export|export-revoke api METHOD PATH [--body JSON] mcp --params JSON --body JSON|@FILE --key-id ID --member-id ID --export-id ID --device-id ID --secret-file FILE (keys create / org invite; new 0600 file) --json --lang ko|en|zh-CN 设备授权:用户码有效期 600 秒,轮询间隔至少 5 秒;收到 slow_down 后增加 5 秒。管理 session 和模型 Key 分别签发。 权限:默认 management:read;login --write 申请 management:write。服务端核对当前成员关系、角色、MFA 和 IP 策略。 凭证:YAONIC_HOME/credentials.json 权限 0600,目录 0700。凭证绑定登录 origin,支持 HTTPS 与本机回环地址。 Agent:启动本机已安装工具;dry-run 隐藏凭证。模型 Key 通过子进程环境传入。Claude/Codex/OpenCode 挂载管理 MCP;Hermes 使用 custom OpenAI 兼容入口。 配置:写入前备份,原子替换。支持 JSON/TOML。Codex/OpenCode 通过启动器或 yaonic env 获得 YAONIC_MODEL_KEY。 MCP:whoami/openapi/api/models/docs/search。API 请求使用登录的组织和项目,由服务端执行当前权限。 新 Key 与邀请 token:keys create / org invite --secret-file FILE 保存到新建的 0600 文件,标准输出隐藏凭证。 官方 SDK:examples/python、examples/typescript、examples/curl 的模型、提示词和 token 上限一致。yaonic models 查询可用模型及服务端提供的元数据。金额为 KRW 字符串,账期为 Asia/Seoul。 管理 API:管理组织、项目、Key、钱包、用量、安全设置与操作记录。 项目:org project-scope 读取设备绑定项目;project-rename、project-archive 使用 management:write 和 Owner/Admin 角色。归档后拒绝新请求,历史用量继续保留。 退出:服务端撤销设备 session 与模型 Key 后清理本地凭证;已过期的本地凭证直接清理。 快速开始:yaonic login → yaonic models → yaonic claude(或 codex/opencode/hermes)。默认选择当前 Key 可用、且支持工具协议的第一个文本模型;可用 --model 指定。 在浏览器核对账号、组织/项目和 management:read、model:invoke 权限;管理写入使用 login --write。yaonic auth 显示地址、范围和到期时间。切换项目时先 logout,再通过 login 选择新项目。 持久配置后直接启动:yaonic setup codex 或 setup opencode → eval "$(yaonic env)" → codex 或 opencode。env 会向标准输出提供 Bash/Zsh 凭证导出语句,请直接在本机 shell 使用。Claude 使用凭证 helper。常规启动器只设置本次运行。 Agent 参数:yaonic claude -p "概括 README";yaonic codex --reasoning-effort high exec "概括 README"。--no-mcp 关闭自动管理 MCP。Codex 0.36 会清空本次运行的全部 MCP 配置。 CI:通过密钥管理工具注入 YAONIC_API_KEY、YAONIC_BASE_URL。环境 Key 用于模型调用,管理命令使用设备 session。 文档搜索:search QUERY 检索包内管理 API 文档。docs/openapi 可离线使用。网页入口:/connect、/llms.txt、/llms-full.txt、/openapi.json。 更新:yaonic update --dry-run 显示安装命令;yaonic update 安装当前站点的包。 login_required: 运行 yaonic login,在浏览器批准设备。 session_expired_login_required: 运行 yaonic logout,再运行 yaonic login 重新批准设备。 model_key_required: 运行 yaonic login;CI 可设置 YAONIC_API_KEY 和 YAONIC_BASE_URL。 agent_not_installed: 通过 /connect 的官方链接安装所选工具,再运行 yaonic doctor。 agent_start_failed: 运行 yaonic doctor 检查工具安装状态。 model_unavailable: 运行 yaonic models,选择支持该工具协议的模型。 no_compatible_models: 检查 yaonic models 和项目 Key 的模型使用范围。 logout_existing_device_before_login: 运行 yaonic logout,再登录并选择新的组织与项目。 insufficient_scope: 运行 yaonic logout,再通过 yaonic login --write 申请管理权限。 connection_failed: 用 yaonic auth 核对地址,再运行 yaonic doctor。写入断线后先查服务端结果。 expired_token: 重新运行 yaonic login 获取新设备码。 access_denied: 核对浏览器中的账号、组织和项目,再运行 login。 scope_forbidden: 检查已批准组织、项目及成员权限。yaonic auth 可查看当前范围。 { "openapi": "3.1.0", "info": { "title": "Yaonic Korea CLI management API", "version": "0.1.0", "description": "Manage your organizations, projects, Keys, wallet, usage, security and activity records." }, "servers": [ { "url": "{origin}", "variables": { "origin": { "default": "http://localhost:18080" } } } ], "components": { "securitySchemes": { "deviceSession": { "type": "http", "scheme": "bearer", "description": "ycs_ management session; model API Keys are separate." }, "browserSession": { "type": "apiKey", "in": "cookie", "name": "session", "description": "Existing Korea User session. Browser middleware also checks CSRF and MFA/access policy." } }, "schemas": { "Envelope": { "type": "object", "required": [ "success", "message", "data" ], "properties": { "success": { "type": "boolean" }, "message": { "type": "string" }, "code": { "type": "string" }, "data": {} } }, "Money": { "type": "object", "required": [ "currency", "amount" ], "properties": { "currency": { "const": "KRW" }, "amount": { "type": "string", "pattern": "^-?[0-9]+([.][0-9]+)?$" } } }, "DeviceAuthorize": { "type": "object", "properties": { "client_id": { "const": "yaonic-cli" }, "device_name": { "type": "string", "maxLength": 100 }, "scope": { "type": "string", "description": "management:read [management:write] [model:invoke]" } }, "required": [ "client_id" ], "additionalProperties": false }, "DeviceAuthorization": { "type": "object", "properties": { "device_code": { "type": "string" }, "user_code": { "type": "string", "pattern": "^[A-Z2-9]{4}-[A-Z2-9]{4}$" }, "verification_uri": { "type": "string", "format": "uri" }, "verification_uri_complete": { "type": "string", "format": "uri" }, "expires_in": { "const": 600 }, "interval": { "const": 5 } }, "required": [ "device_code", "user_code", "verification_uri", "expires_in", "interval" ], "additionalProperties": false }, "DevicePoll": { "type": "object", "properties": { "client_id": { "const": "yaonic-cli" }, "device_code": { "type": "string" }, "grant_type": { "const": "urn:ietf:params:oauth:grant-type:device_code" } }, "required": [ "client_id", "device_code", "grant_type" ], "additionalProperties": false }, "DeviceTokens": { "type": "object", "properties": { "access_token": { "type": "string" }, "token_type": { "const": "Bearer" }, "expires_in": { "type": "integer" }, "expires_at": { "type": "integer" }, "scope": { "type": "string" }, "model_key": { "type": "string" }, "device_id": { "type": "string" }, "organization_id": { "type": "string", "pattern": "^[1-9][0-9]*$" }, "project_id": { "type": "string", "pattern": "^[1-9][0-9]*$" } }, "required": [ "access_token", "token_type", "expires_at", "scope", "device_id", "organization_id", "project_id" ], "additionalProperties": false }, "DeviceDecision": { "type": "object", "properties": { "user_code": { "type": "string" }, "organization_id": { "type": "string", "pattern": "^[1-9][0-9]*$" }, "project_id": { "type": "string", "pattern": "^[1-9][0-9]*$" }, "approve": { "type": "boolean" } }, "required": [ "user_code", "organization_id", "project_id", "approve" ], "additionalProperties": false }, "CreateKey": { "type": "object", "properties": { "name": { "type": "string", "maxLength": 100 }, "service": { "type": "boolean", "default": false } }, "required": [ "name" ], "additionalProperties": false }, "CreateOrganization": { "type": "object", "properties": { "name": { "type": "string", "minLength": 1, "maxLength": 120 } }, "required": [ "name" ], "additionalProperties": false }, "CreateProject": { "type": "object", "properties": { "name": { "type": "string", "minLength": 1, "maxLength": 120 } }, "required": [ "name" ], "additionalProperties": false }, "RenameProject": { "type": "object", "properties": { "name": { "type": "string", "minLength": 1, "maxLength": 120 } }, "required": [ "name" ], "additionalProperties": false }, "InviteMember": { "type": "object", "properties": { "email": { "type": "string", "format": "email" }, "role": { "enum": [ "admin", "finance", "member" ] }, "project_id": { "type": "string", "pattern": "^[1-9][0-9]*$", "description": "Optional project membership; must match the device-bound project." } }, "required": [ "email", "role" ], "additionalProperties": false }, "UpdateMember": { "type": "object", "properties": { "role": { "enum": [ "owner", "admin", "finance", "member" ] }, "active": { "type": "boolean" }, "department": { "type": "string" } }, "required": [ "role", "active" ], "additionalProperties": false }, "TransferKey": { "type": "object", "properties": { "member_id": { "type": "string", "pattern": "^[1-9][0-9]*$" } }, "required": [ "member_id" ], "additionalProperties": false }, "AccessPolicy": { "type": "object", "properties": { "require_mfa": { "type": "boolean" }, "console_ips": { "type": "array", "items": { "type": "string" } }, "api_ips": { "type": "array", "items": { "type": "string" } }, "session_hours": { "type": "integer", "minimum": 1, "maximum": 24 } }, "required": [ "require_mfa", "console_ips", "api_ips", "session_hours" ], "additionalProperties": false }, "Retention": { "type": "object", "properties": { "request": { "type": "boolean" }, "response": { "type": "boolean" }, "attachment": { "type": "boolean" }, "preview": { "type": "boolean", "description": "Requires request retention" }, "days": { "enum": [ 7, 14, 30 ] } }, "required": [ "request", "response", "attachment", "preview", "days" ], "additionalProperties": false }, "PrivacyRule": { "type": "object", "properties": { "id": { "type": "string", "pattern": "^[A-Za-z0-9_-]{1,64}$" }, "name": { "type": "string" }, "kind": { "enum": [ "keyword", "regex", "email", "kr_phone", "kr_resident", "card" ] }, "pattern": { "type": "string" }, "action": { "enum": [ "REDACT", "BLOCK" ] }, "objects": { "type": "array", "minItems": 1, "maxItems": 4, "items": { "enum": [ "system", "message", "tool_result", "tool_input" ] } }, "enabled": { "type": "boolean" } }, "required": [ "id", "name", "kind", "action", "objects", "enabled" ], "additionalProperties": false }, "AuditFilter": { "type": "object", "properties": { "category": { "enum": [ "login", "management", "request" ] }, "from": { "type": "string", "format": "date-time" }, "to": { "type": "string", "format": "date-time" }, "project_id": { "type": "string", "pattern": "^[1-9][0-9]*$" }, "request_id": { "type": "string" }, "model": { "type": "string" }, "actor_user_id": { "type": "integer", "minimum": 1 }, "token_id": { "type": "integer", "minimum": 1 }, "outcome": { "type": "string" }, "http_status": { "type": "integer", "minimum": 100, "maximum": 599 } }, "required": [], "additionalProperties": false }, "PrivacyPolicy": { "type": "object", "properties": { "revision": { "type": "integer", "minimum": 0 }, "retention": { "$ref": "#/components/schemas/Retention" }, "rules": { "type": "array", "maxItems": 64, "items": { "$ref": "#/components/schemas/PrivacyRule" } }, "access": { "$ref": "#/components/schemas/AccessPolicy" } }, "required": [ "revision", "retention", "rules", "access" ], "additionalProperties": false }, "UpdateAccess": { "type": "object", "properties": { "revision": { "type": "integer", "minimum": 0 }, "access": { "$ref": "#/components/schemas/AccessPolicy" } }, "required": [ "revision", "access" ], "additionalProperties": false }, "CreateExport": { "type": "object", "properties": { "filter": { "$ref": "#/components/schemas/AuditFilter" }, "include_content": { "type": "boolean", "default": false } }, "required": [], "additionalProperties": false }, "KeyBudget": { "type": "object", "properties": { "amount": { "type": "string", "description": "Non-negative budget in KRW, as a decimal string." } }, "required": [ "amount" ], "additionalProperties": false }, "Budget": { "type": "object", "properties": { "kind": { "enum": [ "organization", "project", "member", "key" ] }, "subject_id": { "type": "string", "pattern": "^[1-9][0-9]*$", "description": "Organization, project, membership or model Key ID for the selected kind." }, "amount": { "type": "string", "description": "Non-negative budget in KRW, as a decimal string." } }, "required": [ "kind", "subject_id", "amount" ], "additionalProperties": false } } }, "paths": { "/api/korea/models": { "get": { "operationId": "models.list", "summary": "Available models, KRW prices and execution capabilities", "security": [ { "deviceSession": [] } ], "parameters": [], "responses": { "200": { "description": "Success envelope", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Envelope" } } } }, "401": { "description": "Session expired or revoked" }, "403": { "description": "Scope, role, membership or access policy denied" }, "503": { "description": "Integration unavailable" } } } }, "/api/korea/cli/session": { "get": { "operationId": "whoami", "summary": "Device management session", "security": [ { "deviceSession": [] } ], "parameters": [], "responses": { "200": { "description": "Success envelope", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Envelope" } } } }, "401": { "description": "Session expired or revoked" }, "403": { "description": "Scope, role, membership or access policy denied" }, "503": { "description": "Integration unavailable" } } } }, "/api/korea/cli/devices": { "get": { "operationId": "devices.list", "summary": "List organization devices", "security": [ { "deviceSession": [] } ], "parameters": [], "responses": { "200": { "description": "Success envelope", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Envelope" } } } }, "401": { "description": "Session expired or revoked" }, "403": { "description": "Scope, role, membership or access policy denied" }, "503": { "description": "Integration unavailable" } } } }, "/api/korea/cli/devices/{device_id}": { "delete": { "operationId": "devices.revoke", "summary": "Revoke session and device model Key", "security": [ { "deviceSession": [] } ], "parameters": [ { "name": "device_id", "in": "path", "required": true, "schema": { "type": "string" } } ], "responses": { "200": { "description": "Success envelope", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Envelope" } } } }, "401": { "description": "Session expired or revoked" }, "403": { "description": "Scope, role, membership or access policy denied" }, "503": { "description": "Integration unavailable" } } } }, "/api/korea/organizations": { "post": { "operationId": "org.create", "summary": "Create an organization", "security": [ { "deviceSession": [] } ], "parameters": [], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CreateOrganization" } } } }, "responses": { "200": { "description": "Success envelope", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Envelope" } } } }, "401": { "description": "Session expired or revoked" }, "403": { "description": "Scope, role, membership or access policy denied" }, "503": { "description": "Integration unavailable" } } }, "get": { "operationId": "org.list", "summary": "List organizations", "security": [ { "deviceSession": [] } ], "parameters": [], "responses": { "200": { "description": "Success envelope", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Envelope" } } } }, "401": { "description": "Session expired or revoked" }, "403": { "description": "Scope, role, membership or access policy denied" }, "503": { "description": "Integration unavailable" } } } }, "/api/korea/organizations/{organization_id}/scope": { "get": { "operationId": "org.get", "summary": "Organization details", "security": [ { "deviceSession": [] } ], "parameters": [ { "name": "organization_id", "in": "path", "required": true, "schema": { "type": "string" } } ], "responses": { "200": { "description": "Success envelope", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Envelope" } } } }, "401": { "description": "Session expired or revoked" }, "403": { "description": "Scope, role, membership or access policy denied" }, "503": { "description": "Integration unavailable" } } } }, "/api/korea/organizations/{organization_id}/members/{member_id}": { "patch": { "operationId": "org.member-update", "summary": "Update role, department or active membership", "security": [ { "deviceSession": [] } ], "parameters": [ { "name": "organization_id", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "member_id", "in": "path", "required": true, "schema": { "type": "string" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UpdateMember" } } } }, "responses": { "200": { "description": "Success envelope", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Envelope" } } } }, "401": { "description": "Session expired or revoked" }, "403": { "description": "Scope, role, membership or access policy denied" }, "503": { "description": "Integration unavailable" } } } }, "/api/korea/organizations/{organization_id}/projects/{project_id}/members/{member_id}": { "put": { "operationId": "org.project-grant", "summary": "Grant project membership", "security": [ { "deviceSession": [] } ], "parameters": [ { "name": "organization_id", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "project_id", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "member_id", "in": "path", "required": true, "schema": { "type": "string" } } ], "responses": { "200": { "description": "Success envelope", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Envelope" } } } }, "401": { "description": "Session expired or revoked" }, "403": { "description": "Scope, role, membership or access policy denied" }, "503": { "description": "Integration unavailable" } } }, "delete": { "operationId": "org.project-revoke", "summary": "Revoke project membership", "security": [ { "deviceSession": [] } ], "parameters": [ { "name": "organization_id", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "project_id", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "member_id", "in": "path", "required": true, "schema": { "type": "string" } } ], "responses": { "200": { "description": "Success envelope", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Envelope" } } } }, "401": { "description": "Session expired or revoked" }, "403": { "description": "Scope, role, membership or access policy denied" }, "503": { "description": "Integration unavailable" } } } }, "/api/korea/organizations/{organization_id}/members": { "get": { "operationId": "org.members", "summary": "Organization members", "security": [ { "deviceSession": [] } ], "parameters": [ { "name": "organization_id", "in": "path", "required": true, "schema": { "type": "string" } } ], "responses": { "200": { "description": "Success envelope", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Envelope" } } } }, "401": { "description": "Session expired or revoked" }, "403": { "description": "Scope, role, membership or access policy denied" }, "503": { "description": "Integration unavailable" } } } }, "/api/korea/organizations/{organization_id}/projects": { "get": { "operationId": "org.projects", "summary": "Organization projects", "security": [ { "deviceSession": [] } ], "parameters": [ { "name": "organization_id", "in": "path", "required": true, "schema": { "type": "string" } }, { "in": "query", "name": "include_archived", "schema": { "type": "boolean", "default": false } } ], "responses": { "200": { "description": "Success envelope", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Envelope" } } } }, "401": { "description": "Session expired or revoked" }, "403": { "description": "Scope, role, membership or access policy denied" }, "503": { "description": "Integration unavailable" } } }, "post": { "operationId": "org.project-create", "summary": "Create a project", "security": [ { "deviceSession": [] } ], "parameters": [ { "name": "organization_id", "in": "path", "required": true, "schema": { "type": "string" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CreateProject" } } } }, "responses": { "200": { "description": "Success envelope", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Envelope" } } } }, "401": { "description": "Session expired or revoked" }, "403": { "description": "Scope, role, membership or access policy denied" }, "503": { "description": "Integration unavailable" } } } }, "/api/korea/organizations/{organization_id}/invitations": { "post": { "operationId": "org.invite", "summary": "Invite a member", "security": [ { "deviceSession": [] } ], "parameters": [ { "name": "organization_id", "in": "path", "required": true, "schema": { "type": "string" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/InviteMember" } } } }, "responses": { "200": { "description": "Success envelope", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Envelope" } } } }, "401": { "description": "Session expired or revoked" }, "403": { "description": "Scope, role, membership or access policy denied" }, "503": { "description": "Integration unavailable" } } } }, "/api/korea/organizations/{organization_id}/projects/{project_id}/scope": { "get": { "operationId": "org.project-scope", "summary": "Read the device-bound project scope", "security": [ { "deviceSession": [] } ], "parameters": [ { "name": "organization_id", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "project_id", "in": "path", "required": true, "schema": { "type": "string" } } ], "responses": { "200": { "description": "Success envelope", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Envelope" } } } }, "401": { "description": "Session expired or revoked" }, "403": { "description": "Scope, role, membership or access policy denied" }, "503": { "description": "Integration unavailable" } } } }, "/api/korea/organizations/{organization_id}/projects/{project_id}": { "patch": { "operationId": "org.project-rename", "summary": "Rename the device-bound project", "security": [ { "deviceSession": [] } ], "parameters": [ { "name": "organization_id", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "project_id", "in": "path", "required": true, "schema": { "type": "string" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/RenameProject" } } } }, "responses": { "200": { "description": "Success envelope", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Envelope" } } } }, "401": { "description": "Session expired or revoked" }, "403": { "description": "Scope, role, membership or access policy denied" }, "503": { "description": "Integration unavailable" } } } }, "/api/korea/organizations/{organization_id}/projects/{project_id}/archive": { "post": { "operationId": "org.project-archive", "summary": "Archive the device-bound project; retain historical usage", "security": [ { "deviceSession": [] } ], "parameters": [ { "name": "organization_id", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "project_id", "in": "path", "required": true, "schema": { "type": "string" } } ], "responses": { "200": { "description": "Success envelope", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Envelope" } } } }, "401": { "description": "Session expired or revoked" }, "403": { "description": "Scope, role, membership or access policy denied" }, "503": { "description": "Integration unavailable" } } } }, "/api/korea/organizations/{organization_id}/projects/{project_id}/keys": { "get": { "operationId": "keys.list", "summary": "List masked Keys", "security": [ { "deviceSession": [] } ], "parameters": [ { "name": "organization_id", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "project_id", "in": "path", "required": true, "schema": { "type": "string" } } ], "responses": { "200": { "description": "Success envelope", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Envelope" } } } }, "401": { "description": "Session expired or revoked" }, "403": { "description": "Scope, role, membership or access policy denied" }, "503": { "description": "Integration unavailable" } } }, "post": { "operationId": "keys.create", "summary": "Create a scoped model Key", "security": [ { "deviceSession": [] } ], "parameters": [ { "name": "organization_id", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "project_id", "in": "path", "required": true, "schema": { "type": "string" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CreateKey" } } } }, "responses": { "200": { "description": "Success envelope", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Envelope" } } } }, "401": { "description": "Session expired or revoked" }, "403": { "description": "Scope, role, membership or access policy denied" }, "503": { "description": "Integration unavailable" } } } }, "/api/korea/organizations/{organization_id}/projects/{project_id}/keys/{key_id}": { "delete": { "operationId": "keys.revoke", "summary": "Revoke a model Key", "security": [ { "deviceSession": [] } ], "parameters": [ { "name": "organization_id", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "project_id", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "key_id", "in": "path", "required": true, "schema": { "type": "string" } } ], "responses": { "200": { "description": "Success envelope", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Envelope" } } } }, "401": { "description": "Session expired or revoked" }, "403": { "description": "Scope, role, membership or access policy denied" }, "503": { "description": "Integration unavailable" } } } }, "/api/korea/organizations/{organization_id}/projects/{project_id}/keys/{key_id}/owner": { "patch": { "operationId": "keys.transfer", "summary": "Transfer a service Key owner", "security": [ { "deviceSession": [] } ], "parameters": [ { "name": "organization_id", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "project_id", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "key_id", "in": "path", "required": true, "schema": { "type": "string" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/TransferKey" } } } }, "responses": { "200": { "description": "Success envelope", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Envelope" } } } }, "401": { "description": "Session expired or revoked" }, "403": { "description": "Scope, role, membership or access policy denied" }, "503": { "description": "Integration unavailable" } } } }, "/api/korea/organizations/{organization_id}/projects/{project_id}/keys/{key_id}/budget": { "put": { "operationId": "keys.budget", "summary": "Update Key budget", "security": [ { "deviceSession": [] } ], "parameters": [ { "name": "organization_id", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "project_id", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "key_id", "in": "path", "required": true, "schema": { "type": "string" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/KeyBudget" } } } }, "responses": { "200": { "description": "Success envelope", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Envelope" } } } }, "401": { "description": "Session expired or revoked" }, "403": { "description": "Scope, role, membership or access policy denied" }, "503": { "description": "Integration unavailable" } } } }, "/api/korea/organizations/{organization_id}/usage": { "get": { "operationId": "usage.get", "summary": "Usage with KRW/KST attribution", "security": [ { "deviceSession": [] } ], "parameters": [ { "name": "organization_id", "in": "path", "required": true, "schema": { "type": "string" } }, { "in": "query", "name": "month", "schema": { "type": "string", "pattern": "^[0-9]{4}-[0-9]{2}$", "description": "Billing month in Asia/Seoul; defaults to the current month." } }, { "in": "query", "name": "project_id", "schema": { "type": "string", "pattern": "^[1-9][0-9]*$" }, "description": "Optional project scope within the organization; device sessions use their bound project." } ], "responses": { "200": { "description": "Success envelope", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Envelope" } } } }, "401": { "description": "Session expired or revoked" }, "403": { "description": "Scope, role, membership or access policy denied" }, "503": { "description": "Integration unavailable" } } } }, "/api/korea/organizations/{organization_id}/usage/report": { "get": { "operationId": "usage.report", "summary": "Daily settled/reserved amounts and request metadata", "security": [ { "deviceSession": [] } ], "parameters": [ { "name": "organization_id", "in": "path", "required": true, "schema": { "type": "string" } }, { "in": "query", "name": "month", "schema": { "type": "string", "pattern": "^[0-9]{4}-[0-9]{2}$", "description": "Billing month in Asia/Seoul; defaults to the current month." } }, { "in": "query", "name": "project_id", "schema": { "type": "string", "pattern": "^[1-9][0-9]*$" }, "description": "Optional project scope within the organization; device sessions use their bound project." } ], "responses": { "200": { "description": "Success envelope", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Envelope" } } } }, "401": { "description": "Session expired or revoked" }, "403": { "description": "Scope, role, membership or access policy denied" }, "503": { "description": "Integration unavailable" } } } }, "/api/korea/organizations/{organization_id}/usage/requests/{request_id}": { "get": { "operationId": "usage.requestCost", "summary": "Original request or video task cost, reservations, refunds and usage; members read their own requests", "security": [ { "deviceSession": [] } ], "parameters": [ { "name": "organization_id", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "request_id", "in": "path", "required": true, "schema": { "type": "string", "maxLength": 64 } }, { "in": "query", "name": "project_id", "schema": { "type": "string" } } ], "responses": { "200": { "description": "Success envelope", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Envelope" } } } }, "401": { "description": "Session expired or revoked" }, "403": { "description": "Scope, role, membership or access policy denied" }, "404": { "description": "Request unavailable in current scope" }, "503": { "description": "Integration unavailable" } } } }, "/api/korea/organizations/{organization_id}/wallet": { "get": { "operationId": "billing.get", "summary": "Shared organization wallet", "security": [ { "deviceSession": [] } ], "parameters": [ { "name": "organization_id", "in": "path", "required": true, "schema": { "type": "string" } } ], "responses": { "200": { "description": "Success envelope", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Envelope" } } } }, "401": { "description": "Session expired or revoked" }, "403": { "description": "Scope, role, membership or access policy denied" }, "503": { "description": "Integration unavailable" } } } }, "/api/korea/organizations/{organization_id}/budgets": { "get": { "operationId": "billing.budgets", "summary": "Budget policy", "security": [ { "deviceSession": [] } ], "parameters": [ { "name": "organization_id", "in": "path", "required": true, "schema": { "type": "string" } }, { "in": "query", "name": "month", "schema": { "type": "string", "pattern": "^[0-9]{4}-[0-9]{2}$", "description": "Billing month in Asia/Seoul; defaults to the current month." } } ], "responses": { "200": { "description": "Success envelope", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Envelope" } } } }, "401": { "description": "Session expired or revoked" }, "403": { "description": "Scope, role, membership or access policy denied" }, "503": { "description": "Integration unavailable" } } }, "put": { "operationId": "billing.budget-set", "summary": "Update budget policy", "security": [ { "deviceSession": [] } ], "parameters": [ { "name": "organization_id", "in": "path", "required": true, "schema": { "type": "string" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Budget" } } } }, "responses": { "200": { "description": "Success envelope", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Envelope" } } } }, "401": { "description": "Session expired or revoked" }, "403": { "description": "Scope, role, membership or access policy denied" }, "503": { "description": "Integration unavailable" } } } }, "/api/organizations/{organization_id}/access-policy": { "get": { "operationId": "security.get", "summary": "MFA and IP policy", "security": [ { "deviceSession": [] } ], "parameters": [ { "name": "organization_id", "in": "path", "required": true, "schema": { "type": "string" } } ], "responses": { "200": { "description": "Success envelope", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Envelope" } } } }, "401": { "description": "Session expired or revoked" }, "403": { "description": "Scope, role, membership or access policy denied" }, "503": { "description": "Integration unavailable" } } }, "put": { "operationId": "security.set", "summary": "Update access policy", "security": [ { "deviceSession": [] } ], "parameters": [ { "name": "organization_id", "in": "path", "required": true, "schema": { "type": "string" } } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/UpdateAccess" } } } }, "responses": { "200": { "description": "Success envelope", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Envelope" } } } }, "401": { "description": "Session expired or revoked" }, "403": { "description": "Scope, role, membership or access policy denied" }, "503": { "description": "Integration unavailable" } } } }, "/api/organizations/{organization_id}/privacy-policy": { "get": { "operationId": "security.privacy", "summary": "Effective privacy policy", "security": [ { "deviceSession": [] } ], "parameters": [ { "name": "organization_id", "in": "path", "required": true, "schema": { "type": "string" } }, { "in": "query", "name": "project_id", "schema": { "type": "string", "pattern": "^[1-9][0-9]*$" }, "description": "Optional project scope within the organization; device sessions use their bound project." } ], "responses": { "200": { "description": "Success envelope", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Envelope" } } } }, "401": { "description": "Session expired or revoked" }, "403": { "description": "Scope, role, membership or access policy denied" }, "503": { "description": "Integration unavailable" } } }, "put": { "operationId": "security.privacy-set", "summary": "Update privacy policy", "security": [ { "deviceSession": [] } ], "parameters": [ { "name": "organization_id", "in": "path", "required": true, "schema": { "type": "string" } }, { "in": "query", "name": "project_id", "schema": { "type": "string", "pattern": "^[1-9][0-9]*$" }, "description": "Optional project scope within the organization; device sessions use their bound project." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/PrivacyPolicy" } } } }, "responses": { "200": { "description": "Success envelope", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Envelope" } } } }, "401": { "description": "Session expired or revoked" }, "403": { "description": "Scope, role, membership or access policy denied" }, "503": { "description": "Integration unavailable" } } } }, "/api/organizations/{organization_id}/audit-logs": { "get": { "operationId": "audit.list", "summary": "Audit metadata", "security": [ { "deviceSession": [] } ], "parameters": [ { "name": "organization_id", "in": "path", "required": true, "schema": { "type": "string" } }, { "in": "query", "name": "filter", "schema": { "type": "string", "description": "JSON-encoded AuditFilter" } }, { "in": "query", "name": "limit", "schema": { "type": "integer", "minimum": 1, "maximum": 200, "default": 100 } }, { "in": "query", "name": "before", "schema": { "type": "string", "pattern": "^[0-9]+$" } }, { "in": "query", "name": "project_id", "schema": { "type": "string", "pattern": "^[1-9][0-9]*$" }, "description": "Optional project scope within the organization; device sessions use their bound project." } ], "responses": { "200": { "description": "Success envelope", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Envelope" } } } }, "401": { "description": "Session expired or revoked" }, "403": { "description": "Scope, role, membership or access policy denied" }, "503": { "description": "Integration unavailable" } } } }, "/api/organizations/{organization_id}/exports": { "post": { "operationId": "audit.export", "summary": "Create a 24-hour audit export", "security": [ { "deviceSession": [] } ], "parameters": [ { "name": "organization_id", "in": "path", "required": true, "schema": { "type": "string" } }, { "in": "query", "name": "project_id", "schema": { "type": "string", "pattern": "^[1-9][0-9]*$" }, "description": "Optional project scope within the organization; device sessions use their bound project." } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/CreateExport" } } } }, "responses": { "200": { "description": "Success envelope", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Envelope" } } } }, "401": { "description": "Session expired or revoked" }, "403": { "description": "Scope, role, membership or access policy denied" }, "503": { "description": "Integration unavailable" } } } }, "/api/organizations/{organization_id}/exports/{export_id}": { "delete": { "operationId": "audit.export-revoke", "summary": "Revoke an audit export", "security": [ { "deviceSession": [] } ], "parameters": [ { "name": "organization_id", "in": "path", "required": true, "schema": { "type": "string" } }, { "name": "export_id", "in": "path", "required": true, "schema": { "type": "string" } } ], "responses": { "200": { "description": "Success envelope", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Envelope" } } } }, "401": { "description": "Session expired or revoked" }, "403": { "description": "Scope, role, membership or access policy denied" }, "503": { "description": "Integration unavailable" } } } }, "/api/korea/cli/device/authorize": { "post": { "operationId": "device.authorize", "summary": "Device authorization", "security": [], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/DeviceAuthorize" } } } }, "responses": { "200": { "description": "Success envelope", "content": { "application/json": { "schema": { "allOf": [ { "$ref": "#/components/schemas/Envelope" }, { "properties": { "data": { "$ref": "#/components/schemas/DeviceAuthorization" } } } ] } } } }, "400": { "description": "Invalid/expired device code or device polling state" }, "403": { "description": "Browser scope/access denied" }, "429": { "description": "Attempt limiter" }, "503": { "description": "Service temporarily unavailable" } } } }, "/api/korea/cli/device/token": { "post": { "operationId": "device.token", "summary": "Exchange once; authorization_pending / slow_down (+5s) / access_denied / expired_token", "security": [], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/DevicePoll" } } } }, "responses": { "200": { "description": "Success envelope", "content": { "application/json": { "schema": { "allOf": [ { "$ref": "#/components/schemas/Envelope" }, { "properties": { "data": { "$ref": "#/components/schemas/DeviceTokens" } } } ] } } } }, "400": { "description": "Invalid/expired device code or device polling state" }, "403": { "description": "Browser scope/access denied" }, "429": { "description": "Attempt limiter" }, "503": { "description": "Service temporarily unavailable" } } } }, "/api/korea/cli/device/decision": { "post": { "operationId": "device.decision", "summary": "Device authorization", "security": [ { "browserSession": [] } ], "requestBody": { "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/DeviceDecision" } } } }, "responses": { "200": { "description": "Success envelope", "content": { "application/json": { "schema": { "allOf": [ { "$ref": "#/components/schemas/Envelope" }, { "properties": { "data": {} } } ] } } } }, "400": { "description": "Invalid/expired device code or device polling state" }, "403": { "description": "Browser scope/access denied" }, "429": { "description": "Attempt limiter" }, "503": { "description": "Service temporarily unavailable" } } } }, "/api/korea/cli/device": { "get": { "operationId": "device.inspect", "security": [ { "browserSession": [] } ], "parameters": [ { "in": "query", "name": "user_code", "required": true, "schema": { "type": "string" } } ], "responses": { "200": { "description": "Device name, requested scopes and expiry for human review" }, "400": { "description": "Invalid or expired code" }, "401": { "description": "Browser login required" } } } } } }