Environments
ChainIT provides two fully isolated environments: Sandbox and Production. This separation ensures that development, testing, and experimentation activities are completely decoupled from live business operations. Changes made in Sandbox — including created accounts, submitted transactions, or registered webhooks — have no effect on Production systems, and vice versa.
Your Active Environment
Your current documentation environment is configured to use:
- API Base URL:
https://staging-api.chainit.online
Sandbox Environment
The Sandbox environment is a fully functional replica of the Production environment, designed exclusively for development and integration testing. All API endpoints, authentication flows, request structures, and response formats are identical to Production, ensuring that code validated in Sandbox behaves identically when deployed against Production.
Sandbox is the required starting point for all new integrations. Use the Sandbox environment to:
- Build and validate new integrations against real API behaviors without risk.
- Test authentication flows, token acquisition, and token refresh logic.
- Verify request construction and response parsing for all endpoints your application will use.
- Simulate error conditions and edge cases to validate your error handling logic.
- Conduct end-to-end workflow testing, including multi-step transaction flows.
- Run automated integration test suites as part of your CI/CD pipeline.
- Onboard and train new developers without risk to production data.
Note: Sandbox data is periodically reset. Do not rely on Sandbox records persisting indefinitely. Design your test suites to create the data they need at the start of each test run.
Production Environment
The Production environment processes live, real-world operations. Every request made to Production endpoints interacts with real financial data, live customer records, and actual transaction infrastructure. Errors in Production may have real business consequences, including failed transactions, compliance violations, or data integrity issues.
Access to Production should be restricted to fully validated integrations that have passed thorough testing in Sandbox. Production credentials must never be used outside of the production-designated deployment environment.
Environment Routing
Routing requests to the correct environment is controlled entirely by the base URL used in your API calls. The path structure, endpoint naming, and all request/response formats are identical between Sandbox and Production — only the hostname differs. Switching environments in your integration requires nothing more than updating the base URL in your configuration.
| Environment | Base URL |
|---|---|
| Sandbox | https://sandbox-api.chainit.com |
| Production | https://api.chainit.com |
Endpoint Structure
All ChainIT API endpoints follow a consistent URL structure regardless of environment:
https://{hostname}/{service}/v1/{resource-path}
Example: Accessing the authentication token endpoint in Sandbox:
https://sandbox-api.chainit.com/oauth/token
The same endpoint in Production:
https://api.chainit.com/oauth/token
URL Component Breakdown
| Component | Example Value | Description | Sandbox Example | Production Example |
|---|---|---|---|---|
| Protocol | https:// | All requests use HTTPS. HTTP is not supported. | https:// | https:// |
| Hostname | api.chainit.com | Determines the target environment. | sandbox-api.chainit.com | api.chainit.com |
| Service Prefix | public-api | Identifies the product service being accessed. | public-api | public-api |
| API Version | v1 | API version for compatibility management. | v1 | v1 |
| Resource Path | auth/token | The specific operation being invoked. | auth/token | auth/token |
Environment Best Practices
To maintain integration quality and security across environments, observe the following practices:
- Always develop and test in Sandbox before deploying any code changes to Production.
- Maintain strictly separate credentials (client ID and secret) for Sandbox and Production. Never use production credentials in test environments.
- Use environment variables or a configuration management system to manage environment-specific settings (base URL, credentials). Never hardcode these values.
- Automate integration testing against Sandbox as part of your CI/CD pipeline to catch regressions before they reach Production.
- Treat Production access credentials with the same security level as financial system credentials — rotate them regularly and restrict access to only those systems and personnel that require them.
- Monitor Production API usage for anomalies. Unexpected traffic patterns or error rate spikes may indicate integration issues or security events.