⚡ Add this skill
One command
Add the Autoplay Amplitude session replay provider skill for an existing Amplitude setup.View the docs →
Agent onboarding
Fetch this skill when a customer already uses Amplitude as a session replay provider and wants Autoplay live user activity.View the skill →
- API Key — already in your
amplitude.initAll()call (Step 2 below). Find it under Settings → Projects → [Your Project] → General if you need to re-verify it. - Project ID — links your Amplitude project to your Autoplay
product_id(Settings → Projects → select your project → Project ID; used in Step 4).
🎯 Step 1 — Verify the existing Amplitude SDK
Confirm your app already has@amplitude/unified installed with Analytics and Session Replay enabled — this is the one that bundles both in one package, which Autoplay needs (Session Replay lets Autoplay correlate what users actually did on screen with your support AI agent conversations). If you’re on the older @amplitude/analytics-browser package instead, that’s a migration decision — see Amplitude’s browser SDK docs.
Don’t have it installed yet? Run this in your frontend app’s directory:
💻 Step 2 — Verify initialization and autocapture
Your app should already callamplitude.initAll() once at startup (main.ts, _app.tsx, or root layout) — see Amplitude’s browser SDK docs for the general init pattern and where to find your API key if you need to check it.
📺 Copy your Amplitude API key
Confirm your existing
initAll() call has autocapture: true set — this is the one setting Autoplay actually requires:
👤 Step 3 — Identify on login (required for session scoping)
Add this to your auth/login handler — wherever your app handles a successful login.setUserId is the key step: it stamps every event with a stable user_id, and the connector keys a user’s activity under exactly that id — the same one your agent will look them up by.
About session IDs: Amplitude assigns each session a numeric Unix-millisecond timestamp as its ID. The connector converts it to a string automatically. If
session_id is -1 in very early events, the connector falls back to device_id until the session resolves (a few seconds).📝 Step 4 — Register your product with Autoplay
Now that your app is capturing events, we need to create a secure “ingest_url” and a shared secret (ingest_secret) so that data can be safely sent to Autoplay.
📺 How to find your Amplitude Project ID
The
autoplay-sdk was installed on the Quickstart page. Create a Python file with the script below, replace the placeholders with your values, and run it once:
- product_id:
YOUR_AMPLITUDE_PROJECT_ID - provider:
amplitude - ingest_url:
https://connector.autoplay.ai/ingest/YOUR_AMPLITUDE_PROJECT_ID - ingest_secret:
{secret}— Amplitude sends this asAuthorization: Bearer <ingest_secret> - mcp_url:
https://mcp.autoplay.ai/mcp - mcp_key:
{secret}— your agent’s Bearer token
ingest_url and ingest_secret in Step 5 below, and mcp_key when you connect your AI support agent.
Re-registering your productA second
onboard_product with the same product_id returns 409 until overwrite is allowed. Pass force=True to overwrite. You must still pass contact_email on every registration, including overwrites.⚙️ Step 5 — Create the event streaming destination in Amplitude
You’ll need two values printed by Step 4:- URL:
ingest_url(e.g.https://connector.autoplay.ai/ingest/YOUR_AMPLITUDE_PROJECT_ID) - Bearer token:
ingest_secret
Amplitude uses a developer portal to create custom event streaming destinations. Opening the destination builder (Data → Destinations → + Add Destination → search “HTTP” → Event Streaming) is standard Amplitude navigation — see Amplitude’s HTTP destination docs if you need the general walkthrough. The Autoplay-specific part is what you configure once you’re there:
Fill in the Configuration tab
Integration Name — give the destination a name, e.g.
autoplay-connector.
URL Endpoint
Create Parameters — click “Add New Parameter” and add:
REST API Headers — click “Add New REST API Header” and set:
Event Body Editor — replace the default Freemarker template with:
Amplitude destination — Freemarker event body template (expand to copy)
Amplitude destination — Freemarker event body template (expand to copy)
This template does two things the default Amplitude template does not:1. Event type normalisation — Amplitude’s autocapture sends events with names like
[Amplitude] Page Viewed and [Amplitude] Element Clicked. The Autoplay connector needs these mapped to standard names it recognises. The template does that automatically:2. Field mapping — Amplitude stores click details (element text, URL, element path) under its own field names. The template copies them into the fields Autoplay expects so it can generate human-readable descriptions like “User clicked Sign Up button on the dashboard page”.Without this template, only page views appear in the Autoplay stream — clicks and form events are silently ignored.
200 OK, then Release to publish the destination. Finally, back in Data → Destinations, open your published destination and Add New Sync to activate it — standard Amplitude steps, not Autoplay-specific.
The sync is now active. Amplitude will stream all events to your connector endpoint in real time.
👋 Quick Tip: Once you add this code to your site, jump into our Discord and say hi — we will check your data is flowing and help you get fully set up!
🔌 Next: connect your AI support agent
Your activity is now flowing into the connector. Head back to Quickstart to choose your existing AI support agent and connect it via MCP — it then pulls a user’s live activity on demand, the moment it needs context to answer.Choose your AI support agent
Fin (Intercom), Maven, Ada, Botpress, and more — pick yours and connect via MCP.