> ## Documentation Index
> Fetch the complete documentation index at: https://docs.maition.com/llms.txt
> Use this file to discover all available pages before exploring further.

# S3

> Configure the mAItion S3 connector to ingest files from AWS S3 and S3-compatible storage.

Use S3 Connector to ingest documents from [S3](https://aws.amazon.com/s3/-compatible) object storage (AWS S3, MinIO, B2, R2, etc).

## What It Does

* reads files from one or more buckets
* converts content to Markdown for indexing
* runs ingestion on configurable schedules

## Required Environment Variables

Set these in `.env.rag`:

* `S3_ACCOUNT1_ENDPOINT`: S3 API endpoint URL
* `S3_ACCOUNT1_ACCESS_KEY`: access key ID
* `S3_ACCOUNT1_SECRET_KEY`: secret key
* `S3_ACCOUNT1_REGION`: bucket region
* `S3_ACCOUNT1_USE_SSL`: `True` or `False`
* `S3_ACCOUNT1_BUCKETS`: bucket name(s), comma-separated for multiple
* `S3_ACCOUNT1_SCHEDULES`: ingestion interval(s) in seconds (default is `3600`)

## `config.yaml` Example

```yaml theme={null}
sources:
  - type: "s3"
    name: "account1"
    enabled: true  # optional, default: true
    config:
      endpoint: "${S3_ACCOUNT1_ENDPOINT}"
      access_key: "${S3_ACCOUNT1_ACCESS_KEY}"
      secret_key: "${S3_ACCOUNT1_SECRET_KEY}"
      region: "${S3_ACCOUNT1_REGION}"
      use_ssl: "${S3_ACCOUNT1_USE_SSL}"
      buckets: "${S3_ACCOUNT1_BUCKETS}"
      schedules: "${S3_ACCOUNT1_SCHEDULES}"
```

## Configuration Reference

| Field           | Required | Default | Description                                                                        |
| --------------- | -------- | ------- | ---------------------------------------------------------------------------------- |
| `enabled`       | no       | `true`  | Set to `false` to skip this source entirely                                        |
| `endpoint`      | yes      | —       | S3 API endpoint URL                                                                |
| `access_key`    | yes      | —       | Access key ID                                                                      |
| `secret_key`    | yes      | —       | Secret access key                                                                  |
| `region`        | yes      | —       | Bucket region                                                                      |
| `use_ssl`       | no       | `True`  | Whether to use HTTPS                                                               |
| `buckets`       | yes      | —       | Bucket name(s), comma-separated                                                    |
| `schedules`     | no       | `3600`  | Ingestion interval in seconds                                                      |
| `request_delay` | no       | `0`     | Seconds to wait between API requests. Increase to avoid rate-limiting (e.g. `0.1`) |

## Multiple S3 Accounts

Add more `sources` entries (`account2`, `account3`, etc) with separate env vars per account.
