chat8 ops

Chat API

In-app messaging between accounts and threaded conversations.

Queries

QUERY

messages

Deprecated#

Deprecation reason: Use messagesPage(threadId, pagination); legacy list retires through BET-204

Arguments

  • threadId!
  • limitInt!

    Default

    50
  • offsetInt!

    Default

    0
Returns[!]!
QUERY

messagesPage

#

Paginated messages. Authorization is completed before reading the total.

Arguments

  • threadId!
  • pagination
Returns!
QUERY

myChatThread

#

One conversation of mine, by id. myChatThreads was the only place a non-admin could read a thread's lock state, topic and counterparties, so a client opening a single conversation had to page the list and search it — both service apps scanned the first 100 rows. Past that the header fell back to a role name and the lock stopped being read, leaving the composer up on a closed thread until the send was refused. None when the caller is not a participant, which is the same answer as "no such thread" on purpose: a thread's existence is not something to confirm to someone who is not in it.

Arguments

  • threadId!
Returns
QUERY

myChatThreads

Deprecated#

My conversations, newest activity first. Three queries regardless of page size: my participant rows, the threads they point at, and the other participants of those threads.

Deprecation reason: Use myChatThreadsPage(activeOnly, pagination); legacy list retires through BET-204

Arguments

  • activeOnlyBoolean!

    Default

    true
  • limitInt!

    Default

    50
  • offsetInt!

    Default

    0
Returns[!]!
QUERY

myChatThreadsPage

#

Conversations with standard pagination metadata.

Arguments

  • activeOnlyBoolean!

    Default

    true
  • pagination
Returns!
QUERY

orderChatMessages

#

Fetch all chat messages for a specific order. # Authorization Requires TenantAdmin or PlatformAdmin role. # Arguments * order_id - The order ID to fetch messages for # Returns List of chat messages associated with the order's chat thread. Returns empty list if no chat thread exists for the order.

Arguments

  • orderId!
Returns[!]!

Mutations

MUTATION

markAsRead

#

Arguments

  • input!
ReturnsBoolean!
MUTATION

sendMessage

#

Arguments

  • input!
Returns!