alangunning / OpenBanking-Java-SDK

A Java SDK to help implementing the Open Banking standard : https://www.openbanking.org.uk/read-write-apis/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Build Status

OpenBanking-Java-SDK

A Java SDK to help implementing the Open Banking standard : https://www.openbanking.org.uk/read-write-apis/ . This project is compiled with JDK 8.

Class generation

Many of the classes are generated from OB Swagger documentation. When a new version of OB API is released, the following steps are performed:

  1. Download the Swagger json files from OB Spec pages (e.g. for 3.1.1 accounts: https://openbanking.atlassian.net/wiki/spaces/DZ/pages/999622968/Account+and+Transaction+API+Specification+-+v3.1.1#AccountandTransactionAPISpecification-v3.1.1-SwaggerSpecification)

Note: there are currently swagger files for Accounts, Payments, Funds Confirmation, ASPSP Callback and TPP Events - more may be available in future releases).

  1. Download swagger-codegen-cli-2.4.5.jar
  2. Run java -jar swagger-codegen-cli-2.4.5.jar generate \ -i {your_json_file} \ -DuseBeanValidation=true \ -Dmodels \ --model-package uk.org.openbanking.datamodel \ --group-id com.forgerock.openbanking \ --artifact-id openbanking-sdk \ -l java \ --library resttemplate \ -o generated
  3. Check the generated files and copy them into appropriate source directory. Do not overwrite existing files.
  4. Remove Links, Meta, OBError1 and OBErrorResponse1 - we use shared generic versions of these classes.
  5. Repeat generation for each new swagger json file
  6. If using Intelij, run format and optimise imports on newly generated files.
  7. Increment the major or minor version in pom.xml
  8. Run build to ensure everything compiles and copyrights are generated for new source files.
  9. Commit and raise PR.

Release to maven central

This project is built and released to maven using Travis CI. When a change is merged to master branch, Travis CI will increment the version, build the project, sign the release artifacts and release it to maven central (https://oss.sonatype.org). We no longer use Bintray in this project.

Licence

License: CDDLv1.0
License URL : https://opensource.org/licenses/CDDL-1.0

About

A Java SDK to help implementing the Open Banking standard : https://www.openbanking.org.uk/read-write-apis/


Languages

Language:Java 100.0%Language:Shell 0.0%