列出工作区项目
OpenAPI 契约
- 方法
- GET
- 路径
/api/v1/workspaces/{id}/projects- 认证
- jwtBearer (bearer)
- 响应状态
- 200 400 401 403 404 409 429 500
请求与响应 Schema
JSON
{
"requestBody": {},
"responses": {
"200": {
"description": "Workspace project page",
"content": {
"application/json": {}
}
},
"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 workspace resource was not found",
"content": {
"application/json": {
"$ref": "#/components/schemas/ApiError"
}
}
},
"409": {
"description": "Request conflicts with current workspace state",
"content": {
"application/json": {
"$ref": "#/components/schemas/ApiError"
}
}
},
"429": {
"description": "Rate limit exceeded",
"content": {
"application/json": {
"$ref": "#/components/schemas/SecurityError"
}
}
},
"500": {
"description": "Unexpected server error",
"content": {
"application/json": {
"$ref": "#/components/schemas/ApiError"
}
}
}
}
}GET /api/v1/workspaces/{id}/projects 仅限 JWT,并且需要 workspace:read。它返回 Spring 分页,默认按最新项目排序。具有项目管理能力的调用方可看到工作区中的所有项目;其他调用方只能看到工作区可见项目或直接授予给自己的受限项目。仅具有计费角色的工作区成员会得到空页,除非其他角色授予项目管理能力。
使用常规 page、size 和 sort 查询参数;默认值分别为页 0、大小 20 和 createdAt,desc。不会披露超出调用方协作边界的项目。