Pass id (the Customer UUID) and externalUserId so a user gets the same experiment variation everywhere.
setAttributes() replaces all attributes; keep these two fields on every update.
Backends can read and evaluate with getFeatures or evaluateFeatures (features:read).
Track events
track(name, properties) records a behavior event and flush() sends it. Experiment exposures and Feature usage are recorded automatically; each kind can be turned on or off per environment in Console.
Website experiments
Load URL redirect and visual experiments on your pages without a credential. Copy the environment UUID from the experiment pages in Console.
experiments.tsTypeScript
1import { createPageExperiments } from"@tinkerlandai/indiana-sdk/page";2import { createVisualExperiments } from"@tinkerlandai/indiana-sdk/visual";34// The environment UUID is public; it selects published experiments and authenticates nothing.5const redirects = createPageExperiments({ environmentId: "<ENVIRONMENT_UUID>" });6const visual = createVisualExperiments({ environmentId: "<ENVIRONMENT_UUID>" });78exportasyncfunctionstartExperiments() {9awaitPromise.all([redirects.start(), visual.start()]);10}