Configuration
The Phoenix Java Middleware is configured through theapplication.properties file. This guide covers all available configuration options.
Configuration file location
Depending on how you run the middleware, the configuration file is located at:- Pre-built JAR:
dist/application.properties - Source build:
src/main/resources/application.properties
Required configuration
Server configuration
The port on which the middleware will run. Default is 8081.
Phoenix API credentials
These credentials are provided by Interswitch Uganda when you register for the Phoenix API.Your Phoenix API client ID.
Your Phoenix API client secret. This value is updated after successful client registration.
After completing client registration, a new client secret is issued. You must update this value in the configuration file.
Your terminal identifier.
Cryptographic keys
Your RSA public key in Base64 format. Generate this using the
/isw/auth/generateKeys endpoint or use existing keys.Your RSA private key in Base64 format. Keep this secure and never share it.
Application metadata
Serial ID for your application instance.
API version to use.
Application password for authentication.
Phoenix API endpoints
The base URL for Phoenix API operations.
The base URL for biller-related operations.
The URLs shown above are for the development/sandbox environment. Use production URLs when deploying to production.
Complete configuration example
Here’s a complete example of theapplication.properties file:
Configuration steps
Obtain credentials
Register with Interswitch Uganda to receive your Phoenix API credentials including client ID, terminal ID, and access to the API environments.
Register client
After starting the middleware, register your client using the
/isw/auth/registerClient endpoint. This will issue a new client secret.Update client secret
Update the
app.client_secret value in application.properties with the new secret from the registration response.Environment-specific configuration
For different environments (development, staging, production), maintain separate configuration files:Security best practices
- Never commit
application.propertieswith real credentials to version control - Use environment variables or secret management tools for production deployments
- Rotate keys regularly and update the client secret after registration
- Restrict access to the configuration file using file system permissions
- Use HTTPS when deploying the middleware to production
Next steps
Authentication
Learn about the authentication flow
Client registration
Register your client with Phoenix API