获取项目
OpenAPI 契约
- 方法
- GET
- 路径
/api/v1/projects/{id}- 认证
- jwtBearer (bearer) OR automationKey (bearer)
- 响应状态
- 200 400 401 403 404 409 429 500
请求与响应 Schema
JSON
{
"requestBody": {},
"responses": {
"200": {
"description": "Project",
"content": {
"application/json": {
"$ref": "#/components/schemas/ProjectResponse"
}
}
},
"400": {
"description": "Invalid request",
"content": {
"application/json": {
"$ref": "#/components/schemas/RequestError"
}
}
},
"401": {
"description": "Authentication required or invalid",
"content": {
"application/json": {
"$ref": "#/components/schemas/SecurityError"
}
}
},
"403": {
"description": "Authenticated but not permitted",
"content": {
"application/json": {
"$ref": "#/components/schemas/SecurityError"
}
}
},
"404": {
"description": "Requested project or build was not found",
"content": {
"application/json": {
"$ref": "#/components/schemas/ApiError"
}
}
},
"409": {
"description": "Request conflicts with current project state",
"content": {
"application/json": {
"$ref": "#/components/schemas/ApiError"
}
}
},
"429": {
"description": "HTTP rate limit or API-key NCU usage limit exceeded",
"content": {
"application/json": {
"$ref": "#/components/schemas/RateLimitError"
}
}
},
"500": {
"description": "Unexpected server error",
"content": {
"application/json": {
"$ref": "#/components/schemas/ApiError"
}
}
}
}
}GET /api/v1/projects/{id} 接受 JWT 或带 project:read 的 nfy_ 密钥。调用方还必须通过 workspace membership 或直接 project grant 获得 collaboration capability project:read。响应包含 workspace 与 organization ID、access mode、有效 project role 与 capability、已保存默认值和构建摘要字段。调用方可见边界之外的项目按未找到处理。
http
GET /api/v1/projects/{id}
Authorization: Bearer <access token>