# Reward Hash

{% hint style="success" %}
**To win 1 BTC, 100 BNB with total prize pool worth $1M USD, start by** [**boosting your MAIGA XP today**](https://t.me/maigaxbt_bot)**!**
{% endhint %}

## What is MAIGA’s Reward Hash?

Every time you boost your XP using the MaigaXBT AI agent, you’re also triggering a provably fair on-chain reward mechanism: the Reward Hash.

It’s a native way to reward users onchain activities, using the raw mechanics of blockchain. No off-chain RNG, no centralized logic, just verifiable transaction hashes and pure luck.

## How the Reward Hash is generated: “Hash within Hash”

<figure><img src="https://lh7-rt.googleusercontent.com/docsz/AD_4nXcq4Zq6KDDDY3vIgvH3zEpOSqVFVkC7wggThYovNJ46k07uuJ64dhp7J1nrttI7neBoAQNi4L_Wcif87fEYl6VY0ZLrJwl_3Msv_y_difda8PULxuHogaWkrjtB2lKnh2ffLusIAQ?key=VizouvlnHWaHpwuRwShWWg" alt=""><figcaption><p>Maiga's innovative Reward Hash</p></figcaption></figure>

To generate these hashes, Maiga developed a verifiably fair method called "Hash within Hash", which uses Ethereum's *keccak256* hashing algorithm to combine several on-chain variables:

#### Breakdown:

* **tokenId** – Unique ID from the boost
* **msg.sender** – Your wallet address
* **block.chainid** – The current blockchain (e.g. BNB = 56)
* **boostCount\[tokenId]** – Number of times the NFT has been boosted
* **block.timestamp** – Timestamp of block confirmation
* **blockhash(block.number)** – The actual block hash

These inputs ensure every Reward Hash is:

* **Unique** (boost count, sender, tokenId)
* **Unpredictable** (block timestamp and hash)
* **Immutable** once confirmed on-chain

This makes any attempt to game the system practically impossible unless you can control the network (e.g. a 51% attack).

## Why It’s Different

### 100% On-Chain

Unlike traditional raffles that rely on opaque backend logic, MAIGA’s Reward Hash system is:

1. Completely on-chain where hashes are generated during actual blockchain transactions
2. Immutable, meaning once a transaction is confirmed, the hash cannot be altered.
3. Self-verifiable - anyone can view the reward hash using blockchain explorers.

### Provably Fair

Each reward hash is based on a mix of variables that cannot be predicted before your transaction is mined.

1. `Block.timestamp`: Exact time the block is mined
2. `blockhash(block.number)`: Hash of the current block

These inputs are only known after the block is confirmed, making it impossible for users or developers to force a specific outcome. The only way to generate one is by executing real transactions and leaving it (your luck and trust) to the chain.

**Let’s further break down how it exactly works:**

A Reward Hash is a 32-byte hexadecimal string (like  transaction ID) generated when a user boosts XP via the MaigaXBT AI agent.

Each <kbd><mark style="color:blue;">/boostxp<mark style="color:blue;"></kbd> action signs and submits an on-chain transaction through your MAIGA MPC wallet or your web3 wallet. This transaction hash will be used to create a reward hash and the **final 6 alphanumerics of that hash** are evaluated for reward eligibility, like this:

<kbd><mark style="color:green;">0xddaa624d505222c1da48831db68f8440ce478d74728a6f8255b36669316ae361<mark style="color:green;"></kbd>

Last characters = ...<kbd><mark style="color:green;">361<mark style="color:green;"></kbd>. If the ruleset rewards hash like <kbd><mark style="color:green;">123<mark style="color:green;"></kbd>, this transaction isn’t a winner. But if it ends in <kbd><mark style="color:green;">123, 456, 789, abc, def<mark style="color:green;"></kbd>, you could win up to **$100 and more**.

This suffix is called your **Reward Hash**.&#x20;

## Updated Reward Hash prizes

<table data-header-hidden><thead><tr><th width="449.64453125"></th><th></th><th data-hidden></th></tr></thead><tbody><tr><td><strong>Reward Hash Lucky Draw Ending</strong></td><td><strong>$ USDT Prize</strong></td><td><strong>USD Value ($1,000/BNB)</strong></td></tr><tr><td>00, 11, 22, 33, 44, 55, 66, 77, 88, 99, aa, bb, cc, dd, ee, ff</td><td>$5 USDT</td><td>$15</td></tr><tr><td>123, 456, 789, abc, def</td><td>$100 USDT</td><td>$150</td></tr><tr><td>1234, 6789, abcd</td><td>$1,000 USDT</td><td>$1,500</td></tr><tr><td>12345, abcde</td><td>$10,000 USDT</td><td>$15,000</td></tr><tr><td>123456</td><td>1 BTC</td><td>$100,000 +</td></tr></tbody></table>

{% hint style="success" %}
**The more you boost, the higher your chances of hitting a winning reward hash.**
{% endhint %}

## Example of actual reward hash:

Alice boosted XP on the Telegram MaigaXBT and sends a transaction on-chain on BNB or opBNB mainnet. In 6 transactions, Alice managed to get an actual on-chain reward hash of <kbd><mark style="color:green;">**98EEAA**<mark style="color:green;"></kbd> (see screenshot) and won a Reward Hash lucky draw prize of **0.015 BNB** (\~$15).

<figure><img src="https://3394575098-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FILQuDyQdAQeVEdJzf3TA%2Fuploads%2FGYtFzY3MbkpXZiCZb9sm%2FScreenshot%202025-05-15%20at%206.22.52%20PM.png?alt=media&#x26;token=8b283774-0e17-4ae0-95be-ec08bd695102" alt=""><figcaption><p><a href="https://opbnb.bscscan.com/tx/0x0e7c86c27690f8d9c615479068b505b6fd581bc8f43dffc179e4170362d9ab79#eventlog">https://opbnb.bscscan.com/tx/0x0e7c86c27690f8d9c615479068b505b6fd581bc8f43dffc179e4170362d9ab79#eventlog</a></p></figcaption></figure>

<figure><img src="https://3394575098-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FILQuDyQdAQeVEdJzf3TA%2Fuploads%2FJz3tsWj06cL0iyGBt28D%2FScreenshot%202025-05-15%20at%206.24.58%20PM.png?alt=media&#x26;token=cf7d6843-4b85-4564-8d59-82f5b4bf931f" alt=""><figcaption><p><a href="https://opbnb.bscscan.com/tx/0x0e7c86c27690f8d9c615479068b505b6fd581bc8f43dffc179e4170362d9ab79#eventlog">https://opbnb.bscscan.com/tx/0x0e7c86c27690f8d9c615479068b505b6fd581bc8f43dffc179e4170362d9ab79#eventlog</a></p></figcaption></figure>
