Transak Docs
Search…
πŸ€–
Android
To add Transak to you Android app add the below code:

MainActivity.Java

Make sure to add your API key and customise using query parameters​
1
import android.webkit.WebView;
2
...
3
​
4
webView = (WebView) findViewById(R.id.transakWidget);
5
webView.getSettings().setJavaScriptEnabled(true);
6
webView.loadUrl("<https://global.transak.com?apiKey=[YOUR_PRODUCTION_API_KEY]&[QUERY_PARAMETERS]>");
Copied!

Activity_main.xml

1
<WebView xmlns:android="<http://schemas.android.com/apk/res/android>"
2
android:id="@+id/transakWidget"
3
android:layout_width="fill_parent"
4
android:layout_height="fill_parent"/>
Copied!

Provide permission in AndroidManifest.XML

1
<uses-permission android:name="android.permission.INTERNET"/>
Copied!
Last modified 3mo ago