Auth 1.0 oauth_signature creation Android for magento API
We didn’t need to pass all the attribute as auth, retrofit itself handle this, we need to pass only the CONSUMER_KEY, CONSUMER_SECRET, ACCESS_TOKEN and TOKEN_SECRET. By following this ApiUtils class will be like, Kotlin class ApiUtils { companion object { fun getAPIService(): APIService? { val consumer = OkHttpOAuthConsumer(BuildConfig.CONSUMER_KEY, BuildConfig.CONSUMER_SECRET) consumer.setTokenWithSecret(BuildConfig.ACCESS_TOKEN, BuildConfig.TOKEN_SECRET) return RetrofitClient.getClient(BuildConfig.BASE_URL, consumer)?.create(APIService::class.java) } … Read more