Iteratively works best when integrated into your CI workflow, running continuously alongside your test suite. We integrate with all common CI providers and can be configured for custom environments.
Once you've added Iteratively to your CI environment, Iteratively will verify your analytics against every build.
Iteratively checks your analytics implementation against the tracking plan version that's currently checked in. If your team made changes to your tracking plan since the last call to
ampli pull, those changes will not cause a failure in CI.
Create an API token in your account or set up another account to be used for CI. Ampli will use this token for authentication when running inside CI to update your tracking plan's implementation status.
Keep your token secret. Your token has global permissions on your account.
Create an environment variable in your CI service called
ITLY_KEY and set it to the API token you created in Step 1. You'll use this environment variable to pass the token to
ampli status when it runs inside CI.
For example, this is how it would work in Netlify.
Read the documentation for your CI service to get step-by-step instructions:
By now, you've run
ampli pull and
ampli status in your project's root folder. The folder contains an
ampli.json file with metadatata about the current state of the Itly SDK in your project. When you run
ampli status, on your local machine or soon in CI, Ampli will verify your analytics against this file.
To install Ampli locally, run
npm install @amplitude/ampli -D.
To integrate Ampli with your CI system, modify your CI configuration to run
ampli status as part of the build process. We've made it easy by creating Docker Containers that you can use which include dependencies. Some runtimes have their own containers:
amplitudeinc/ampli-all(for convenience this contains everything but is larger in size)
The following examples are for Bitbucket Pipelines but you can use the same images in any CI system that supports containers.
- .NET C#
The ampli image can be used to verify the following SDK runtimes.
- python (2 & 3)
The ampli-swift image can be used to verify Swift runtimes.
The ampli-dotnet image can be used to verify .NET C#.
The ampli-ruby image can be used to verify Ruby.
You should now have Ampli running inside your CI system. Congratulations!