https://github.com/zoho/subscriptions-java-client
Java client for Zoho Subscriptions.
https://github.com/zoho/subscriptions-java-client
Last synced: 9 months ago
JSON representation
Java client for Zoho Subscriptions.
- Host: GitHub
- URL: https://github.com/zoho/subscriptions-java-client
- Owner: zoho
- License: mit
- Created: 2016-09-11T05:47:17.000Z (over 9 years ago)
- Default Branch: master
- Last Pushed: 2022-05-24T06:52:35.000Z (almost 4 years ago)
- Last Synced: 2023-08-17T14:09:57.756Z (over 2 years ago)
- Language: Java
- Size: 2.2 MB
- Stars: 2
- Watchers: 9
- Forks: 7
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
# Zoho Subscriptions Java Client Library
An open source Java Client library for integrating with Zoho Subscriptions Billing Solution
### To get the latest jar
Subscriptions java client jar is listed under the ```dist``` directory. Just checkout the latest version by
```git checkout [latest release tag]```
## Usage
Import the Zoho Subscriptions Java Client Library to your project
### Setup
**SetUp Organization ID and OAuth Access Token**
1. Get Organization Id refer
2. Generate oauth token using API Reference
##### Sample Code:
import com.zoho.subscription.net.*;
import java.io.IOException;
import java.util.*;
public class Main {
public static void main (String args[]) throws Exception
{
ZSClient object = new ZSClient();
object.setOauthtoken("{{Zoho Subscriptions Oauth Token}}");
object.setOrganizationId("{{Zoho Organization ID}}");
}
}
## How to use
Use the below sample code for Customer Creation refer Api Docs
Example to create a Customer:
import com.zoho.subscription.net.*;
import com.zoho.subscription.model.*;
import java.io.IOException;
import com.fasterxml.jackson.databind.ObjectMapper;
import java.util.*;
public class Main {
public static void main (String args[]) throws Exception
{
ZSClient object = new ZSClient();
object.setOauthtoken("{{Zoho Subscriptions Oauth Token}}");
object.setOrganizationId("{{Zoho Organization ID}}");
ObjectMapper mapper = new ObjectMapper();
Customer customer=new Customer();
customer.setDisplayName("Patricia Boyale");
customer.setEmail("patricia.boyale@zylker.com");
customer.setPhone("9876543210");
Customer new_customer = new Customer();
new_customer = Customer.create(customer);
System.out.println(new_customer.getCustomerId())
}
}
## License
See the LICENCE file.
## Dependencies
------------
- [jackson-annotations-2.0.2.jar](https://repo1.maven.org/maven2/com/fasterxml/jackson/core/jackson-annotations/2.0.2/jackson-annotations-2.0.2.jar)
- [jackson-core-2.0.2.jar](https://repo1.maven.org/maven2/com/fasterxml/jackson/core/jackson-core/2.0.2/jackson-core-2.0.2.jar)
- [jackson-databind-2.0.2.jar](https://repo1.maven.org/maven2/com/fasterxml/jackson/core/jackson-databind/2.0.2/jackson-databind-2.0.2.jar)