OptionaladditionalExtra properties merged into every analytics event the SDK sends.
A flat object — use it to tag events with your own identifiers. More properties can be added
later with enrichAnalytics(). A plan property here
is also forwarded to the Agents API as end-user data when a Talks (V2) or Clips (V3) stream
is created.
OptionalenabledWhether the SDK reports usage analytics at all. Set it to false to send nothing.
OptionalmixpanelMixpanel project token the SDK's analytics events are sent to.
Defaults to D-ID's own project. Set it to send the SDK's events to your Mixpanel project instead.
What the SDK reports about the session, and where it goes.
Pass it as AgentManagerOptions.analytics; every field is optional, and leaving the whole object out reports to D-ID's own project.
The SDK posts an event to Mixpanel for each step of a session — connect, reconnect and disconnect, every message sent and answered, every speak(), mode change, rating, feedback, tool call, video start and stop, interrupt and error. Each event carries the agent id, the visitor id derived from externalId, the page URL, the screen size, the user agent, the SDK version and whatever additionalProperties added. Conversation text is included too: the agent's answer on
agent-message-received, and the script onagent-speak. Set enabled: false to send nothing at all.Events that fail to post are buffered in memory (at most 50) and retried when the tab comes back online or becomes visible.
Example: Send the SDK's events to your own project, tagged with your plan