πŸ“–
SDKs Integration
  • Quick Start
  • πŸ€–Android
    • Android SDK Integration
      • Banner Ads
      • Interstitial Ads
      • Rewarded Ads
  • 🍏iOS
    • iOS SDK Integration
      • Banner Ads
      • Interstitial Ads
      • Rewarded Ads
  • Frequently Asked Questions
  • Contact us
  • Documentation
Powered by GitBook
On this page
  • Installation
  • ➜ Option 1
  • ➜ Option 2
  • Setup
  • How to use

Was this helpful?

  1. Android

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.

PreviousQuick StartNextBanner Ads

Last updated 4 years ago

Was this helpful?

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’?

➜ 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();.

πŸ€–
πŸ’‘
Click here
288KB
Adstronomic Android SDK.zip
archive
Download Android SDK
19MB
Adstronomic - Android Sample.zip
archive
Download Android Sample app