Java SDK for interacting with PayZippy charging, query and refund APIs
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Type Name Latest commit message Commit time
Failed to load latest commit information.


PayZippy Java SDK for interacting with PayZippy charging, query and refund APIs.
Checkout wiki page for documentation

To integrate the SDK.
1. Download the SDK, copy the classes from the folder java-sdk-master/target/classes, make sure the package structure is followed.
2. In the checkout page of your website, use the ChargingRequestBuilder object to set all the parameters of your checkout page and then call build method which return ChargingRequest. Make sure all the mandatory parameters are set in the ChargingRequestBuilder object
3. Then call chargingRequest.getUrl(CHARGING_URL) which return the charging API url with all the parameters by passing the charging API url without the parameters

Sample code snippet to create a charging request object is shown below:

//import the package which contains the payzippy sdk classes
<%@page import="com.payzippy.sdk.*" %>

//set all the parameters in the charging builder object
ChargingRequestBuilder chargingBuilder=ChargingRequest.getBuilder();
chargingBuilder.setMerchantKeyId(<pass your merchant key id here>);
chargingBuilder.setMerchantId(<pass your merchant id here>);
//similarly set all the mandatory parameters as shown above

//and to set any optional parameter in the charging builder object
chargingBuilder.putParams("buyer_phone_no", <pass the buyer phone number here>);
chargingBuilder.putParams("shipping_address", <pass the buyer shipping address here>);

//call build method which returns ChargingRequest object by passing the secret key
ChargingRequest chargingRequest =<pass your secret key here>);

//get the url here
String url = chargingRequest.getUrl(<pass the charging API url>);

//if ui_mode is REDIRECT, then

//else if ui_mode is IFRAME
//include the url in the iframe src like the example below
<iframe src="<%=url%>" height="450" width="50%">

//The parameters item_vertical,item_total and buyer_phone_no are now mandatory.Pass these parameters for all the transactions(both domestic and international).
public ChargingRequestBuilder putParams(String key, Object value);
eg: putParams("item_vertical",books)

For complete documentation, please refer the link