> For the complete documentation index, see [llms.txt](https://docs.transferchain.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.transferchain.io/transferchain-sdk/s4/using-transferchain-s4/storage.md).

# Storage

TransferChain S4 provides a privacy-enhancing wrapper around standard S3 operations.

* Create secure buckets ((Note: Buckets are created and managed via TransferChain S4’s S3-compatible interface — not directly on AWS S3 or other providers.)
* Upload and retrieve files
* List objects
* Delete objects

All objects are:

* Client-side encrypted
* Split into multiple fragments
* Stored across multiple backends (based on your configuration)
* &#x20;Immutable unless explicitly overwritten

### Upload

**Endpoint:** /v1/storage/upload\
**Method:** POST<br>

Body:

```json
{
  "files": ["raw file data", "/home/transferchain/file1.zip"]
}
```

Response:

```json
{
  "data": {
    "transactions": [
      {
        "id": "<txID>",
        "version": 2,
        "type": "storage",
        "sender_addr": "<your random address>",
        "recipient_addr": "<your random address>",
        "data": "<base encoded, encrypted data>",
        "sign": "<base encoded, sha512 hashed sender signed data>",
        "fee": 0
      }
    ],
    "storages": [
      {
        "UUID": "<string>",
        "FileName": "<uuid_v4>",
        "Size": 97,
        "Slots": [
          {
            "base_uuid": "<string>",
            "uuid": "<string>",
            "storage_service": "<provider title>",
            "storage_code": "<provider code>",
            "size": 0,
            "size_rl": 0,
            "user_id": 0,
            "chunk_size": 0
          }
        ],
        "KeyAES": "<base64 encoded random bytes>",
        "KeyHMAC": "<base64 encoded random bytes>",
        "UploadDate": "RFC3339 TIMESTAMP",
        "Policy": {
          "ID": "<string>",
          "Identifier": "<string>",
          "Owner": "<your random address>",
          "SourceIdentifier": "<your random address>",
          "TargetIdentifier": "<your random address>",
          "OPCode": "storage",
          "Policy": "owner",
          "EventType": "create",
          "CreatedAt": "RFC3339 TIMESTAMP"
        }
      }
    ],
    "mapped_storages": {
      "<txID>": {
        "UUID": "<string>",
        "FileName": "<uuid_v4>",
        "Size": 97,
        "Slots": [
          {
            "base_uuid": "<string>",
            "uuid": "<string>",
            "storage_service": "<provider title>",
            "storage_code": "<provider code>",
            "size": 0,
            "size_rl": 0,
            "user_id": 0,
            "chunk_size": 0
          }
        ],
        "KeyAES": "<base64 encoded random bytes>",
        "KeyHMAC": "<base64 encoded random bytes>",
        "UploadDate": "RFC3339 TIMESTAMP",
        "Policy": {
          "ID": "<string>",
          "Identifier": "<string>",
          "Owner": "<your random address>",
          "SourceIdentifier": "<your random address>",
          "TargetIdentifier": "<your random address>",
          "OPCode": "storage",
          "Policy": "owner",
          "EventType": "create",
          "CreatedAt": "RFC3339 TIMESTAMP"
        }
      }
    }
  }
}
```
