---
title: "Send text and optionally one attachment to an existing eligible chat"
method: POST
path: "/messages"
---

# Send text and optionally one attachment to an existing eligible chat

`POST /messages`

## Request

- Base URL: `https://gramclaw.com/api/v1`
- URL: `https://gramclaw.com/api/v1/messages`
- Auth: HTTP bearer

Requires a send-scoped key and Idempotency-Key. JSON sends text; multipart sends exactly one attachment (maximum 25 MiB) with optional text. Multiple attachments, automatic retries, provider fallbacks, new-chat creation, and bulk sends are unsupported.

## Headers

- `Idempotency-Key` string, required

## Request body

- SendRequest
  - `account_id` string, required
  - `chat_id` string, required
  - `text` string, required

## Response `200`

Accepted canonical result, or replay of the same completed idempotent operation

## Other responses

- `400`: Invalid input, unsupported attachment count/type, or idempotency collision
- `403`: Missing send scope or account ownership
- `409`: Operation still in progress or prior outcome ambiguous
- `413`: Attachment exceeds 25 MiB
- `503`: Scoped provider unavailable or outcome ambiguous; do not retry

---

[API](https://skmtc.dev/gramclaw/apis/gramclaw-telegram-api.md) · [All operations](https://skmtc.dev/gramclaw/apis/gramclaw-telegram-api/llms.txt) · [OpenAPI document](https://skmtc.dev/gramclaw/apis/gramclaw-telegram-api/revisions/7506dc9c905a?raw)
