---
title: "POST /streams/{streamId}"
method: POST
path: "/streams/{streamId}"
---

# POST /streams/{streamId}

`POST /streams/{streamId}`

Creates a stream for delivering one or more large files in chunks over MQTT. A stream transports data bytes in chunks or blocks packaged as MQTT messages from a source like S3. You can have one or more files associated with a stream.

Requires permission to access the [CreateStream](https://docs.aws.amazon.com/service-authorization/latest/reference/list_awsiot.html#awsiot-actions-as-permissions) action.

## Path parameters

- `streamId` string, required

## Request body

- object
  - `description` string — A description of the stream.
  - `files` StreamFile[], required — The files to stream.
    - `fileId` integer — The file ID.
    - `s3Location` object — The location of the file in S3.
      - `bucket` string — The S3 bucket.
      - `key` string — The S3 key.
      - `version` string — The S3 bucket version.
  - `roleArn` string, required — An IAM role that allows the IoT service principal to access your S3 files.
  - `tags` Tag[] — Metadata which can be used to manage streams.
    - `Key` string, required — The tag's key.
    - `Value` string — The tag's value.

## Response `200`

Success

- CreateStreamResponse
  - `streamId` string — The stream ID.
  - `streamArn` string — The stream ARN.
  - `description` string — A description of the stream.
  - `streamVersion` integer — The version of the stream.

## Other responses

- `480` — InvalidRequestException
- `481` — LimitExceededException
- `482` — ResourceNotFoundException
- `483` — ResourceAlreadyExistsException
- `484` — ThrottlingException
- `485` — UnauthorizedException
- `486` — ServiceUnavailableException
- `487` — InternalFailureException

---

[API](https://skmtc.net/aws/apis/iot.md) · [All operations](https://skmtc.net/aws/apis/iot/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/aws/iot/revisions/deef5c4b09f0/schema)
