Use a browser-safe public key, authorize your exact or wildcard domains, and choose avatar mode, text mode, or both. Your private AI brain remains behind Atina's gateway.
3D avatar:
https://atina.comfylearnhub.com/atina-embed/assets/index-bc07bc84.js
Text SDK:
https://atina.comfylearnhub.com/atina-embed-sdk/atina-sdk.js
public_key is required. The SDK sends it with the browser origin to create a temporary session token after your domain is validated. You can also pass friendly defaults that shape the first visitor experience.
<script>
window.ATINA_CONTEXT = {
public_key: "atina_pk_live_your_public_key",
external_user_id: "optional-user-id-from-your-app",
mode: "text"
};
</script>
Use window.AtinaSDK.configure() or new Atina() after the SDK loads to customize these runtime settings.
mode
Default: avatar
Sets the first view. Use text for support chat, avatar for a guided 3D experience, then switch later with setMode() or toggleMode().
recommendations
Default: general sample prompts
Adds clickable prompt chips in text mode. Make these specific to your page, such as product discovery, booking questions, lesson help, or support shortcuts.
otherelementsIDForAvatar
Default: []
DOM element IDs to show when avatar mode is active. Useful when a page has controls, galleries, or notes that only make sense beside the avatar.
otherelementsIDForText
Default: []
DOM element IDs to show when text mode is active. Commonly used for chat history, transcript panels, or compact support widgets.
idleTimeout
Default: 30000
Milliseconds of inactivity before Atina can treat the session as idle. Increase it for long reading pages; reduce it for hands-on demos or training flows.
uploadEnabled
Default: true
Shows or hides the context-file upload action in text mode. Turn it off for simple lead capture, product browsing, or pages that should not accept files.
interactionSignals
Default: enabled
Tunes lightweight engagement detection, confidence thresholds, cooldowns, throttling, and whether interaction signals are sent with chat requests.
<div id="atina-root" style="height: 620px"></div>
<link rel="stylesheet" href="https://atina.comfylearnhub.com/atina-embed/assets/index-5b0ac9c0.css">
<script type="module" src="https://atina.comfylearnhub.com/atina-embed/assets/index-bc07bc84.js"></script>
<div id="atina-text-root"></div>
<div class="my-atina-history"></div>
<link rel="stylesheet" href="https://atina.comfylearnhub.com/atina-embed-sdk/atina-sdk.css">
<script src="https://atina.comfylearnhub.com/atina-embed-sdk/atina-sdk.js"></script>
<script>
window.AtinaEvents.registerCallbacks([
function (event) {
console.log("Atina conversation updated", event.conversation_id);
}
]);
window.AtinaSDK.mountChatHistory(".my-atina-history");
</script>
The SDK starts in window.ATINA_CONTEXT.mode when provided. You can also switch modes from your own button or menu.
<button id="atinaModeToggle">Toggle Atina Mode</button>
<button onclick="window.AtinaSDK.setMode('text')">Text</button>
<button onclick="window.AtinaSDK.setMode('avatar')">Avatar</button>
<script>
document.getElementById("atinaModeToggle").addEventListener("click", function () {
window.AtinaSDK.toggleMode();
});
</script>
After creating an embed app, open the Atina dashboard and add the capabilities this deployment needs. The same public key can power avatar mode or text mode; the agent behavior comes from the app/domain configuration behind the gateway.
Product feeds must be served over HTTPS and return JSON. Atina accepts either a top-level array or an object containing products or items.
{
"products": [
{
"id": "shoe-blue-42",
"title": "Blue Running Shoes",
"description": "Lightweight running shoes for daily training.",
"category": "Shoes",
"price": 89.99,
"currency": "USD",
"availability": "in_stock",
"url": "https://example.com/products/blue-running-shoes"
}
]
}
When Atina answers with a product URL, the SDK turns the full https://... URL into a clickable link in text mode and conversation history.
Live tools are read-only HTTPS GET endpoints. Atina calls the endpoint with q and keyword query parameters containing the visitor request. Optional JSON headers can be configured in the dashboard.
GET https://example.com/api/atina/product-status?q=blue%20running%20shoes
Response:
{
"status": "in_stock",
"title": "Blue Running Shoes",
"price": 89.99,
"currency": "USD",
"link": "https://example.com/products/blue-running-shoes"
}
Return only data Atina is allowed to use. Do not expose private database credentials, admin endpoints, or write actions from browser-facing embed deployments.
atina_pk_live_ public keys.Choose your frontend, copy or download the starter, then replace atina_pk_live_your_public_key with your own public key and the sample recommendation prompts with content that matches your page.
Paste your public key, choose a mode, and try the CDN setup from this page. Without a valid key and authorized domain, the widget loads but requests are rejected.
Atina App
Install Atina for a focused, full-screen experience with faster access to your AI assistant.
No download store. No extra sign in.