MIMIC is an open source, self-hosted session replay framework which abstracts away the intricacies of recording and replaying users' sessions on web applications. It is tailored towards user experience improvement and debugging, providing granular insights into application malfunctions in a streamlined and cost-effective manner. With its ready-made telemetry pipeline, MIMIC automates instrumentation and deployment, providing an in depth replay interface that is intuitive and easy to learn.
MIMIC's setup involves two main steps:
- Deploy MIMIC's telemetry pipeline to a host of your choice
- Run MIMIC's command line tool to instrument your application
node
installed, 20.9.0 or greaterpython3
installed, 3.8.0 or greaterpip
installed, the version compatible with yourpython3
versionPostgreSQL
installed, with a userpostgres
and password of your choice- An API token from
https://findip.net/
- Redis cloud database host, port, and password (must be configured for Redis Stack capability)
- AWS S3 Bucket dedicated to this project
- Clone the MIMIC repository to your machine
- Navigate to
./MIMIC/backend
and create the.env
file necessary for MIMIC to work, using the below template:
# .env template
PORT = *** # this is the port your entire MIMIC pipeline will utilize
PSQL_PASSWORD = *** # the password for your PostgreSQL 'postgres' user
POSTGRES_PORT = *** # is 5432 at default
LOCATION_API_TOKEN = *** # your personal API token from https://findip.net/
SECRET = *** # what your JWT login tokens are signed with, UUID recommended
REDIS_PASSWORD = ***
REDIS_HOST = *** # in the format of ***.cloud.redislabs.com
REDIS_PORT = ***
AWS_ACCESS_KEY_ID = ***
AWS_SECRET_ACCESS_KEY = ***
AWS_BUCKET_NAME = ***
- Navigate to
./models
, following the instructions at the top of theinitialize.sql
file to initialize your database - Returning to the backend's root directory, build your MIMIC pipeline with the following:
npm run build:ui
- You can now communicate with both your MIMIC backend and frontend interface with the PORT specified in your
.env
file by running:
npm start
- Before doing this step ensure your MIMIC pipeline is running, otherwise you will be unable to set up MIMIC functionality in your application
- Download our MIMIC installer python package with the following command:
pip install mimic-replay
- In the root folder of your application, run the installer with the command:
python3 -m mimic_replay.install
- Note: if your application is not made up of vanilla HTML files, the installer will not be able to run properly
- To enable MIMIC in these applications, after running the installer, ensure the following two script tags are present in the deployed HTML files:
<script class="mimic" defer src="https://cdn.jsdelivr.net/npm/rrweb@latest/dist/rrweb-all.min.js"></script>
<script class="mimic" defer src="THE/PATH/FROM/THE/FILE/TO/YOUR/PROJECT/ROOT/script.mimic.js"></script>
- Note: trying out MIMIC on a locally hosted application? No sweat! To get a full feel of our features, MIMIC uses the default IP address of
203.190.216.0
, which is located on the remote, tropical island of Nauru
- Want to change the specifics in how MIMIC records the information generated by your application? Feel free to edit the
script.mimic.js
file generated by the MIMIC installer- For example, on line 220, change
maskAllInputs: true,
tomaskAllInputs: false,
to mask only password information, as opposed to all user generated text input
- For example, on line 220, change
- Interested in more customization options? Visit the RRWeb documentation
Louis Mascari • Software Engineer • Knoxville, TN
Lucas Sorribes • Software Engineer • Madrid, Spain
Veronika Todd • Software Engineer • Hartford, CT
Erik Wiens • Software Engineer • New York, NY