sendMessage method

Future<XRPCResponse<MessageView>> sendMessage({
  1. required String convoId,
  2. required MessageInput message,
  3. Map<String, String>? $unknown,
  4. Map<String, String>? $headers,
  5. PostClient? $client,
})

Implementation

Future<XRPCResponse<MessageView>> sendMessage({
  required String convoId,
  required MessageInput message,
  Map<String, String>? $unknown,
  Map<String, String>? $headers,
  PostClient? $client,
}) async =>
    await _ctx.post<MessageView>(
      ns.chatBskyConvoSendMessage,
      headers: $headers,
      body: {
        'convoId': convoId,
        'message': message.toJson(),
        ...?$unknown,
      },
      to: const MessageViewConverter().fromJson,
      client: $client,
    );