Amazon S3

To allow our servers to download files directly from the Amazon S3 storage, the following permissions are required:

  • s3:GetObject
    • Used to download a file
  • s3:PutObject
    • Used to store a file
  • s3:PutObjectAcl
    • Used to grant different Access Control List (ACL) values when storing a file

Below you can find a list with the fields that are accepted in this input type:

Field Description Required Default
input.type Specifies the type of input. For cloud storage always use cloud. Yes N/A
input.source Tells our servers which cloud storage provider must be contacted, in this case amazons3. Yes N/A
input.parameters.bucket Determines from which bucket our servers will get the file. Yes N/A
input.parameters.region Indicates the region configured for your bucket. A list of Amazon S3 region names can be found here. If you don't specify this field and your bucket is configured to use another region than the default, any download will fail. No eu-central-1
input.parameters.file Amazon S3 key of the file to download. Usually looks like a normal file path, e.g. pictures/mountains.jpg. Yes N/A
input.credentials.accesskeyid The Amazon S3 access key ID. Yes N/A
input.credentials.secretaccesskey The Amazon S3 secret access key. Yes N/A
input.credentials.sessiontoken Together with secretaccesskey and accesskeyid, this is used to authenticate using temporary credentials. For more information on how to generate temporary credentials please check how to install AWS CLI tool and how to do a call to AWS STS get-session-token. No N/A
POST /jobs HTTP/1.1
Host: api2.online-convert.com
x-oc-api-key: <your API key here>
Content-Type: application/json
Cache-Control: no-cache

{
    "conversion": [
        {
            "target": "png"
        }
    ],
    "input": [{
        "type": "cloud",
        "source": "amazons3",
        "parameters": {
            "bucket": "your bucket name",
            "file": "path to the file you want us to download"
        },
        "credentials": {
            "accesskeyid": "your accesskey id",
            "secretaccesskey": "your secret access key"
        }
    }]
}
curl -X POST \
  https://api2.online-convert.com/jobs \
  -H 'cache-control: no-cache' \
  -H 'content-type: application/json' \
  -H 'x-oc-api-key: <your API key here>' \
  -d '{
    "conversion": [
        {
            "target": "png"
        }
    ],
    "input": [{
        "type": "cloud",
        "source": "amazons3",
        "parameters": {
            "bucket": "your bucket name",
            "file": "path to the file you want us to download"
        },
        "credentials": {
            "accesskeyid": "your accesskey id",
            "secretaccesskey": "your secret access key"
        }
    }]
}'

results matching ""

    No results matching ""