VMSMobileSDK initialization
Main entry point to establish connection between application and server.
Initialization
For simple initialization you must set 3 required params to 'VMSMobileSDK.Builder':
application: Application - import android.app.*
baseUrl: String - url of your server
uuid: String - uuid of your server
import VMSMobileSDK
VMSMobileSDK.Builder(
application: Application,
baseUrl: String,
uuid: String,
language: VMSLanguage,
).apply {
// If you have access token
if (your_user_token.isNotEmpty()) {
VMSMobileSDK.userToken = your_user_token
}
}
Language
For now we support only two languages
enum class VMSLanguage(val language: String) {
ENGLISH("en"),
RUSSIAN("ru");
}
Access token
For authorised user you can set user's access token. You must set access token after successful login to use it in other requests. Set 'userToken' from 'VMSMobileSDK':
VMSMobileSDK.userToken = your_user_token
We support only 3 requests without tokens:
getTranslations();
getStatics();
getStaticBasic();