Skip to content


Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?

Latest commit


Git stats


Failed to load latest commit information.
Latest commit message
Commit time


Activeledger SDK-Android

To use the Android SDK please Add it in your root build.gradle at the end of repositories:

allprojects {
	repositories {
		maven { url '' }

Add the dependency

dependencies {
	implementation 'com.github.activeledger:SDK-Android:Tag'

For Maven:


Add the dependency


NOTE: Please update the Tag : 0.1.3

SDK Dev Instruction

Use the ActiveLedger SDK interface to Use the SDK.

Initialise the SDK


Generate KeyPair

Generating a KeyPair will give an Observable in return. User RxAndroid to subscribe to the Obserable.

Observable<KeyPair> keyPair = ActiveLedgerSDK.getInstance().generateAndSetKeyPair(KeyType,SaveKeysToFile);
Observable<KeyPair> keyPair = ActiveLedgerSDK.getInstance().generateAndSetKeyPair(keyType,true);

Oboard KeyPair

Onboarding a KeyPair will give an Observable in return. User RxAndroid to subscribe to the Obserable.

Observable<String> response = ActiveLedgerSDK.getInstance().onBoardKeys(KeyPair, "KeyName");
ActiveLedgerSDK.getInstance().onBoardKeys(keyPair, "ActiveLedgerAwesomeKey");

Creating and Signing Transaction

Transactions can be created using Transactions class in the SDK. User can create complete transaction or just the $tx Object and SDK will create the complete transaction. User can also create Labeled Transaction using the example below. $tx is a JSONObject that can be created by folowing Activeledger Documentation.

JSONObject transaction = Transactions.createLabeledTransaction($tx);

Server Sent Event

Server Sent Events can be subscribed by giving the protocol, ip and port. All the functional URLs can be found in Utility/ApiURL. User can create their own ServerEventListener and observe the events or can pass null and Observe the LiveData variable "SSEUtil.getInstance().eventLiveData".

ActiveLedgerSDK.getInstance().subscribeToEvent(protocol, ip, port, url, null/ServerEventListener);

Executing a Transaction

Execute method takes a transaction and will give an Observable in return with response in String format. User RxAndroid to subscribe to the Obserable.

Observable<String>  respinse =  ActiveLedgerSDK.getInstance().executeTransaction(String transactionJson);


This project is licensed under the MIT License