> ## Documentation Index
> Fetch the complete documentation index at: https://social-b97141fb-auto-generate-llmstxt.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Messaging Features Overview

> SDK surfaces for creating, querying, updating, deleting, flagging, and engaging with chat messages.

Use chat message APIs to build the message composer, message list, replies, reactions, and moderation actions inside a channel or subchannel. Most message creation APIs target a `subChannelId`; use channel and member APIs when you need to discover the correct chat target first.

<CardGroup cols={2}>
  <Card title="Create Messages" href="./message-creation/send-a-message" icon="send">
    Send text, image, file, video, audio, and custom message payloads where the platform SDK exposes them.
  </Card>

  <Card title="Query Messages" href="./messages/query-and-filter-messages" icon="list-filter">
    Load channel messages, replies, filtered message lists, and paginated message collections.
  </Card>

  <Card title="Manage Messages" href="./messages/edit-and-delete-messages" icon="pen-line">
    Edit supported message types, soft-delete messages, and clear failed local messages where supported.
  </Card>

  <Card title="Flag Messages" href="./message-flagging" icon="flag">
    Let users report or unreport messages for moderation review.
  </Card>
</CardGroup>

## Message Creation Coverage

| Message type | TypeScript                        | iOS                   | Android               | Flutter                                                        |
| ------------ | --------------------------------- | --------------------- | --------------------- | -------------------------------------------------------------- |
| Text         | `MessageRepository.createMessage` | `createTextMessage`   | `createTextMessage`   | `createMessage(...).text(...)`                                 |
| Image        | `MessageRepository.createMessage` | `createImageMessage`  | `createImageMessage`  | `createMessage(...).image(...)`                                |
| File         | `MessageRepository.createMessage` | `createFileMessage`   | `createFileMessage`   | `createMessage(...).file(...)`                                 |
| Video        | `MessageRepository.createMessage` | `createVideoMessage`  | `createVideoMessage`  | `createMessage(...).video(...)`                                |
| Audio        | `MessageRepository.createMessage` | `createAudioMessage`  | `createAudioMessage`  | No current public audio creator in the message create selector |
| Custom       | `MessageRepository.createMessage` | `createCustomMessage` | `createCustomMessage` | `createCustomMessage` or `createMessage(...).custom(...)`      |

<Info>
  Media-message inputs differ by platform. TypeScript creates media messages from uploaded file IDs. iOS accepts `AmityMessageAttachment` values such as `.localURL` or `.fileId`. Android accepts `AmityMessageAttachment` values such as `FILE_ID` or `URL`. Flutter creates image, file, and video messages from a `Uri`.
</Info>

## Implementation Notes

* Resolve the `subChannelId` from your channel flow before creating messages.
* Use `parentId` when creating replies.
* Use `tags` and `metadata` only for app-owned categorization or rendering context.
* Upload or select media first when your target platform expects a file ID or attachment object.
* Keep message state handling in the UI tied to the platform model returned by the SDK.

## Related Topics

<CardGroup cols={2}>
  <Card title="Send a Message" href="./message-creation/send-a-message" icon="send">
    Choose the right create API for each message type.
  </Card>

  <Card title="Reply to a Message" href="./message-creation/reply-to-a-message" icon="reply">
    Create threaded replies with `parentId`.
  </Card>

  <Card title="Query Messages" href="./messages/query-and-filter-messages" icon="list-filter">
    Query top-level messages and reply threads.
  </Card>

  <Card title="Message Flagging" href="./message-flagging" icon="flag">
    Add report and unreport actions for chat messages.
  </Card>
</CardGroup>
