facebook_audience_network
Facebook Audience Network plugin for Flutter applications.
Note: Currently only Android platform is supported.
Banner Ad | Native Banner Ad | Native Ad |
---|---|---|
![]() |
![]() |
![]() |
Interstitial Ad | Rewarded Video Ad | In-Stream Video Ad |
---|---|---|
![]() |
![]() |
![]() |
Getting Started
1. Initialization:
For testing purposes you need to obtain the hashed ID of your testing device. To obtain the hashed ID:
- Call
FacebookAudienceNetwork.init()
during app initialization. - Place the
FacebookBannerAd
widget in your app. - Run the app.
The hased id will be in printed to the logcat. Paste that onto the testingId
parameter.
2. Show Banner Ad:
3. Show Interstitial Ad:
4. Show Rewarded Video Ad:
5. Show In-Stream Video Ad:
Make sure the width and height is 300 at minimum.
6. Show Native Ad:
7. Show Native Banner Ad:
Use NativeBannerAdSize
to choose the height for Native banner ads. height
property is ignored for native banner ads.
Check out the example for complete implementation.
Future Work
Implement for iOS platform.