Skip to main content

Installation

For SDK installation, you’ll have to add the SuprSend jar file. You can include the jar using following two ways:
suprsend-java-sdk is present as a maven dependency on maven central. Add following code to your pom.xml to include the sdk
<dependencies>
  <dependency>
    <groupId>com.suprsend</groupId>
    <artifactId>suprsend-java-sdk</artifactId>
    <version>0.5.0</version>
  </dependency>
</dependencies>
Click here to download the latest version of java SDK from releases section and add it as an External Jar in your build path. suprsend-java-sdk is available as a JAR with name- suprsend-java-sdk-0.5.0-jar-with-dependencies.jar
JDK version 8 and above is supportedPlease check your Java development kit version. If it is lower than supported version, upgrade it to the latest version

Initialization

For initializing SDK, you need WORKSPACE KEY and WORKSPACE SECRET.
import suprsend.Suprsend;
Suprsend suprsend = new Suprsend("WORKSPACE KEY", "WORKSPACE SECRET");
Replace WORKSPACE KEY and WORKSPACE SECRET with your workspace values. You will get both the tokens from Developers -> API Keys section.

Constructor to test SDK in debug mode

Constructor allows you to view HTTP calls to Suprsend in your console. The final parameter is a boolean parameter which denotes whether value for “debug” is true or false. Default value for the same is false.
import suprsend.Suprsend;
Suprsend suprsend = new Suprsend("WORKSPACE KEY", "WORKSPACE SECRET", true);

I