Possíveis erros no console

Todas as mensagens impressas no console terão o prefixo [Ad Placement API]:

Você só pode definir preloadAdBreaks uma vez:

  • adConfig() já foi chamado para definir preloadAdBreaks com o valor <VALUE>

Tentativa de chamar adBreak() enquanto outra chamada para adBreak() ainda estava em andamento. Verifique se você não está acionando anúncios de outros workers e se não está chamando adBreak() de dentro de uma função de callback:

  • Cannot show ad while another ad is already visible.

Falhas ao executar qualquer callback fornecido:

  • <CALLBACK NAME> callback threw an error: <ERROR>

Erros nos parâmetros de inclusão de tag:

  • Invalid data-ad-frequency-hint value: '<VALUE>'. It must be in format 'Xs' where X is a number.
  • Unsupported data-adbreak-test value '<VALUE>'. Supported values: 'on'.

Erros de validação do argumento adConfig():

  • Invalid ad config: <ERROR>. Onde <ERROR> pode ser:
    • preloadAdBreaks must be one of ['auto', 'on']
    • sound must be one of ['on', 'off']
    • onReady precisa ser uma função

Erros de validação do argumento adBreak():

  • Invalid placement config: <ERROR>. Onde <ERROR> pode ser:
    • missing required properties <LIST OF PROPERTIES>
    • <CALLBACK NAME> must be a function
    • <PROPERTY NAME> must be one of <LIST OF VALID VALUES>
    • the following properties are not used for the given ad type: <LIST OF PROPERTIES>

Os callbacks renomeados em adBreak() (beforeBreak, afterBreak e adComplete foram renomeados como beforeAd, afterAd e adViewed, respectivamente Elas ainda funcionam da mesma forma:

  • Placement config: <OLD> has been renamed to <NEW>. Please update your code.
  • Invalid placement config: <OLD> has been renamed to <NEW>. Cannot pass both fields. Please use <NEW> only.