Publishers · Reference

Errors & troubleshooting

What every SDK error means and how to fix it.

When show() fails, result.description contains one of these messages.

ErrorWhat it meansHow to fix
Wrong refererThe ad was requested from a domain that isn't your Web app URLOpen the app from the URL saved on your platform
Need to use active blockidBlock is paused or still in reviewWait for review or activate the block
Not found this idBlock ID typoCopy the ID again from the panel
Need to specify blockidinit() called without blockIdPass { blockId: "..." }
No botIdPlatform has no Bot IDContact support to add it
Bad init dataTelegram signature invalidOpen the app through Telegram, not a copied link
Session too oldApp opened more than 4 h / 24 h agoAsk the user to restart the Mini App
No available adNo campaign matches this user right nowNormal — handle onBannerNotFound
NonStopShowAds requested too fastWait at least 5 s between ads
NoUserDataNot running inside TelegramTest inside Telegram or use debug: true
Bad signature / ReplayRequest was changed or repeatedDon't proxy or cache SDK requests
VideoLoadTimeout / PlayRequestFailedSlow network or autoplay blockedSDK shows a tap-to-play button automatically

Errors thrown by init()

These appear in the console as an exception, before any ad request is made — they are your own code, not the network:

Message containsCauseFix
blockId param should contain only letters, digits, '-' or '_'The ID was pasted with a space, a quote or a slashCopy the ID again from the block page
debug should be booleandebug was passed as a string ("true")Use debug: true without quotes
debugBannerType should be one of ...Typo in the debug format nameUse "RewardedVideo" or "FullscreenMedia"
passing container parameter is not allowedAn old snippet passes a container elementRemove container — the ad always opens full-screen

Common questions

The ad doesn't show at all

  • Is the script tag in <head>? Check typeof window.Adsun.
  • Is the block Active? Try debug: true first.
  • Look at the console for “ADSUN DEBUG LOG”.

My users don't get the reward

  • Check that your Reward URL is reachable from the internet (not localhost).
  • It's not called in debug mode.
  • If anti-fraud rejects the view, onNotSuitable fires and no reward is sent.

The ad is under Telegram's buttons

The SDK handles safe areas automatically. Make sure you load telegram-web-app.js and keep the SDK up to date.

Still stuck? Write to support@adsun.io or our Telegram support — we answer fast.