Skip to content
Dashboard
Open .md fileOpen llms.txtA list of every page, for AI tools

Guides

Page context

Tell agents and triage where the contact is in your product: the plan, the cart, the current order.

Call Iris.setPageContext when the page loads, and again when the facts change. Each call replaces the earlier page context. Iris keeps only the latest one for the conversation, and adds the page url and title itself.

app.js
Iris.setPageContext({
plan: "pro",
cartTotal: 42.5,
beta: true,
coupon: null,
});
  • A flat object: no nested objects or arrays.
  • Up to 48 of your own keys. Iris adds url and title, 50 in all. A key has up to 64 characters.
  • Each value is a string of up to 500 characters, a number, a boolean or null.

Every limit is also in Iris.setPageContext.