Admin API / Types

PostChatMessageInput

Input

The message to post and the idempotency key.

input PostChatMessageInput

Input fields

FieldTypeDescription
chatChannelIdID!The ID of a channel that the caller can read (ChatChannel.viewer.canRead).
idempotencyKeyString!A client-generated key, 1 to 200 characters after trim. A repeat with the same key and input within 24 hours returns the first message and posts no second message. The same key with another input returns IdempotencyConflictError.
mentionEveryoneBooleanNotifies every member of the channel. True requires the MODERATOR role or higher. Default: false.
mentionedUserIds[ID!]Members to mention, each at most once and at most 100. A member whose ID is a token in text is mentioned at that token. The mentions of the other members go before text, in input order. A member who blocks the caller, or whom the caller blocks, is not mentioned, and the post continues.
replyToMessageIdIDThe message to reply to: a message of the same channel that is not deleted.
textNonEmptyString!Plain text. Leading and trailing spaces are removed, and the server escapes markup, so <b> shows as text. Text of only spaces fails the NonEmptyString input check. A token @ and the ID of a member in mentionedUserIds, such as Congratulations @user_C3Sb…, is the mention of that member at that place. The ID must be the whole word, in the same letter case. A token of a member that is not in mentionedUserIds stays text and notifies nobody.