Skip to content

Try the reward player

Toggling an option updates the generated code on the right. Use ▶ Preview to launch the reward player with a sample ad using the current settings.

Use normal in most cases; use ima for the Google IMA SDK.

Shows the reward name prominently in the accent color.

When the reward is earned. If the ad is shorter than the seconds, it is earned on completion.

Seconds of viewing required to earn.

disabled shows no skip control and requires full viewing.

Presentation. responsive picks modal / sheet by viewport width.

Color scheme. auto follows the OS dark / light setting.

Player UI language. auto follows the browser language.

Treated as a failure if no ad starts within this time (ms).

Off: one ad; on: all ads in the pod must be finished.

What to do when the ad fails to load or play.

Autoplays muted. When off, the first tap starts playback with sound.

Shows a quiet success toast when the reward is granted.

Confirms before closing without claiming the reward.

Measures via Open Measurement (only ads with AdVerifications).

Requires a button tap to claim. When off, grants automatically once earned.

Allows closing before the reward is earned.

Closes the modal after claiming.

Grants the reward even if closed while claimable.

<div id="reward-slot"></div>
<script src="https://cdn.michao-ssp.com/player/v1/reward.js"></script>
<script>
  window.michao.createRewardPlayer({
    bid, // VAST bid
    target: "reward-slot",
    mode: "normal",
    reward: "50 coins",
    skin: "responsive",
    theme: "auto",
    muted: true,
    successToast: true,
    confirmClose: true,
    omid: false,
    loadTimeoutMs: 3000,
    policy: {
      trigger: {
        type: "minWatch",
        seconds: 15,
      },
      skip: {
        mode: "disabled",
      },
      pod: {
        required: 1,
      },
      requireClaimClick: true,
      closableBeforeClaim: false,
      closeAfterClaim: true,
      grantOnClose: true,
      onAdFailure: "deny",
    },
  });
</script>

For the full list of options, see the API reference.

Michao!! player documentation