Skip to main content
POST
/
tickets
/
{ticketId}
/
messages
curl -X POST https://teambattles.gg/api/v1/tickets/TICKET_ID/messages \
  -H "Authorization: Bearer tb_your_api_key" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: 9f1c2b3a-reply-1" \
  -d '{"content":"Still seeing the issue after a retry - here is a screenshot."}'
{
  "success": true,
  "messageId": "<string>",
  "timestamp": "<string>"
}

Permission Required

This endpoint requires tickets.write:write on your API key, plus the writes feature. The sender is always the API key owner, derived from the key itself - it is never accepted as a body field. A free (api_free) key receives 403 error_api_feature_required; this requires an api_pro+ plan.

Access / Membership Rules

Tickets are owner-scoped (binding: "none"). You may reply only on a ticket you own. The gate is re-enforced inside Convex: a non-existent ticket returns 404 TICKET_NOT_FOUND, a ticket you cannot write returns 403 TICKET_ACCESS_DENIED, and a closed ticket returns 400. Image and length limits are re-checked server-side. The route supports the Idempotency-Key header. Supplying one makes a retried reply safe - the same key and request body returns the original result rather than posting a duplicate message.

What’s Returned

Returns an object with success: true, the created messageId, and a timestamp. Mintlify renders the full schema from the spec below.

Request Body

FieldTypeRequiredDescription
contentstringYesReply message body (1-2000 chars).
imagesstring[]NoStorage IDs from the image upload endpoint to attach (max 10).
curl -X POST https://teambattles.gg/api/v1/tickets/TICKET_ID/messages \
  -H "Authorization: Bearer tb_your_api_key" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: 9f1c2b3a-reply-1" \
  -d '{"content":"Still seeing the issue after a retry - here is a screenshot."}'

Authorizations

Authorization
string
header
required

Send your API key as: Authorization: Bearer tb_

Path Parameters

ticketId
string
required

Ticket ID.

Body

application/json

Adds a reply message to one of the API key owner's tickets.

content
string
required

Reply message body (max 2000 chars).

Required string length: 1 - 2000
images
string[]

Optional storage IDs (from /uploads/image-url) to attach (max 10).

Maximum array length: 10

Response

The reply was added.

success
boolean
required
messageId
string
required

Created message ID.

timestamp
string
required

Response generation time (ISO 8601).