> For the complete documentation index, see [llms.txt](https://docs.impossiblecloud.com/impossible-cloud-help/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.impossiblecloud.com/impossible-cloud-help/impossible-cloud-storage-guide/cli-user-guide/aws-cli-commands-1.md).

# AWS CLI advanced commands

## General commands syntax

This section is designed to explain the low-level '**s3api**' commands for the CLI

```
aws s3api <Command> [<Arg> ...]
```

{% tabs %}
{% tab title="Syntax" %}

```
aws s3api --profile=impossiblecloud --endpoint-url=https://eu-central-2.storage.impossibleapi.net <ACTION> <FILE SOURCE> <FILE DESTINATION>
```

{% endtab %}
{% endtabs %}

## Supported low-level commands

### Bucket-level

| **Action**                                       | **Command**                               |
| ------------------------------------------------ | ----------------------------------------- |
| CreateBucket                                     | `aws s3api create-bucket`                 |
| DeleteBucket                                     | `aws s3api delete-bucket`                 |
| HeadBucket                                       | `aws s3api head-bucket`                   |
| GetBucketLocation                                | `aws s3api get-bucket-location`           |
| GetBucketCORS                                    | `aws s3api get-bucket-cors`               |
| PutBucketCORS                                    | `aws s3api put-bucket-cors`               |
| DeleteBucketCORS                                 | `aws s3api delete-bucket-cors`            |
| GetBucketEncryption (GetEncryptionConfiguration) | `aws s3api get-bucket-encryption`         |
| PutBucketEncryption (PutEncryptionConfiguration) | `aws s3api put-bucket-encryption`         |
| DeleteBucketEncryption                           | `aws s3api delete-bucket-encryption`      |
| GetBucketTagging                                 | `aws s3api get-bucket-tagging`            |
| PutBucketTagging                                 | `aws s3api put-bucket-tagging`            |
| DeleteBucketTagging                              | `aws s3api delete-bucket-tagging`         |
| GetBucketVersioning                              | `aws s3api get-bucket-versioning`         |
| PutBucketVersioning                              | `aws s3api put-bucket-versioning`         |
| GetObjectLockConfiguration (bucket)              | `aws s3api get-object-lock-configuration` |
| PutObjectLockConfiguration (bucket)              | `aws s3api put-object-lock-configuration` |
| ListBucket (ListObjects)                         | `aws s3api list-objects`                  |
| ListBucketVersions                               | `aws s3api list-object-versions`          |
| ListBucketMultipartUploads                       | `aws s3api list-multipart-uploads`        |
| ListBuckets                                      | `aws s3api list-buckets`                  |

### Object-level

| **Action**                 | **Command**                       |
| -------------------------- | --------------------------------- |
| HeadObject                 | `aws s3api head-object`           |
| GetObject                  | `aws s3api get-object`            |
| GetObjectVersion           | `aws s3api get-object`            |
| GetObjectAttributes        | `aws s3api get-object-attributes` |
| GetObjectVersionAttributes | `aws s3api get-object-attributes` |
| GetObjectTagging           | `aws s3api get-object-tagging`    |
| GetObjectVersionTagging    | `aws s3api get-object-tagging`    |
| PutObject                  | `aws s3api put-object`            |
| PutObjectTagging           | `aws s3api put-object-tagging`    |
| PutObjectVersionTagging    | `aws s3api put-object-tagging`    |
| DeleteObject               | `aws s3api delete-object`         |
| DeleteObjectVersion        | `aws s3api delete-object`         |
| DeleteObjectTagging        | `aws s3api delete-object-tagging` |
| DeleteObjectVersionTagging | `aws s3api delete-object-tagging` |
| PutObjectRetention         | `aws s3api put-object-retention`  |
| GetObjectRetention         | `aws s3api get-object-retention`  |
| PutObjectLegalHold         | `aws s3api put-object-legal-hold` |
| GetObjectLegalHold         | `aws s3api get-object-legal-hold` |
| CopyObject                 | `aws s3api copy-object`           |
| ListObjects                | `aws s3api list-objects`          |
| ListObjectsV2              | `aws s3api list-objects-v2`       |

### Multipart & Batch

| **Action**                       | **Command**                                                                                                 |
| -------------------------------- | ----------------------------------------------------------------------------------------------------------- |
| CreateMultipartUpload            | `aws s3api create-multipart-upload`                                                                         |
| UploadPart                       | `aws s3api upload-part`                                                                                     |
| UploadPartCopy                   | `aws s3api upload-part-copy`                                                                                |
| ListParts                        | `aws s3api list-parts`                                                                                      |
| CompleteMultipartUpload          | `aws s3api complete-multipart-upload`                                                                       |
| AbortMultipartUpload             | `aws s3api abort-multipart-upload`                                                                          |
| DeleteObjects (batch)            | `aws s3api delete-objects`                                                                                  |
| BypassGovernanceRetention (flag) | *(use with `delete-object` / `delete-objects`; e.g., add `--bypass-governance-retention` after the bucket)* |

## Examples

You can find examples of some most useful commands [here](/impossible-cloud-help/impossible-cloud-storage-guide/cli-user-guide/aws-cli-commands-1/examples.md).

## Links and references

You can find more information in the AWS CLI [user guide](https://awscli.amazonaws.com/v2/documentation/api/latest/reference/s3api/index.html) and [developers guide](https://docs.aws.amazon.com/AmazonS3/latest/userguide/creating-buckets-s3.html).


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.impossiblecloud.com/impossible-cloud-help/impossible-cloud-storage-guide/cli-user-guide/aws-cli-commands-1.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
