BankAxept / bankaxept-epayment-development-kit

MIT License
3 stars 2 forks source link

Development kit for BankAxept ePayment integration

The BankAxept ePayment development kit provides OpenAPI specifications and Java clients for integration with the ePayment APIs:

Documentation overview

On our publicly hosted GitHub Pages you may peruse a hand crafted overview of our documentation.

Maven artifacts for Java clients

There are three Maven artifacts available, one for each if the ePayment APIs:

<dependency>
  <groupId>no.bankaxept.epayment</groupId>
  <artifactId>merchant-client</artifactId>
  <version>x.y.z</version>
</dependency>

<dependency>
  <groupId>no.bankaxept.epayment</groupId>
  <artifactId>token-requestor-client</artifactId>
  <version>x.y.z</version>
</dependency>

<dependency>
  <groupId>no.bankaxept.epayment</groupId>
  <artifactId>wallet-client</artifactId>
  <version>x.y.z</version>
</dependency>

These artifact rely on an HTTP client loaded through Java's Service Provider Interface. There's one provided by thiskit development kit, based on Spring WebFlux:

<dependency>
  <groupId>no.bankaxept.epayment</groupId>
  <artifactId>webflux-client</artifactId>
  <version>x.y.z</version>
</dependency>

The artifacts are available on a GitHub Packages repository, so make sure to include the following in your pom.xml as well:

<repositories>
  <repository>
    <id>github</id>
    <url>https://maven.pkg.github.com/BankAxept/bankaxept-epayment-development-kit</url>
  </repository>
</repositories>

Note: GitHub Packages does not allow anonymous access for downloading Maven artifacts. A GitHub personal access token (PAT) with read:packages scope will provide sufficient access.

HTTP client

If you want to use your own HTTP client with the Java clients you can provide it through Java Service Provider Interface by implementing the following interfaces:

Then create a configuration file (like this). The webflux-client module can be used for reference.

Java client usage

Each of the three Java clients can be constructed by providing the following parameters:

Contact BankAxept for appropriate values.