Developer integration
Private page context
Private page context gives a rep or AI Stand-in facts and instructions from the host page without presenting that context as something the visitor typed.
- Availability
- All plans
- Configured in
- Website HTML → prompt on stand-button or stand-card; or website JavaScript → StandChat.openChat(..., { prompt })
- Category
- Developer integration
- Reference status
- Current
Before you begin
Plan availability: All plans through supported Stand entry points.
Prerequisite: An installed widget and a Stand button, card, or API call that creates the conversation.
Key boundary: Context applies only when a new session is created, from the latest open before the visitor’s first message. It is retained for authorized reps and can inform visitor-visible replies; it must not contain secrets.
What private page context is
A page often knows why a visitor is opening chat: the plan they are comparing, the form they are completing, the product they selected, or the kind of interview the team wants the Stand-in to conduct. A prompt sends that context into the new Stand session without adding a visitor-authored message.
An AI Stand-in uses the prompt as session-specific guidance alongside team, site, and Stand-in instructions. A human rep can inspect it in the authenticated conversation view and History. The visitor does not see it in the public transcript.
Private means hidden from the visitor interface—not transient, encrypted for a special recipient, or exempt from conversation retention.
Supply context from a supported entry point
<stand-button
hidden
message="I can help compare plans. What would you like to know?"
prompt="The visitor opened chat from the pricing comparison. Answer plan questions directly. Ask about team size or chat volume only when missing context is needed for a personalized recommendation."
>
Ask about plans
</stand-button>The message is visible to the visitor. The prompt is responder context.
| Entry point | How to supply it | When it is attached |
|---|---|---|
| Stand button | Add a prompt attribute to <stand-button>. | When the session is created, if that button was the last chat opened before the visitor’s first message. |
| Stand card | Add a prompt attribute to <stand-card>. | When the session is created, if the card’s marked action was the last chat opened before the visitor’s first message. |
| JavaScript API | Use the third string argument to openChat(...) or options.prompt. | When the session is created, if that API request was the last chat opened before the visitor’s first message. |
How Stand uses and stores it
- Stand attaches the prompt when it creates the session. Until the visitor sends a first message, each new open replaces the unsent prompt, and an open without one, such as the floating launcher, clears it.
- For AI conversations, the prompt supplies facts and task guidance but does not become a visitor turn or determine the visitor’s language.
- For human conversations, authorized reps can read the context so they understand the page-specific intent.
- The context remains associated with the conversation according to the organization’s retention settings.
- The visitor’s actual form or textarea text should be sent separately as
visitorMessagewhen it is meant to appear in the transcript.
Write context that changes the response
- State the page or workflow the visitor came from and any already-known selections.
- Answer what the supplied facts can establish. Ask for clarification only when missing information prevents an accurate answer or recommendation.
- Separate facts from instructions: for example, “Selected plan: Pro. Explain known plan differences directly; ask only for missing details needed to recommend a plan.”
- Keep it specific to this activation. Reusable organization policy belongs in team, site, or Stand-in instructions.
- Do not claim facts the page cannot actually know or use prompt text as a substitute for authorization checks.
Visibility and privacy boundary
| Surface | What happens |
|---|---|
| Visitor chat | The prompt is not rendered as a visitor message. |
| AI Stand-in | It is supplied as private session context for the response. |
| Live rep and History | Authorized team members can inspect the retained context with the conversation. |
| Public page source | Literal prompt attributes are part of the website HTML and can be inspected by a visitor. Generate dynamic values accordingly. |
Timing and limitations
- Context applies to the session created after the latest activating button, card, or API request; it does not rewrite an already active conversation.
- It cannot authenticate the visitor or grant permission to reveal account-specific information.
- It does not replace knowledge sources for reusable product documentation or team instructions for organization-wide behavior.
- It does not appear as evidence that the visitor personally said or confirmed the supplied facts.