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

# S3 Sink

> Upload job results to an S3 bucket or S3-compatible storage

The S3 Sink command (Command Type: 1202) sends the job result to the sink service, which uploads it to an S3 bucket. The full object key is: `{keyPrefix}/{YYYY}/{MM}/{DD}/{uuid}.json`.

## Command Type

**Command Type ID:** 1202

## Parameters

| Parameter             | Type    | Description                                                                                       | Required |
| --------------------- | ------- | ------------------------------------------------------------------------------------------------- | -------- |
| **bucket**            | string  | Destination S3 bucket name                                                                        | Yes      |
| **keyPrefix**         | string  | Prefix prepended to every uploaded object key                                                     | Yes      |
| **compress**          | boolean | When `true`, gzip-compresses the payload before upload (key uses `.json.gz` extension)            | No       |
| **dataSegmentToSend** | string  | Which part of the data to send. Possible values: `"fullData"`, `"data"`. Defaults to `"fullData"` | No       |

## Usage Examples

### Upload to S3

```json theme={null}
{
  "command": "s3-sink",
  "params": {
    "bucket": "my-data-bucket",
    "keyPrefix": "events/football"
  }
}
```

### Upload Compressed

```json theme={null}
{
  "command": "s3-sink",
  "params": {
    "bucket": "my-data-bucket",
    "keyPrefix": "odds/live",
    "compress": true,
    "dataSegmentToSend": "data"
  }
}
```

## Related Commands

* [Managed Bucket Sink](/stream/commands/sink/managed-bucket-sink) - Upload to LSports-managed GCS bucket
* [Kafka Sink](/stream/commands/sink/kafka-sink) - Publish to Kafka
* [RabbitMQ Sink](/stream/commands/sink/rabbitmq-sink) - Publish to RabbitMQ
