Enterprise customers can use User API Keys to programmatically query their Remark data via the GraphQL API. This covers dashboard statistics, conversation history, smart tags, order data, and more.Documentation Index
Fetch the complete documentation index at: https://docs.remark.ai/llms.txt
Use this file to discover all available pages before exploring further.
Authentication
Create and use API keys to authenticate requests.
Dashboard Statistics
Query chat volume, revenue, conversion rates, and leaderboards.
Conversations
List conversations, fetch details, and inspect associated customer events.
Smart Tags
Aggregate smart tag counts across conversations.
Authentication
Creating an API Key
Using the API Key
All requests go to the GraphQL endpoint:Authorization header:
Example Request
Dashboard Statistics
The main analytics entry point. All stats are nested undervendorById > conversationAggregateStatistics and support filtering by date range and optionally by channel.
Permission required: VIEW_CONVERSIONS (for revenue/conversion fields)
All-in-One Dashboard Query
Fetches the most commonly used KPIs in a single request:Variables
| Variable | Type | Required | Description |
|---|---|---|---|
vendorId | ID! | Yes | Your vendor ID |
start | DateTime! | Yes | Period start (ISO 8601) |
end | DateTime! | Yes | Period end (ISO 8601) |
timezone | String! | Yes | IANA timezone for time series (e.g. "America/New_York") |
channel | ConversationChannel | No | Filter by channel: RemarkChat, GorgiasTicket, ZendeskTicket, KustomerConversation |
Example Response
Field Reference
Field Reference
| Field | Description |
|---|---|
numberOfChats | Total conversations in period |
numberOfAIChats | Conversations handled entirely by AI |
numberOfHumanChats | Conversations involving a human expert |
automationRate | Fraction of chats handled by AI (0–1) |
totalValueOfConversationsAttributedToChat | Total revenue attributed to chat interactions (USD) |
totalValueOfConversationsAttributedToHumanChat | Revenue attributed to human-handled chats |
totalValueOfConversationsAttributedToAIChat | Revenue attributed to AI-handled chats |
numberOfConversionsAttributed | Number of orders attributed to chat |
conversionRateForChatters | Conversion rate for visitors who chatted |
conversionRateForNonChatters | Conversion rate for visitors who did not chat |
aovForChatters | Average order value for chatters (USD) |
aovForNonChatters | Average order value for non-chatters (USD) |
aovForAttributedConversions | AOV for orders directly attributed to chat |
aovForNonAttributedConversions | AOV for non-attributed orders |
averageExpertResponseTime | Average expert response time (seconds) |
medianJoinTime | Median time for an expert to join a chat (seconds) |
totalManHoursSpentInChat | Total expert hours spent in chat |
attributedRevenueTimeSeries | Revenue over time, bucketed by day/week/month |
chatsByHourHistogram | Chat volume by hour of day |
chatsByDayOfWeekHistogram | Chat volume by day of week |
topProductsByAttributedSales | Products ranked by attributed revenue |
topExpertByAttributedSales | Single top expert by revenue |
topExperts | Experts ranked by chat count |
topCitedKnowledge | Most-referenced knowledge documents |
minutesSavedByRemark | Estimated minutes saved by AI automation |
csatScore | Average CSAT score (requires VIEW_NPS) |
Period-over-Period Comparison
Use GraphQL aliases to fetch current and previous periods in one request:Smart Tag Aggregation
Count how often each smart tag was applied to conversations in a time range. Useful for tracking trending topics, common customer issues, or product interest over time.Permission required: VIEW_CONVERSATIONS
Count Tags in a Period
Example Response
List Available Smart Tags
Conversation Listing
Paginated list of conversations with filtering and sorting. Uses cursor-based pagination.Permission required: VIEW_CONVERSATIONS
Variables
| Variable | Type | Required | Description |
|---|---|---|---|
vendorId | ID! | Yes | Your vendor ID |
first | Int | No | Page size (default varies) |
cursor | ID | No | Cursor from previous page’s endCursor |
sort | [ConversationSortInput!] | No | Sort criteria. For stable pagination, pass [{ field: created, direction: desc }]. |
filter | [ConversationFilterInput!] | No | Filter criteria |
Filter Options
| Filter Key | Type | Description |
|---|---|---|
expertId | ID | Filter by assigned expert |
email | String | Search by customer email |
conversionStatus | Enum | Attributed, Converted, None |
smartTagIds | [ID] | Filter by smart tag IDs |
npsRating | Enum | Positive, Negative |
sentiment | Enum | AI-inferred sentiment |
expertChatType | Enum | AI, Human, Both, HasAI, HasHuman |
channels | [ConversationChannel] | Filter by channel type |
Sort Options
| Field | Direction |
|---|---|
created | desc (newest conversation first) or asc. Recommended for paginating long result sets. |
lastMessageDate | desc (most recently active first) or asc. Used when no sort is supplied. |
For exports, backfills, and other long pagination jobs, explicitly sort by
created. The default sort is lastMessageDate, which can change when an
older conversation receives a new message and may make cursor pagination less
stable over time.Recommended Variables
Pagination
Use cursor-based pagination to iterate through results:Conversation Detail
Fetch a single conversation with its full message history.Permission required: VIEW_CONVERSATIONS
Conversation Customer Events
UsecustomerEvent to fetch the browsing and shopping events associated with a
conversation’s session. This is the right place to look for product views,
category page views, searches, and cart activity that happened around a chat.
Permission required: VIEW_CONVERSATIONS
Event Types
| Type | Meaning | Useful fields |
|---|---|---|
ProductPageView | Shopper viewed a product detail page | product.id, product.externalId, product.name, product.brandName, product.externalUrl |
CategoryPageView | Shopper viewed a category or collection page | name |
PageView | Shopper viewed a non-product page | created, type |
Search | Shopper searched the site | search |
CartAdd / CartRemove | Shopper changed their cart | product, cart |
Session & Order Data
Look up browsing sessions and conversion/order details for a customer.Permission required: VIEW_CONVERSIONS
Key Fields
| Field | Description |
|---|---|
totalPrice | Order total |
attributionMethod | How the conversion was attributed to chat |
attribution.chattingExpert | The expert credited with the sale |
lineItems | Individual products/variants in the order |
Permissions Reference
Your API key inherits the permissions of the user who created it. Different data requires different permissions:| Permission | Grants access to |
|---|---|
| VIEW_CONVERSATIONS | Conversation data, smart tags, message history, chat analysis |
| VIEW_CONVERSIONS | Revenue metrics, conversion rates, order details, attributed sales |
| VIEW_PII | Customer emails, names, IP addresses, contact info |
| VIEW_NPS | NPS/CSAT scores and survey details |
| VIEW_BILLING | Billing and payment data |
| EDIT_ANALYTICS | Smart tag management (create/edit/delete) |
Rate Limits & Best Practices
- Rate limiting: Rate limits may be enforced to prevent abuse and maintain quality of service
- Request only what you need: GraphQL lets you select specific fields — smaller queries are faster
- Use pagination: Always paginate conversation and session lists rather than fetching everything at once
- Cache where appropriate: Dashboard statistics don’t change in real time; polling every few minutes is sufficient
- Time ranges: Always provide
start/endfor dashboard stats queries — omitting them returns lifetime data which is slower - Timezone: Pass your local IANA timezone (e.g.
America/New_York) for time series and histogram queries to get correctly bucketed data