---
title: "POST /model/{modelId}/converse-stream"
method: POST
path: "/model/{modelId}/converse-stream"
---

# POST /model/{modelId}/converse-stream

`POST /model/{modelId}/converse-stream`

Sends messages to the specified Amazon Bedrock model and returns the response in a stream. `ConverseStream` provides a consistent API that works with all Amazon Bedrock models that support messages. This allows you to write code once and use it with different models. Should a model have unique inference parameters, you can also pass those unique parameters to the model.

To find out if a model supports streaming, call [GetFoundationModel](https://docs.aws.amazon.com/bedrock/latest/APIReference/API_GetFoundationModel.html) and check the `responseStreamingSupported` field in the response.

The CLI doesn't support streaming operations in Amazon Bedrock, including `ConverseStream`.

Amazon Bedrock doesn't store any text, images, or documents that you provide as content. The data is only used to generate the response.

You can submit a prompt by including it in the `messages` field, specifying the `modelId` of a foundation model or inference profile to run inference on it, and including any other fields that are relevant to your use case.

You can also submit a prompt from Prompt management by specifying the ARN of the prompt version and including a map of variables to values in the `promptVariables` field. You can append more messages to the prompt by using the `messages` field. If you use a prompt from Prompt management, you can't include the following fields in the request: `additionalModelRequestFields`, `inferenceConfig`, `system`, or `toolConfig`. Instead, these fields must be defined through Prompt management. For more information, see [Use a prompt from Prompt management](https://docs.aws.amazon.com/bedrock/latest/userguide/prompt-management-use.html).

For information about the Converse API, see _Use the Converse API_ in the _Amazon Bedrock User Guide_. To use a guardrail, see _Use a guardrail with the Converse API_ in the _Amazon Bedrock User Guide_. To use a tool with a model, see _Tool use (Function calling)_ in the _Amazon Bedrock User Guide_

For example code, see _Conversation streaming example_ in the _Amazon Bedrock User Guide_.

This operation requires permission for the `bedrock:InvokeModelWithResponseStream` action.

To deny all inference access to resources that you specify in the modelId field, you need to deny access to the `bedrock:InvokeModel` and `bedrock:InvokeModelWithResponseStream` actions. Doing this also denies access to the resource through the base inference actions ([InvokeModel](https://docs.aws.amazon.com/bedrock/latest/APIReference/API_runtime_InvokeModel.html) and [InvokeModelWithResponseStream](https://docs.aws.amazon.com/bedrock/latest/APIReference/API_runtime_InvokeModelWithResponseStream.html)). For more information see [Deny access for inference on specific models](https://docs.aws.amazon.com/bedrock/latest/userguide/security_iam_id-based-policy-examples.html#security_iam_id-based-policy-examples-deny-inference).

For troubleshooting some of the common errors you might encounter when using the `ConverseStream` API, see [Troubleshooting Amazon Bedrock API Error Codes](https://docs.aws.amazon.com/bedrock/latest/userguide/troubleshooting-api-error-codes.html) in the Amazon Bedrock User Guide

## Path parameters

- `modelId` string, required

## Request body

- object
  - `messages` Message[] — The messages that you want to send to the model.
    - `role` 'user' | 'assistant' | 'system', required — The role that the message plays in the message.
    - `content` ContentBlock[], required — <p>The message content. Note the following restrictions:</p> <ul> <li> <p>You can include up to 20 images. Each image's size, height, and width must be no more than 3.75 MB, 8000 px, and 8000 px, respectively.</p> </li> <li> <p>You can include up to five documents. Each document's size must be no more than 4.5 MB.</p> </li> <li> <p>If you include a <code>ContentBlock</code> with a <code>document</code> field in the array, you must also include a <code>ContentBlock</code> with a <code>text</code> field.</p> </li> <li> <p>You can only include images and documents if the <code>role</code> is <code>user</code>.</p> </li> </ul>
      - `text` string — Text to include in the message.
      - `image` object — <p>Image to include in the message. </p> <note> <p>This field is only supported by Anthropic Claude 3 models.</p> </note>
        - `format` 'png' | 'jpeg' | 'gif' | 'webp', required — The format of the image.
        - `source` object, required — The source for the image.
          - `bytes` string — The raw image bytes for the image. If you use an AWS SDK, you don't need to encode the image bytes in base64.
          - `s3Location` object — The location of an image object in an Amazon S3 bucket. To see which models support S3 uploads, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/conversation-inference-supported-models-features.html">Supported models and features for Converse</a>.
            - `uri` string, required — An object URI starting with <code>s3://</code>.
            - `bucketOwner` string — If the bucket belongs to another AWS account, specify that account's ID.
        - `error` object — Error information if the image block could not be processed or contains invalid data.
          - `message` string — A human-readable error message describing what went wrong during content processing.
      - `document` object — A document to include in the message.
        - `format` 'pdf' | 'csv' | 'doc' | 'docx' | 'xls' | 'xlsx' | 'html' | 'txt' | 'md' — The format of a document, or its extension.
        - `name` string, required — <p>A name for the document. The name can only contain the following characters:</p> <ul> <li> <p>Alphanumeric characters</p> </li> <li> <p>Whitespace characters (no more than one in a row)</p> </li> <li> <p>Hyphens</p> </li> <li> <p>Parentheses</p> </li> <li> <p>Square brackets</p> </li> </ul> <note> <p>This field is vulnerable to prompt injections, because the model might inadvertently interpret it as instructions. Therefore, we recommend that you specify a neutral name.</p> </note>
        - `source` object, required — Contains the content of the document.
          - `bytes` string — The raw bytes for the document. If you use an Amazon Web Services SDK, you don't need to encode the bytes in base64.
          - `s3Location` object — The location of a document object in an Amazon S3 bucket. To see which models support S3 uploads, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/conversation-inference-supported-models-features.html">Supported models and features for Converse</a>.
            - `uri` string, required — An object URI starting with <code>s3://</code>.
            - `bucketOwner` string — If the bucket belongs to another AWS account, specify that account's ID.
          - `text` string — The text content of the document source.
          - `content` DocumentContentBlock[] — The structured content of the document source, which may include various content blocks such as text, images, or other document elements.
            - `text` string — The text content of the document.
        - `context` string — Contextual information about how the document should be processed or interpreted by the model when generating citations.
        - `citations` object — Configuration settings that control how citations should be generated for this specific document.
          - `enabled` boolean, required — Specifies whether citations from the selected document should be used in the model's response. When set to true, the model can generate citations that reference the source documents used to inform the response.
      - `video` object — Video to include in the message.
        - `format` 'mkv' | 'mov' | 'mp4' | 'webm' | 'flv' | 'mpeg' | 'mpg' | 'wmv' | 'three_gp', required — The block's format.
        - `source` object, required — The block's source.
          - `bytes` string — Video content encoded in base64.
          - `s3Location` object — The location of a video object in an Amazon S3 bucket. To see which models support S3 uploads, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/conversation-inference-supported-models-features.html">Supported models and features for Converse</a>.
            - `uri` string, required — An object URI starting with <code>s3://</code>.
            - `bucketOwner` string — If the bucket belongs to another AWS account, specify that account's ID.
      - `audio` object — An audio content block containing audio data in the conversation.
        - `format` 'mp3' | 'opus' | 'wav' | 'aac' | 'flac' | 'mp4' | 'ogg' | 'mkv' | 'mka' | 'x-aac' | 'm4a' | 'mpeg' | 'mpga' | 'pcm' | 'webm', required — The format of the audio data, such as MP3, WAV, FLAC, or other supported audio formats.
        - `source` object, required — The source of the audio data, which can be provided as raw bytes or an S3 location.
          - `bytes` string — Audio data encoded in base64.
          - `s3Location` object — A reference to audio data stored in an Amazon S3 bucket. To see which models support S3 uploads, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/conversation-inference-supported-models-features.html">Supported models and features for Converse</a>.
            - `uri` string, required — An object URI starting with <code>s3://</code>.
            - `bucketOwner` string — If the bucket belongs to another AWS account, specify that account's ID.
        - `error` object — Error information if the audio block could not be processed or contains invalid data.
          - `message` string — A human-readable error message describing what went wrong during content processing.
      - `toolUse` object — Information about a tool use request from a model.
        - `toolUseId` string, required — The ID for the tool request.
        - `name` string, required — The name of the tool that the model wants to use.
        - `input` object, required — The input to pass to the tool.
        - `type` 'server_tool_use' — The type for the tool request.
      - `toolResult` object — The result for a tool request that a model makes.
        - `toolUseId` string, required — The ID of the tool request that this is the result for.
        - `content` ToolResultContentBlock[], required — The content for tool result content block.
          - `json` object — A tool result that is JSON format data.
          - `text` string — A tool result that is text.
          - `image` object — <p>A tool result that is an image. </p> <note> <p>This field is only supported by Amazon Nova and Anthropic Claude 3 and 4 models.</p> </note>
            - `format` 'png' | 'jpeg' | 'gif' | 'webp', required — The format of the image.
            - `source` object, required — The source for the image.
              - …
            - `error` object — Error information if the image block could not be processed or contains invalid data.
              - …
          - `document` object — A tool result that is a document.
            - `format` 'pdf' | 'csv' | 'doc' | 'docx' | 'xls' | 'xlsx' | 'html' | 'txt' | 'md' — The format of a document, or its extension.
            - `name` string, required — <p>A name for the document. The name can only contain the following characters:</p> <ul> <li> <p>Alphanumeric characters</p> </li> <li> <p>Whitespace characters (no more than one in a row)</p> </li> <li> <p>Hyphens</p> </li> <li> <p>Parentheses</p> </li> <li> <p>Square brackets</p> </li> </ul> <note> <p>This field is vulnerable to prompt injections, because the model might inadvertently interpret it as instructions. Therefore, we recommend that you specify a neutral name.</p> </note>
            - `source` object, required — Contains the content of the document.
              - …
            - `context` string — Contextual information about how the document should be processed or interpreted by the model when generating citations.
            - `citations` object — Configuration settings that control how citations should be generated for this specific document.
              - …
          - `video` object — A tool result that is video.
            - `format` 'mkv' | 'mov' | 'mp4' | 'webm' | 'flv' | 'mpeg' | 'mpg' | 'wmv' | 'three_gp', required — The block's format.
            - `source` object, required — The block's source.
              - …
          - `searchResult` object — A tool result that is a search result.
            - `source` string, required — The source URL or identifier for the content.
            - `title` string, required — A descriptive title for the search result.
            - `content` SearchResultContentBlock[], required — An array of search result content block.
              - …
            - `citations` object — Configuration setting for citations
              - …
        - `status` 'success' | 'error' — <p>The status for the tool result content block.</p> <note> <p>This field is only supported by Amazon Nova and Anthropic Claude 3 and 4 models.</p> </note>
        - `type` string — The type for the tool result content block.
      - `guardContent` object — <p>Contains the content to assess with the guardrail. If you don't specify <code>guardContent</code> in a call to the Converse API, the guardrail (if passed in the Converse API) assesses the entire message.</p> <p>For more information, see <i>Use a guardrail with the Converse API</i> in the <i>Amazon Bedrock User Guide</i>.</p>
        - `text` object — The text to guard.
          - `text` string, required — The text that you want to guard.
          - `qualifiers` GuardrailConverseContentQualifier[] — The qualifier details for the guardrails contextual grounding filter.
        - `image` object — Image within converse content block to be evaluated by the guardrail.
          - `format` 'png' | 'jpeg', required — The format details for the image type of the guardrail converse image block.
          - `source` object, required — The image source (image bytes) of the guardrail converse image block.
            - `bytes` string — The raw image bytes for the image.
      - `cachePoint` object — CachePoint to include in the message.
        - `type` 'default', required — Specifies the type of cache point within the CachePointBlock.
        - `ttl` '5m' | '1h' — Optional TTL duration for cache entries. When specified, enables extended TTL caching with the specified duration. When omitted, uses <code>type</code> value for caching behavior.
      - `reasoningContent` object — Contains content regarding the reasoning that is carried out by the model. Reasoning refers to a Chain of Thought (CoT) that the model generates to enhance the accuracy of its final response.
        - `reasoningText` object — The reasoning that the model used to return the output.
          - `text` string, required — The reasoning that the model used to return the output.
          - `signature` string — A token that verifies that the reasoning text was generated by the model. If you pass a reasoning block back to the API in a multi-turn conversation, include the text and its signature unmodified.
        - `redactedContent` string — The content in the reasoning that was encrypted by the model provider for safety reasons. The encryption doesn't affect the quality of responses.
      - `citationsContent` object — A content block that contains both generated text and associated citation information, providing traceability between the response and source documents.
        - `content` CitationGeneratedContent[] — The generated content that is supported by the associated citations.
          - `text` string — The text content that was generated by the model and is supported by the associated citation.
        - `citations` Citation[] — An array of citations that reference the source documents used to generate the associated content.
          - `title` string — The title or identifier of the source document being cited.
          - `source` string — The source from the original search result that provided the cited content.
          - `sourceContent` CitationSourceContent[] — The specific content from the source document that was referenced or cited in the generated response.
            - `text` string — The text content from the source document that is being cited.
          - `location` object — The precise location within the source document where the cited content can be found, including character positions, page numbers, or chunk identifiers.
            - `web` object — The web URL that was cited for this reference.
              - …
            - `documentChar` object — The character-level location within the document where the cited content is found.
              - …
            - `documentPage` object — The page-level location within the document where the cited content is found.
              - …
            - `documentChunk` object — The chunk-level location within the document where the cited content is found, typically used for documents that have been segmented into logical chunks.
              - …
            - `searchResultLocation` object — The search result location where the cited content is found, including the search result index and block positions within the content array.
              - …
      - `searchResult` object — Search result to include in the message.
        - `source` string, required — The source URL or identifier for the content.
        - `title` string, required — A descriptive title for the search result.
        - `content` SearchResultContentBlock[], required — An array of search result content block.
          - `text` string, required — The actual text content
        - `citations` object — Configuration setting for citations
          - `enabled` boolean, required — Specifies whether citations from the selected document should be used in the model's response. When set to true, the model can generate citations that reference the source documents used to inform the response.
  - `system` SystemContentBlock[] — A prompt that provides instructions or context to the model about the task it should perform, or the persona it should adopt during the conversation.
    - `text` string — A system prompt for the model.
    - `guardContent` object — <p>A content block to assess with the guardrail. Use with the <a href="https://docs.aws.amazon.com/bedrock/latest/APIReference/API_runtime_Converse.html">Converse</a> or <a href="https://docs.aws.amazon.com/bedrock/latest/APIReference/API_runtime_ConverseStream.html">ConverseStream</a> API operations. </p> <p>For more information, see <i>Use a guardrail with the Converse API</i> in the <i>Amazon Bedrock User Guide</i>.</p>
      - `text` object — The text to guard.
        - `text` string, required — The text that you want to guard.
        - `qualifiers` GuardrailConverseContentQualifier[] — The qualifier details for the guardrails contextual grounding filter.
      - `image` object — Image within converse content block to be evaluated by the guardrail.
        - `format` 'png' | 'jpeg', required — The format details for the image type of the guardrail converse image block.
        - `source` object, required — The image source (image bytes) of the guardrail converse image block.
          - `bytes` string — The raw image bytes for the image.
    - `cachePoint` object — CachePoint to include in the system prompt.
      - `type` 'default', required — Specifies the type of cache point within the CachePointBlock.
      - `ttl` '5m' | '1h' — Optional TTL duration for cache entries. When specified, enables extended TTL caching with the specified duration. When omitted, uses <code>type</code> value for caching behavior.
  - `inferenceConfig` object — <p>Base inference parameters to pass to a model in a call to <a href="https://docs.aws.amazon.com/bedrock/latest/APIReference/API_runtime_Converse.html">Converse</a> or <a href="https://docs.aws.amazon.com/bedrock/latest/APIReference/API_runtime_ConverseStream.html">ConverseStream</a>. For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/model-parameters.html">Inference parameters for foundation models</a>.</p> <p>If you need to pass additional parameters that the model supports, use the <code>additionalModelRequestFields</code> request field in the call to <code>Converse</code> or <code>ConverseStream</code>. For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/model-parameters.html">Model parameters</a>.</p>
    - `maxTokens` integer — The maximum number of tokens to allow in the generated response. The default value is the maximum allowed value for the model that you are using. For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/model-parameters.html">Inference parameters for foundation models</a>.
    - `temperature` number, float — <p>The likelihood of the model selecting higher-probability options while generating a response. A lower value makes the model more likely to choose higher-probability options, while a higher value makes the model more likely to choose lower-probability options.</p> <p>The default value is the default value for the model that you are using. For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/model-parameters.html">Inference parameters for foundation models</a>. </p>
    - `topP` number, float — <p>The percentage of most-likely candidates that the model considers for the next token. For example, if you choose a value of 0.8 for <code>topP</code>, the model selects from the top 80% of the probability distribution of tokens that could be next in the sequence.</p> <p>The default value is the default value for the model that you are using. For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/model-parameters.html">Inference parameters for foundation models</a>. </p>
    - `stopSequences` NonEmptyString[] — A list of stop sequences. A stop sequence is a sequence of characters that causes the model to stop generating the response.
  - `toolConfig` object — Configuration information for the tools that you pass to a model. For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/tool-use.html">Tool use (function calling)</a> in the Amazon Bedrock User Guide.
    - `tools` Tool[] — An array of tools that you want to pass to a model.
      - `toolSpec` object — The specfication for the tool.
        - `name` string, required — The name for the tool.
        - `description` string — The description for the tool.
        - `inputSchema` object, required — The input schema for the tool in JSON format.
          - `json` object — The JSON schema for the tool. For more information, see <a href="https://json-schema.org/understanding-json-schema/reference">JSON Schema Reference</a>.
        - `strict` boolean — Flag to enable structured output enforcement on a tool usage response.
      - `systemTool` object — Specifies the system-defined tool that you want use.
        - `name` string, required — The name of the system-defined tool that you want to call.
      - `cachePoint` object — CachePoint to include in the tool configuration.
        - `type` 'default', required — Specifies the type of cache point within the CachePointBlock.
        - `ttl` '5m' | '1h' — Optional TTL duration for cache entries. When specified, enables extended TTL caching with the specified duration. When omitted, uses <code>type</code> value for caching behavior.
    - `toolChoice` object — If supported by model, forces the model to request a tool.
      - `auto` object — (Default). The Model automatically decides if a tool should be called or whether to generate text instead.
      - `any` object — The model must request at least one tool (no text is generated).
      - `tool` object — The Model must request the specified tool. Only supported by Anthropic Claude 3 and Amazon Nova models.
        - `name` string, required — The name of the tool that the model must request.
  - `guardrailConfig` object — Configuration information for a guardrail that you use with the <a href="https://docs.aws.amazon.com/bedrock/latest/APIReference/API_runtime_ConverseStream.html">ConverseStream</a> action.
    - `guardrailIdentifier` string — The identifier for the guardrail.
    - `guardrailVersion` string — The version of the guardrail.
    - `trace` 'enabled' | 'disabled' | 'enabled_full' — The trace behavior for the guardrail.
    - `streamProcessingMode` 'sync' | 'async' — <p>The processing mode. </p> <p>The processing mode. For more information, see <i>Configure streaming response behavior</i> in the <i>Amazon Bedrock User Guide</i>. </p>
  - `additionalModelRequestFields` object — Additional inference parameters that the model supports, beyond the base set of inference parameters that <code>Converse</code> and <code>ConverseStream</code> support in the <code>inferenceConfig</code> field. For more information, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/model-parameters.html">Model parameters</a>.
  - `promptVariables` object — Contains a map of variables in a prompt from Prompt management to objects containing the values to fill in for them when running model invocation. This field is ignored if you don't specify a prompt resource in the <code>modelId</code> field.
  - `additionalModelResponseFieldPaths` ConverseStreamRequestAdditionalModelResponseFieldPathsListMemberString[] — <p>Additional model parameters field paths to return in the response. <code>Converse</code> and <code>ConverseStream</code> return the requested fields as a JSON Pointer object in the <code>additionalModelResponseFields</code> field. The following is example JSON for <code>additionalModelResponseFieldPaths</code>.</p> <p> <code>[ "/stop_sequence" ]</code> </p> <p>For information about the JSON Pointer syntax, see the <a href="https://datatracker.ietf.org/doc/html/rfc6901">Internet Engineering Task Force (IETF)</a> documentation.</p> <p> <code>Converse</code> and <code>ConverseStream</code> reject an empty JSON Pointer or incorrectly structured JSON Pointer with a <code>400</code> error code. if the JSON Pointer is valid, but the requested field is not in the model response, it is ignored by <code>Converse</code>.</p>
  - `requestMetadata` object — Key-value pairs that you can use to filter invocation logs.
  - `performanceConfig` object — Performance settings for a model.
    - `latency` 'standard' | 'optimized' — To use a latency-optimized version of the model, set to <code>optimized</code>.
  - `serviceTier` object — Specifies the processing tier configuration used for serving the request.
    - `type` 'priority' | 'default' | 'flex' | 'reserved' — Specifies the processing tier type used for serving the request.
  - `outputConfig` object — Output configuration for a model response in a call to <a href="https://docs.aws.amazon.com/bedrock/latest/APIReference/API_runtime_Converse.html">Converse</a> or <a href="https://docs.aws.amazon.com/bedrock/latest/APIReference/API_runtime_ConverseStream.html">ConverseStream</a>.
    - `textFormat` object — Structured output parameters to control the model's text response.
      - `type` 'json_schema', required — The type of structured output format.
      - `structure` object, required — The structure that the model's output must adhere to.
        - `jsonSchema` object — A JSON schema structure that the model's output must adhere to.
          - `schema` string, required — The JSON schema to constrain the model's output. For more information, see <a href="https://json-schema.org/understanding-json-schema/reference">JSON Schema Reference</a>.
          - `name` string — The name of the JSON schema.
          - `description` string — A description of the JSON schema.

## Response `200`

Success

- ConverseStreamResponse
  - `stream` object — The output stream that the model generated.
    - `messageStart` object — Message start information.
      - `role` 'user' | 'assistant' | 'system', required — The role for the message.
    - `contentBlockStart` object — Start information for a content block.
      - `start` object, required — Start information about a content block start event.
        - `toolUse` object — Information about a tool that the model is requesting to use.
          - `toolUseId` string, required — The ID for the tool request.
          - `name` string, required — The name of the tool that the model is requesting to use.
          - `type` 'server_tool_use' — The type for the tool request.
        - `toolResult` object — The
          - `toolUseId` string, required — The ID of the tool that was used to generate this tool result block.
          - `type` string — The type for the tool that was used to generate this tool result block.
          - `status` 'success' | 'error' — The status of the tool result block.
        - `image` object — The initial event indicating the start of a streaming image block.
          - `format` 'png' | 'jpeg' | 'gif' | 'webp', required — The format of the image data that will be streamed in subsequent delta events.
      - `contentBlockIndex` integer, required — The index for a content block start event.
    - `contentBlockDelta` object — The messages output content block delta.
      - `delta` object, required — The delta for a content block delta event.
        - `text` string — The content text.
        - `toolUse` object — Information about a tool that the model is requesting to use.
          - `input` string, required — The input for a requested tool.
        - `toolResult` ToolResultBlockDelta[] — An incremental update that contains the results from a tool call.
          - `text` string — The reasoning the model used to return the output.
          - `json` object — The JSON schema for the tool result content block. see <a href="https://json-schema.org/understanding-json-schema/reference">JSON Schema Reference</a>.
        - `reasoningContent` object — Contains content regarding the reasoning that is carried out by the model. Reasoning refers to a Chain of Thought (CoT) that the model generates to enhance the accuracy of its final response.
          - `text` string — The reasoning that the model used to return the output.
          - `redactedContent` string — The content in the reasoning that was encrypted by the model provider for safety reasons. The encryption doesn't affect the quality of responses.
          - `signature` string — A token that verifies that the reasoning text was generated by the model. If you pass a reasoning block back to the API in a multi-turn conversation, include the text and its signature unmodified.
        - `citation` object — Incremental citation information that is streamed as part of the response generation process.
          - `title` string — The title or identifier of the source document being cited.
          - `source` string — The source from the original search result that provided the cited content.
          - `sourceContent` CitationSourceContentDelta[] — The specific content from the source document that was referenced or cited in the generated response.
            - `text` string — An incremental update to the text content from the source document that is being cited.
          - `location` object — Specifies the precise location within a source document where cited content can be found. This can include character-level positions, page numbers, or document chunks depending on the document type and indexing method.
            - `web` object — The web URL that was cited for this reference.
              - …
            - `documentChar` object — The character-level location within the document where the cited content is found.
              - …
            - `documentPage` object — The page-level location within the document where the cited content is found.
              - …
            - `documentChunk` object — The chunk-level location within the document where the cited content is found, typically used for documents that have been segmented into logical chunks.
              - …
            - `searchResultLocation` object — The search result location where the cited content is found, including the search result index and block positions within the content array.
              - …
        - `image` object — A streaming delta event containing incremental image data.
          - `source` object — The incremental image source data for this delta event.
            - `bytes` string — The raw image bytes for the image. If you use an AWS SDK, you don't need to encode the image bytes in base64.
            - `s3Location` object — The location of an image object in an Amazon S3 bucket. To see which models support S3 uploads, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/conversation-inference-supported-models-features.html">Supported models and features for Converse</a>.
              - …
          - `error` object — Error information if this image delta could not be processed.
            - `message` string — A human-readable error message describing what went wrong during content processing.
      - `contentBlockIndex` integer, required — The block index for a content block delta event.
    - `contentBlockStop` object — Stop information for a content block.
      - `contentBlockIndex` integer, required — The index for a content block.
    - `messageStop` object — Message stop information.
      - `stopReason` 'end_turn' | 'tool_use' | 'max_tokens' | 'stop_sequence' | 'guardrail_intervened' | 'content_filtered' | 'malformed_model_output' | 'malformed_tool_use' | 'model_context_window_exceeded', required — The reason why the model stopped generating output.
      - `additionalModelResponseFields` object — The additional model response fields.
    - `metadata` object — Metadata for the converse output stream.
      - `usage` object, required — Usage information for the conversation stream event.
        - `inputTokens` integer, required — The number of tokens sent in the request to the model.
        - `outputTokens` integer, required — The number of tokens that the model generated for the request.
        - `totalTokens` integer, required — The total of input tokens and tokens generated by the model.
        - `cacheReadInputTokens` integer — The number of input tokens read from the cache for the request.
        - `cacheWriteInputTokens` integer — The number of input tokens written to the cache for the request.
        - `cacheDetails` CacheDetail[] — Detailed breakdown of cache writes by TTL. Empty if no cache creation occurred. Sorted by TTL duration (1h before 5m).
          - `ttl` '5m' | '1h', required — TTL duration for these cached tokens
          - `inputTokens` integer, required — Number of tokens written to cache with this TTL (cache creation tokens)
      - `metrics` object, required — The metrics for the conversation stream metadata event.
        - `latencyMs` integer, required — The latency for the streaming request, in milliseconds.
      - `trace` object — The trace object in the response from <a href="https://docs.aws.amazon.com/bedrock/latest/APIReference/API_runtime_ConverseStream.html">ConverseStream</a> that contains information about the guardrail behavior.
        - `guardrail` object — The guardrail trace object.
          - `modelOutput` GuardrailOutputText[] — The output from the model.
          - `inputAssessment` object — The input assessment.
          - `outputAssessments` object — the output assessments.
          - `actionReason` string — Provides the reason for the action taken when harmful content is detected.
        - `promptRouter` object — The request's prompt router.
          - `invokedModelId` string — The ID of the invoked model.
      - `performanceConfig` object — Model performance configuration metadata for the conversation stream event.
        - `latency` 'standard' | 'optimized' — To use a latency-optimized version of the model, set to <code>optimized</code>.
      - `serviceTier` object — Specifies the processing tier configuration used for serving the request.
        - `type` 'priority' | 'default' | 'flex' | 'reserved', required — Specifies the processing tier type used for serving the request.
    - `internalServerException` object — An internal server error occurred. Retry your request.
      - `message` string
    - `modelStreamErrorException` object — A streaming error occurred. Retry your request.
      - `message` string
      - `originalStatusCode` integer — The original status code.
      - `originalMessage` string — The original message.
    - `validationException` object — The input fails to satisfy the constraints specified by <i>Amazon Bedrock</i>. For troubleshooting this error, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/troubleshooting-api-error-codes.html#ts-validation-error">ValidationError</a> in the Amazon Bedrock User Guide.
      - `message` string
    - `throttlingException` object — Your request was denied due to exceeding the account quotas for <i>Amazon Bedrock</i>. For troubleshooting this error, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/troubleshooting-api-error-codes.html#ts-throttling-exception">ThrottlingException</a> in the Amazon Bedrock User Guide.
      - `message` string
    - `serviceUnavailableException` object — The service isn't currently available. For troubleshooting this error, see <a href="https://docs.aws.amazon.com/bedrock/latest/userguide/troubleshooting-api-error-codes.html#ts-service-unavailable">ServiceUnavailable</a> in the Amazon Bedrock User Guide
      - `message` string

## Other responses

- `480` — AccessDeniedException
- `481` — ThrottlingException
- `482` — ResourceNotFoundException
- `483` — ModelTimeoutException
- `484` — InternalServerException
- `485` — ServiceUnavailableException
- `486` — ValidationException
- `487` — ModelNotReadyException
- `488` — ModelErrorException

---

[API](https://skmtc.net/aws/apis/bedrock-runtime.md) · [All operations](https://skmtc.net/aws/apis/bedrock-runtime/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/aws/bedrock-runtime/versions/8a393198b636/schema)
