- KB API Business portal
- KB API Developer portal
- KB ADAA API Java SDK
- KB Client Registration API Java SDK
- ADAA API technical manual (for production version)
- ADAA API technical manual (for sandbox version)
This Java web application serves as a reference example or an inspiration for developers who want to develop software based on the KB ADAA API. This example is based on the JAX-RS Jersey implementation.
For more examples check our Github repository.
- Complete application properties located
in the
./service/src/main/resources/application.properties
file:x-api-key
- authorization API key generated at KB API Developer portalclient-registration-uri
- URI of the page of the KB Client Registration pagesoftware-statement-uri
- URI of the endpoint of the KB Client Registration API for getting software statementadaa-uri
- URI of the KB ADAA APIauthorization-uri
- URI of the page of the KB Authorization server for getting OAuth2 authorization codeaccess-token-uri
- URI of the endpoint of the KB OAuth2 API for getting access tokensecret
- Base64 encoded 256-bit key that used during getting client registration processkeystore-location
- path to the keystore with client certificatekeystore-password
- password of the keystore with client certificateclient-cert-password
- password of the client certificate
- Build this project with Maven.
and then run the embedded Jetty server using command:
mvn clean install
mvn jetty:run -pl web
- Or you can deploy a built
war
file to your own instance of the application server.
KB ADAA API authorization process is based on the OAuth 2.0 specification. To call KB ADAA API and get user's transaction history you must complete following steps:
- Registration of the application's instance
- user grants access
- gets software statement by calling
SoftwareStatementsApi#softwareStatement(SoftwareStatementRequest req)
using KB Client Registration API Java SDK - redirects user to the KB login page for authentication
- after success authentication KB SAML server will send response with an encrypted client ID and a client secret to
/register/client
application endpoint. Application decrypts client's registration data and store them to the further usage
- OAuth2 authorization process
- redirects user to KB OAuth2 authorization page. After user grant access, KB authorization server
will send a redirect response with authorization code back to the application's endpoint
/oauth2/authorize
- application calls KB OAuth2 API to get access token
- redirects user to KB OAuth2 authorization page. After user grant access, KB authorization server
will send a redirect response with authorization code back to the application's endpoint
- Call KB ADAA API
- application call KB ADAA API for user's transaction history and account balance
- return HTML page with displayed transaction history and account balance to the user
The whole flow of this application is described by sequence diagram below:
For further details please read ADAA API technical manual (for production version) or ADAA API technical manual (for sandbox version).
If you still have any questions please contact a KB API support team.