Skip to content

OpenAPI import example

supdger edited this page Sep 30, 2026 · 1 revision

OpenAPI 导入 JSON 示例

从下方复制完整 JSON,按导入指南替换客户主体、应用、环境、资源和动作。示例值不是实际凭证或已登记记录,预检通过前不要应用。

{
  "organization_code": "sand",
  "application_code": "work",
  "environment_code": "production",
  "document": {
    "openapi": "3.1.0",
    "info": {
      "title": "工作项 API",
      "version": "1.0.0"
    },
    "paths": {
      "/work-items/{id}": {
        "get": {
          "summary": "查看工作项",
          "x-sand-iam": {
            "riskLevel": "low"
          },
          "parameters": [
            {
              "name": "id",
              "in": "path",
              "required": true,
              "schema": {
                "type": "string"
              }
            }
          ],
          "responses": {
            "200": {
              "description": "成功"
            }
          }
        }
      }
    }
  },
  "mappings": [
    {
      "operation_key": "GET /work-items/{id}",
      "api_code": "work-item.read",
      "api_version": "v1",
      "resource_code": "work_item",
      "action": "work_item.read",
      "audience": "work-api",
      "required_scope": "work.read"
    }
  ],
  "disable_missing": false
}

文档首页

Clone this wiki locally