Back to Copilotkit

Image

showcase/shell-docs/src/content/reference/bot/components/Image.mdx

1.60.1862 B
Original Source

Overview

Image embeds an image in the message by URL.

Import

tsx
import { Image } from "@copilotkit/bot-ui";

Props

<PropertyReference name="url" type="string" required> The image URL. Must be reachable by the platform (Slack fetches it server-side). </PropertyReference> <PropertyReference name="alt" type="string"> Alternative text for accessibility. </PropertyReference>

Usage

tsx
<Message>
  <Section>Incident timeline:</Section>
  <Image url="https://example.com/chart.png" alt="Error rate over time" />
</Message>

On Slack

Renders as an image block. To post a locally generated image (e.g. a rendered chart), upload it with thread.postFile instead — Image is for URLs.