Back to Account

Integration Guide

Follow these steps to start earning with Monetix Ads.

1. Add the SDK

Paste this into your <head> tag.

<script src="https://monetix.wenepay.cyou/ads.js" data-mxid="YOUR_MXID"></script>

2. Trigger Reward

Use this function to show an ad and reward your user.

function claimReward() {
  window.showRewardAd((res) => {
    if (res.status === "completed") {
      alert("Success! Reward granted.");
      // Add your coin/energy logic here
    }
  });
}

3. Full HTML Example

Copy this full code into a file named index.html to test.

<!DOCTYPE html>
<html>
<head>
  <title>Monetix Test</title>
  <script src="https://monetix.wenepay.cyou/ads.js" data-mxid="YOUR_MXID"></script>
</head>
<body style="background:#000; color:#fff; text-align:center; padding-top:50px;">
  <h2>Monetix Reward Test</h2>
  <button onclick="claimReward()" style="padding:15px; border-radius:10px;">
    Watch Ad for Reward
  </button>

  <script>
    function claimReward() {
      window.showRewardAd((res) => {
        if(res.status === "completed") alert("Reward Success!");
      });
    }
  </script>
</body>
</html>
StatusMeaning
completedUser watched the full ad. Give reward.
closedUser closed ad early. No reward.
© 2026 Monetix Network