← All procedures

s3.multipart.complete

Complete multipart upload by assembling parts

CLI
Package
@procedures/s3 · README
Path
["s3","multipart","complete"]
CLI
mark s3 multipart complete --bucket <string> --key <string> --uploadId <string> --parts <object[]>
As data
{"$proc":["s3","multipart","complete"],"input":{}}

Use it

In TypeScript

import { Client, LocalTransport, PROCEDURE_REGISTRY } from "@procedures/client";
import "@procedures/s3"; // registers its procedures

const client = new Client(new LocalTransport({ registry: PROCEDURE_REGISTRY }));
const result = await client.exec(["s3","multipart","complete"], { bucket: "<bucket>", key: "<key>", uploadId: "<uploadId>", parts: [] });
console.log(JSON.stringify(result));

From the command line

$ mark s3 multipart complete --bucket <string> --key <string> --uploadId <string> --parts <object[]>

As data, in a program

{
  "$proc": ["s3", "multipart", "complete"],
  "input": {
    "bucket": "<bucket>",
    "key": "<key>",
    "uploadId": "<uploadId>",
    "parts": []
  }
}

Input

FieldTypeRequiredDefaultDescription
bucketstringyesS3 bucket name
keystringyesObject key
uploadIdstringyesUpload ID from init
partsobject[]yesParts to complete (etag and partNumber)

Output

FieldTypeRequiredDefaultDescription
locationstringyesThe location of the object
bucketstringyesThe bucket
keystringyesThe object key
etagstringyesThe ETag of the object, without quotes
JSON Schemas
{
  "input": {
    "type": "object",
    "properties": {
      "bucket": {
        "type": "string",
        "description": "S3 bucket name"
      },
      "key": {
        "type": "string",
        "description": "Object key"
      },
      "uploadId": {
        "type": "string",
        "description": "Upload ID from init"
      },
      "parts": {
        "type": "array",
        "items": {
          "type": "object",
          "properties": {
            "etag": {
              "type": "string"
            },
            "partNumber": {
              "type": "number"
            }
          },
          "required": [
            "etag",
            "partNumber"
          ]
        },
        "description": "Parts to complete (etag and partNumber)"
      }
    },
    "required": [
      "bucket",
      "key",
      "uploadId",
      "parts"
    ]
  },
  "output": {
    "type": "object",
    "properties": {
      "location": {
        "type": "string",
        "description": "The location of the object"
      },
      "bucket": {
        "type": "string",
        "description": "The bucket"
      },
      "key": {
        "type": "string",
        "description": "The object key"
      },
      "etag": {
        "type": "string",
        "description": "The ETag of the object, without quotes"
      }
    },
    "required": [
      "location",
      "bucket",
      "key",
      "etag"
    ],
    "additionalProperties": {}
  }
}