Skip to content

멀티파트 업로드 시작 Tier 3

POST/api/projects/:id/files/upload.multipartCopied!

파일을 생성하고 멀티파트 업로드용 Presigned URL을 반환합니다. 파트는 100 MB 단위로 생성되며, 최대 파일 크기는 10 GB입니다.

CLI 관리형 업로드

SDK의 files.upload 헬퍼와 CLI의 youvico file upload.file 명령은 모두 전체 멀티파트 흐름을 실행하므로, 아래 CLI 예시는 이 엔드포인트를 단독으로 호출하지 않습니다.

예시

ts
const upload = await client.files.startMultipartUpload("bdbff5de-96d7-468f-9db0-85fe28bd6b62", {
  name: "launch-cut.mp4",
  size: 250000000,
});
bash
youvico file upload.file \
  --project bdbff5de-96d7-468f-9db0-85fe28bd6b62 \
  --path ./launch-cut.mp4 \
  --name launch-cut.mp4
bash
curl -X POST 'https://api.youvico.com/api/projects/bdbff5de-96d7-468f-9db0-85fe28bd6b62/files/upload.multipart' \
  -H 'Authorization: Bearer YOUR_API_KEY' \
  -H 'Content-Type: application/json' \
  -d '{ "name": "launch-cut.mp4", "size": 250000000 }'
json
{
  "data": {
    "id": "FX1234567890ABCD",
    "parts": [
      {
        "partNumber": 1,
        "url": "https://example.com/upload/1"
      },
      {
        "partNumber": 2,
        "url": "https://example.com/upload/2"
      },
      {
        "partNumber": 3,
        "url": "https://example.com/upload/3"
      }
    ]
  }
}

요청

경로

idstringrequired
프로젝트 ID

본문

namestringrequired

1-255 characters

파일 이름
sizenumberrequired

1-10000000000

파일 크기(바이트)

응답

201 Created를 반환합니다.

dataobject
업로드 세션
data.idstring
생성된 파일 ID

Example: FX1234567890ABCD

data.partsarray
업로드 파트
data.parts[].partNumbernumber
파트 번호

Example: 1

data.parts[].urlstring
파트 업로드용 Presigned URL

Example: https://example.com/upload/1