Skip to content

Latest commit

 

History

History
33 lines (29 loc) · 1.61 KB

InitSDK.md

File metadata and controls

33 lines (29 loc) · 1.61 KB

Initiate Citrus SDK

Make sure you initialize Citrus SDK just before processing Payment. It is not recommended to init() SDK on app launch.

Create a object of CitrusClient

    CitrusClient citrusClient = CitrusClient.getInstance(Context);
  • SDK supports two different environments.Sandbox and Production.

  • Testing should be done on Sandbox.User created on Sandbox environment will not be available on production environment. You have to explicitly create account for both environments.

  • Once your app is working fine with Sandbox environment, you can switch environment to Production.so please make sure you are using correct set of keys and have set environment to Production before releasing your app to Play-Store.

  • Pass your environment as SANDBOX to citrusClient.init method when testing as mentioned below.

Pass merchant parameters in init

    citrusClient.init(
              "test-signup", 
              "c78ec84e389814a05d3ae46546d16d2e", 
              "test-signin", 
              "52f7e15efd4208cf5345dd554443fd99", 
              "testing", 
              Environment.SANDBOX ); // Make sure change the environment to PRODUCTION while going live.

For both the enviroments Citrus PG Prerequisites key sets are different. keys from one enviroment wont work on other.

  • First Parameter – SignUp Key
  • Second Parameter – SignUp Secret
  • Third Parameter – SignIn Key
  • Fourth Parameter - SignIn Secret
  • Fifth Parameter - Vanity
  • Sixth Parameter - Environment.