Addons for frameworks
Springboot
Source files on Github
How to use
To use this library add the jar to your project libraries (it will be added to maven when possible)
There are two ways to configure keys and secrets:
-
By providing your own configuration class like this
-
or simply adding by these properties on application.properties file
then to make a payment simply inject the ChargilyClient in your service
either by constructor or field injection like this (constructor injection is preferred, but I will use field injection just for demo)
Here’s a demo