How to manage the dev and live environments with Batch?
Here are the best practices to manage both environments.
How to manage the dev and live environments with Batch?
A staging environment refers to a parallel server environment for testing websites and software applications in conditions as close as possible to the live environment, without compromising the organization's current data or interrupting its operations.
You should always integrate Batch in a development environment and then go into production mode after everything has been tested and validated.
For this matter, we strongly recommend:
Creating two applications per OS (Android, iOS, Web) on the dashboard: one for tests and one for production (e.g. MyApp and [DEV] MyApp).
These apps will then be grouped into two Omnichannel projects.
For instance:
![Screenshot of the Batch dashboard showing two omnichannel projects in a dropdown menu ("The Store" and "[DEV] The Store")](https://doc.batch.com/~gitbook/image?url=https%3A%2F%2F38998153-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FCL8wF0y1T2vLnm3yR2MW%252Fuploads%252FOnWV8i5ojTdvaTjdadTQ%252Ftechnical-guides_dev-live-env_02052025.png%3Falt%3Dmedia%26token%3D3b9efe5c-9054-44d9-b737-e5ed994ece61&width=768&dpr=3&quality=100&sign=c2940f5cc070f2f334cdd61770a7088e&sv=3)
Avoid using the Dev API key on production projects. The Dev API key (its value starts with DEV) is meant for development and testing only. Using it in production has several drawbacks:
Your stats will be inaccurate. Batch does not compute analytics for the Dev API key, so any campaign or traffic sent with it is ignored in your KPIs (delivery, open and click rates, etc.).
Deliverability can suffer. Dev traffic is not treated as production traffic and can be rate-limited by push providers such as FCM or APNs, which may throttle or drop your notifications.
It pollutes your production data. Mixing Dev installs and tokens into a production app makes your audiences and targeting unreliable.
Always ship your production app with the Live API key, and reserve the Dev API key for a dedicated development app or project.
Last updated

