Skip to content

Java client application consuming gpi v4 APIs using SWIFT SDK.

License

Notifications You must be signed in to change notification settings

defiQUG/SWIFTINC_gpi-v4-demo-1

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

24 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

SWIFT gpi API demo application in Java

Make calls to SWIFT APIs is easy using SWIFT SDK. All you need to do is add the SWIFT SDKs as dependency when building your Java application through Maven or Gradle.

We built this demo Java application with Maven to show you how we are using it to make calls to SWIFT gpi APIs in the API Sandbox.

Getting Started

Prerequisites

  • Java 11 and below
  • maven 3.5.* and above

Install SWIFT SDK

Download SWIFT SDK from SWIFT Developer Portal, login is required for download.

Unpackage the zip file and install the dependency in your local .m2 repository.

$ install.sh

Configure runtime SDK propertise

Update config/config-swift-connect.yaml with your application credentials, consumer-key & consumer-secret. Obtain from SWIFT Developer Portal by creating an app.

To use forward proxies update config/config-swift-connect-fp.yaml with your application credentials, consumer-key & consumer-secret and forward proxy information. Obtain from SWIFT Developer Portal by creating an app.

Build

$ mvn clean install

Run

$ java -Dlog4j.configuration=file:config/log4j.properties -jar target/gpi-v4-demo-jar-with-dependencies.jar config/config-swift-connect.yaml

To use forward proxies:

$ java -Dlog4j.configuration=file:config/log4j.properties -jar target/gpi-v4-demo-jar-with-dependencies.jar config/config-swift-connect-fp.yaml

Keystore

The keystore (conf/keystore.jks) has these several entried that may need renewing when the Sandbox certificate is renewed:

  • globalsign_root_ca_r3, 18 Oct 2022, trustedCertEntry, Sandbox server root ca
  • globalsign_rsa_ov_ssl_ca_2018, 18 Oct 2022, trustedCertEntry, Sandbox server sub ca
  • sandbox_pub, 18 Oct 2022, trustedCertEntry, Sandbox server cert. Potentially not needed given its roots are present (see above)
  • selfsigned, 18 Jun 2020, PrivateKeyEntry, Demo client key

Authors

[email protected]

About

Java client application consuming gpi v4 APIs using SWIFT SDK.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Java 100.0%