Airgram

Guides
/
/
Methods

api.setChatDraftMessage()

Changes the draft message in a chat

Parameters SetChatDraftMessageParams:

NameTypeDescription
chatIdnumber Chat identifier
messageThreadIdnumber If not 0, a message thread identifier in which the draft was changed
draftMessage New draft message; pass null to remove the draft
Returns ApiResponse interface:
interface ApiResponse {
  _: 'setChatDraftMessage' | 'error'
  airgram: Airgram
  request: {
    method: 'setChatDraftMessage'
    params: SetChatDraftMessageParams
  }
  response:  | 
  setState: (nextState: Record<string, unknown>) => void
  getState: () => Record<string, unknown>
}