OSTKit is an api wrapper written in java and kotlin for ost kit. The complete blockchain toolkit for business
Volley: https://developer.android.com/training/volley/
Kotlin https://developer.android.com/kotlin/
OST KIT⍺ API: https://dev.ost.com/docs/api.html
==========
OST KIT⍺ API
Simple SDK solution.
Add it in your root build.gradle at the end of repositories:
allprojects {
repositories {
...
maven { url 'https://jitpack.io' }
}
}
Add the dependency
dependencies {
implementation 'com.github.ost-sdk:ostkit-android:0.0.2'
}
OstWrapperSdk ostWrapperSdk = new OstWrapperSdk(context, API_KEY, SECRET, isDebug);
ostWrapperSdk.newUserWrapper().getListUser(nextPage, new VolleyRequestCallback() {
@Override
public void callback(
82CC
Context context, Boolean isSuccess, String result) {
Log.d("tag", result);
if (isSuccess) {
try {
JSONObject jsonResult = new JSONObject(result);
Boolean isSuccessApi = jsonResult.getBoolean("success");
if (isSuccessApi) {
JSONObject jsonData = jsonResult.getJSONObject("data");
JSONObject jsonMetaData = jsonData.getJSONObject("meta");
JSONObject jsonNextPagePayload = jsonMetaData.getJSONObject("next_page_payload");
ArrayList<UserModel> listUser = new ArrayList<>();
JSONArray arrayData = jsonData.getJSONArray("economy_users");
for (int i = 0; i < arrayData.length(); i++) {
UserModel itemModel = new UserModel();
itemModel.setData(arrayData.getJSONObject(i));
listUser.add(itemModel);
}
addListItem(listUser);
if (Utilities.checkKeyValid(jsonNextPagePayload, "page_no")) {
nextPage = jsonNextPagePayload.getInt("page_no");
} else {
}
} else {
}
} catch (JSONException ex) {
ex.printStackTrace();
}
} else {
}
}
});
- createUser
- editUser
- getListUser
- createTransactionType
- editTransactionType
- getListTransactionType
- executeTransactionType
- statusTransactionType
- executeAirdrop
- retrieveAirdrop
- getListAirDrop
OSTKit is owned by @vanductai and maintained by @tinhuit89
You can contact me at email tinhvc89@gmail.com