chat method

Future<OryksaReply> chat(
  1. String message, {
  2. String? conversationId,
  3. String? customerName,
})

Chat with the AI employee. Reuse conversationId to keep the context.

Implementation

Future<OryksaReply> chat(String message, {String? conversationId, String? customerName}) async =>
    OryksaReply.fromJson(await _req('POST', '/chat', {
      'message': message,
      if (conversationId != null) 'conversation_id': conversationId,
      if (customerName != null) 'customer_name': customerName,
    }));