同じ組織内の別のワークスペースからこのワークスペースに既存の成功したビルドのイメージをコピーし、配置可能なビルドを作成します。ソース ビルドのプロジェクトと ターゲットプロジェクト の両方に対する配置管理が必要です。強制するには、ターゲットのプロジェクト所有者ロールが追加で必要です。処理は非同期です。準備が完了するまで、返された昇格をポーリングします。
POST /api/v1 /projects/{id}/workspaces/{workspace_id}/pro moves
curl \
--request POST 'https://agentengine.mongodb.com/api/v1/projects/{id}/workspaces/{workspace_id}/promotions' \
--header "Authorization: $API_KEY" \
--header "Content-Type: application/json" \
--data '{
"confirmed": true,
"force": true,
"source_build_id": "string"
}'
リクエスト例
{
"confirmed": true,
"force": true,
"source_build_id": "string"
}
応答の例(406)
操作は利用できません
{
"detail": "This operation is not available in API version 2026-09-20-preview.",
"error": 406,
"errorCode": "OPERATION_NOT_IN_API_VERSION",
"parameters": [
"Accept"
],
"reason": "Not Acceptable"
}
{
"detail": "This operation supports text/event-stream, which the Accept header excludes. Remove unsupported media-type parameters or accept this type with a positive q value.",
"error": 406,
"errorCode": "UNACCEPTABLE_MEDIA_TYPE",
"parameters": [
"Accept"
],
"reason": "Not Acceptable"
}
{
"detail": "The requested API version is not supported. Supported versions: 2026-09-20-preview.",
"error": 406,
"errorCode": "UNSUPPORTED_API_VERSION",
"parameters": [
"Accept"
],
"reason": "Not Acceptable"
}
応答の例(406)
{
"detail": "This operation is not available in API version 2026-09-20-preview.",
"error": 406,
"errorCode": "OPERATION_NOT_IN_API_VERSION",
"parameters": [
"Accept"
],
"reason": "Not Acceptable"
}
応答の例(202)
{
"created_at": "string",
"failure_reason": "string",
"finished_at": "string",
"force": true,
"initiated_by": "string",
"org_id": "string",
"promotion_id": "string",
"source_build_id": "string",
"status": "pending",
"target_build_id": "string",
"target_project_id": "string",
"target_workspace_id": "string"
}
応答の例(202)
{
"created_at": "string",
"failure_reason": "string",
"finished_at": "string",
"force": true,
"initiated_by": "string",
"org_id": "string",
"promotion_id": "string",
"source_build_id": "string",
"status": "pending",
"target_build_id": "string",
"target_project_id": "string",
"target_workspace_id": "string"
}
応答の例(400)
{
"code": "string",
"error": "string",
"success": true
}
応答の例(400)
{
"code": "string",
"error": "string",
"success": true
}
応答の例(403)
{
"code": "string",
"error": "string",
"success": true
}
応答の例(403)
{
"code": "string",
"error": "string",
"success": true
}
応答の例(404)
{
"code": "string",
"error": "string",
"success": true
}
応答の例(404)
{
"code": "string",
"error": "string",
"success": true
}
応答の例(409)
{
"code": "string",
"error": "string",
"success": true
}
応答の例(409)
{
"code": "string",
"error": "string",
"success": true
}
応答の例(413)
{
"code": "string",
"error": "string",
"success": true
}
応答の例(413)
{
"code": "string",
"error": "string",
"success": true
}
応答の例(429)
# Headers
Retry-After: string
# Payload
{
"code": "string",
"error": "string",
"success": true
}
応答の例(429)
# Headers
Retry-After: string
# Payload
{
"code": "string",
"error": "string",
"success": true
}
応答の例(500)
{
"code": "string",
"error": "string",
"success": true
}
応答の例(500)
{
"code": "string",
"error": "string",
"success": true
}
応答の例(502)
{
"code": "string",
"error": "string",
"success": true
}
応答の例(502)
{
"code": "string",
"error": "string",
"success": true
}
応答の例(503)
# Headers
Retry-After: string
# Payload
{
"code": "string",
"error": "string",
"success": true
}
応答の例(503)
# Headers
Retry-After: string
# Payload
{
"code": "string",
"error": "string",
"success": true
}