Android SDK Integration
You have two options two integrate our Android SDK. You can use either the .jar or the .aar files. Please, follow the instructions below.
Adstronomic Android SDK.zip
288KB
Binary
Download Android SDK
Adstronomic - Android Sample.zip
19MB
Binary
Download Android Sample app
​
πŸ’‘
Note: The SDK integration has to be done manually.

Installation

➜ Option 1

Download the .zip file and extract the .aar files. Create a libs folder at the root of your project and copy it here. Now, on your Gradle configuration file (build.gradle), add: // Adstronomic SDK compile(name: 'adstronomic-debug', ext: 'aar') implementation 'com.android.volley:volley:1.1.1' implementation 'com.squareup.picasso:picasso:2.71828' implementation 'androidx.core:core-ktx:1.3.2' Update your Gradle project.
πŸ§™ Tips: Having an error message saying β€˜Failed to resolve :my_library’? Click here​

➜ Option 2

Download the .zip file and extract the .jar file. Create a libs folder at the root of your project and copy it here. Now, on your Gradle configuration file (build.gradle), add: implementation files('libs/AdstronomicSDK.jar') implementation 'com.android.volley:volley:1.1.1' implementation 'com.squareup.picasso:picasso:2.71828' implementation 'androidx.core:core-ktx:1.3.2' Update your Gradle project.

Setup

Open your MainActivity.java and add the following include code import com.adstronomic.sdk.Adstronomic;. Now, initialize Adstronomic in the onCreate methods of your Activity with this line Adstronomic.init(this, "CAMPAIGN ID"); and replace CAMPAIGN ID with your ID available on your dashboard.
You're now ready to load and show Ads.

How to use

You can load all Ads after the setup with this method Adstronomic.loadAdsData();.
Last modified 10mo ago