> Markdown versions of all pages of this connector library are available by appending `.md` to the page URL. For the full index of connectors, see [llms.txt](https://connectors.appmixer.com/llms.txt).

# appmixer.aws.s3.PutObject

- Component: `appmixer.aws.s3.PutObject`
- Kind: Action
- Version: 1.0.0
- Visibility: Public
- Connector: [appmixer.aws.s3 2.2.2](https://connectors.appmixer.com/connector/appmixer.aws.s3/2.2.2.md)
- Component page: <https://connectors.appmixer.com/connector/appmixer.aws.s3/2.2.2/component/appmixer.aws.s3.PutObject>

Upload object to bucket.

## Properties

| Field | Type | Description |
| --- | --- | --- |
| Region (`region`) | text | Your AWS instance region. If not select, us-east-1 will be used as default. |

## Input ports

### Port `in`

| Field | Type | Description |
| --- | --- | --- |
| Bucket (`bucket`) | text | Your AWS S3 Bucket |
| Object Key (`key`) | text | They key of the object to save aws. |
| File ID (`fileId`) | text | File ID assigned to file stored in DB. |
| Access Control (`acl`) | select | The canned ACL to apply to the object. Leave empty for buckets with ACLs disabled. |
| Content Type (`contentType`) | text | Standard MIME type describing the format of the contents. |
| Expiry Date (`expiryDate`) | date-time | The expiry date of the S3 file. |
| Maximum Part Size (`maxPartSize`) | number | Maximum amount of stream data that will be buffered in memory prior to flushing in Megabyte. |
| Concurrent Parts (`concurrentParts`) | number | Number of parts that are concurrently uploaded to S3. |

## Output ports

### Port `object`

| Field | Type | Description |
| --- | --- | --- |
| Bucket Name (`Bucket`) | string | - |
| Object Key (`Key`) | string | - |
| `ETag` | string | - |
| Object Location (`Location`) | string | - |
| Content Type (`ContentType`) | string | - |
| Expiry Date (`Expires`) | string | - |

## Full metadata (component.json)

```json
{
  "name": "appmixer.aws.s3.PutObject",
  "author": "Appmixer <info@appmixer.com>",
  "description": "Upload object to bucket.",
  "private": false,
  "auth": {
    "service": "appmixer:aws:s3"
  },
  "inPorts": [
    {
      "name": "in",
      "schema": {
        "type": "object",
        "properties": {
          "bucket": {
            "type": "string"
          },
          "key": {
            "type": "string"
          },
          "fileId": {
            "type": "string"
          },
          "acl": {
            "type": "string"
          },
          "contentType": {
            "type": "string"
          },
          "expiryDate": {
            "type": "string",
            "format": "date-time"
          },
          "maxPartSize": {
            "type": "number"
          },
          "concurrentParts": {
            "type": "number"
          }
        },
        "required": [
          "bucket",
          "key",
          "fileId"
        ]
      },
      "inspector": {
        "inputs": {
          "bucket": {
            "type": "text",
            "label": "Bucket",
            "index": 1,
            "tooltip": "Your AWS S3 Bucket",
            "source": {
              "url": "/component/appmixer/aws/s3/ListBuckets?outPort=bucket",
              "data": {
                "properties": {
                  "sendWholeArray": true
                },
                "transform": "./ListBuckets#bucketsToSelectArray"
              }
            }
          },
          "key": {
            "type": "text",
            "label": "Object Key",
            "index": 2,
            "tooltip": "They key of the object to save aws."
          },
          "fileId": {
            "type": "text",
            "index": 3,
            "label": "File ID",
            "tooltip": "File ID assigned to file stored in DB."
          },
          "acl": {
            "type": "select",
            "label": "Access Control",
            "index": 4,
            "tooltip": "The canned ACL to apply to the object. Leave empty for buckets with ACLs disabled.",
            "options": [
              {
                "clearItem": true,
                "content": "None (use bucket default)"
              },
              {
                "value": "private",
                "content": "private"
              },
              {
                "value": "public-read",
                "content": "public-read"
              },
              {
                "value": "public-read-write",
                "content": "public-read-write"
              },
              {
                "value": "authenticated-read",
                "content": "authenticated-read"
              }
            ]
          },
          "contentType": {
            "type": "text",
            "index": 5,
            "label": "Content Type",
            "tooltip": "Standard MIME type describing the format of the contents."
          },
          "expiryDate": {
            "type": "date-time",
            "index": 6,
            "label": "Expiry Date",
            "tooltip": "The expiry date of the S3 file."
          },
          "maxPartSize": {
            "type": "number",
            "index": 7,
            "label": "Maximum Part Size",
            "tooltip": "Maximum amount of stream data that will be buffered in memory prior to flushing in Megabyte."
          },
          "concurrentParts": {
            "type": "number",
            "index": 8,
            "label": "Concurrent Parts",
            "tooltip": "Number of parts that are concurrently uploaded to S3."
          }
        }
      }
    }
  ],
  "properties": {
    "schema": {
      "properties": {
        "region": {
          "type": "string"
        }
      }
    },
    "inspector": {
      "inputs": {
        "region": {
          "type": "text",
          "label": "Region",
          "index": 1,
          "tooltip": "Your AWS instance region. If not select, us-east-1 will be used as default.",
          "source": {
            "url": "/component/appmixer/aws/s3/ListRegions?outPort=out"
          }
        }
      }
    }
  },
  "outPorts": [
    {
      "name": "object",
      "options": [
        {
          "label": "Bucket Name",
          "value": "Bucket",
          "schema": {
            "type": "string",
            "example": "my-app-data-bucket"
          }
        },
        {
          "label": "Object Key",
          "value": "Key",
          "schema": {
            "type": "string",
            "example": "uploads/images/photo.png"
          }
        },
        {
          "label": "ETag",
          "value": "ETag",
          "schema": {
            "type": "string",
            "example": "\"d41d8cd98f00b204e9800998ecf8427e\""
          }
        },
        {
          "label": "Object Location",
          "value": "Location",
          "schema": {
            "type": "string",
            "example": "https://my-app-data-bucket.s3.us-east-1.amazonaws.com/uploads/images/photo.png"
          }
        },
        {
          "label": "Content Type",
          "value": "ContentType",
          "schema": {
            "type": "string",
            "example": "image/png"
          }
        },
        {
          "label": "Expiry Date",
          "value": "Expires",
          "schema": {
            "type": "string",
            "example": "2024-12-31T23:59:59.000Z"
          }
        }
      ]
    }
  ],
  "icon": "(data URI omitted)"
}
```
