question

developer314 avatar image
developer314 asked

Documentation on calling Mobile Ads plugin methods for Cordova app

Hi there - I am using the Amazon Mobile Ads plugin with a Cordova app that I'm building. I've been successful adding the plugin to my Cordova project, and I've also successfully called the setApplicationKey and registerApplication methods. However, I haven't been able to successfully call the enableLogging, enableTesting, createFloatingBannerAd, or loadAndShowFloatingBannerAd methods. The reason I haven't been able to call these methods is because I can't find any documentation on what options I need to specify for these methods, as well as what the structure of the options parameter should be for each method (e.g. string, array, object, etc.). Can anyone point me to some Javascript examples (not Java) calling these methods?

Thanks.

amazon appstoremobile adsweb appsmobile apis and services
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

1 Answer

Levon@Amazon avatar image
Levon@Amazon answered

Hi developer314,

Thanks for posting! Please see Mobile Ads Plugin Methods and Events for Cordova:

https://developer.amazon.com/public/apis/earn/mobile-ads/cordova/mobile-ads-plugin-methods-and-events-for-cordova

2 comments
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Hi Levon - thanks for the reply. I'm familiar with the link you supplied. However, please take a look at the page. Unless I'm missing something, it looks like Amazon mixed different language implementations into the same page. For example, Javascript code is provided for the setApplicationKey method, but take a look at the code for the enableLogging method. That's not Javascript. The same is true for several other methods on the page. Am I missing something on how these methods are called via Javascript (not Java)?

0 Likes 0 ·

Hi developer314,

Thank you for bringing that to our attention. I notified the technical documentation team to correct it, and will post here as soon as we have any updates. Thanks!

0 Likes 0 ·