콘텐츠로 이동

cloneWorkspaceStorage

POST
/api/v1/storages/{storage_id}/clones
curl --request POST \
--url https://dev.api.endueos.com/api/v1/storages/wst_01J9ZK3Q8M4XW7D2N5R6T0V1BC/clones \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{ "source_revision": 1, "name": "example", "size_gb": 1 }'

Fixes source_revision once. Creates independent data at revision 1, unbound, with fresh policy.

storage_id
필수
string
/^wst_[0-9A-HJKMNP-TV-Z]{26}$/
예시
wst_01J9ZK3Q8M4XW7D2N5R6T0V1BC
X-Idempotency-Key
string
/^[A-Za-z0-9._:-]{1,200}$/
Media typeapplication/json
object
source_revision
integer format: int64
<= 9007199254740991
name
필수
string
>= 1 characters <= 100 characters
size_gb
필수
integer format: int32
>= 1 <= 100
예시자동 생성
{
"source_revision": 1,
"name": "example",
"size_gb": 1
}

받았지만 아직 끝나지 않았다. Location 으로 상태를 묻는다. Retry-After 는 다음 조회까지 기다릴 초.

Media typeapplication/json
object
data
필수
object
operation_id
필수
string
/^wso_[0-9A-HJKMNP-TV-Z]{26}$/
operation_storage_id
필수
string
/^wst_[0-9A-HJKMNP-TV-Z]{26}$/
kind
필수
string
허용 값: clone restore transfer cleanup delete attach detach checkpoint copy move
status
필수
string
허용 값: queued running waiting succeeded failed cancelled
phase
필수
string
status_url
필수
string
bytes_done
필수
integer format: int64
<= 9007199254740991
bytes_total
필수
integer format: int64
<= 9007199254740991
entries_done
필수
integer format: int64
<= 9007199254740991
entries_total
필수
integer format: int64
<= 9007199254740991
cancel_requested
필수
boolean
result
필수
Any of:
object
error
필수
Any of:
object
code
필수

오류 코드. 예: RESOURCE_NOT_FOUND

string
message
필수
string
details
필수
object
suggest
필수
Any of:
string
source_storage_id
필수
Any of:
string
/^wst_[0-9A-HJKMNP-TV-Z]{26}$/
source_revision
필수
Any of:
integer format: int64
<= 9007199254740991
clone_cut_at
필수
Any of:
string format: date-time
source_committed_at
필수
Any of:
string format: date-time
transfer

Kind 가 copy·move 일 때만 있다 (ENDUE-1162)

object
source
필수
object
storage_id
필수
string
/^wst_[0-9A-HJKMNP-TV-Z]{26}$/
path
필수
string
revision
필수
Any of:
integer format: int64
<= 9007199254740991
committed_at
필수
Any of:
string format: date-time
saved_now
필수
boolean
destination
필수
object
storage_id
필수
string
/^wst_[0-9A-HJKMNP-TV-Z]{26}$/
path
필수
string
>= 1 characters <= 4096 characters
revision
필수
Any of:
integer format: int64
<= 9007199254740991
deadline_at
필수
string format: date-time
destination_committed
필수

이동의 원본 제거 단계에서 기한이 지나면 destination_committed=true · source_removed=false 로 끝난다(양쪽에 남는다)

boolean
source_removed
필수
boolean
created_at
필수
string format: date-time
updated_at
필수
string format: date-time
meta
필수
object
request_id
필수
string
timestamp
필수
string format: date-time
duration

서버 처리 시간(ms).

integer format: int32
예시
{
"data": {
"operation_id": "wso_01J9ZK3Q8M4XW7D2N5R6T0V1BC",
"operation_storage_id": "wst_01J9ZK3Q8M4XW7D2N5R6T0V1BC",
"kind": "clone",
"status": "queued",
"source_storage_id": "wst_01J9ZK3Q8M4XW7D2N5R6T0V1BC",
"transfer": {
"source": {
"storage_id": "wst_01J9ZK3Q8M4XW7D2N5R6T0V1BC"
},
"destination": {
"storage_id": "wst_01J9ZK3Q8M4XW7D2N5R6T0V1BC"
}
}
}
}
Location
필수
string
Retry-After
필수
integer format: int32

요청 형식이 틀렸다 — VALIDATION_ERROR(details.errors[]) 또는 BAD_REQUEST. 본문은 오류 봉투.

인증이 없거나 무효다 — UNAUTHORIZED. 본문은 오류 봉투.

크레딧이 없다 — INSUFFICIENT_CREDITS (충전하면 다시 된다). 본문은 오류 봉투.

없거나 내 것이 아니다 — *_NOT_FOUND. 본문은 오류 봉투.

지금 상태와 충돌한다 — 코드는 위 설명을 본다. 본문은 오류 봉투.

보관 기간이 지났다 — OUTPUT_EXPIRED. 본문은 오류 봉투.

한도를 넘었다 — Retry-After 초 뒤에 다시. 본문은 오류 봉투.

서버 오류 — INTERNAL_ERROR. 본문은 오류 봉투.

의존 서비스에 닿지 못했다 — 잠시 뒤 다시. 본문은 오류 봉투.