Foster loyalty through a points system that rewards consistent interaction with your platform.

Examples

  • Distribute an ‘Early Adopter’ badge for the first 100 wallet
  • Distribute 10 points to members who have been active for longer than 2 months

Create a token collection

  1. Go to the ‘Tokens’ tab in the Dashboard.
  2. Click ‘+ New Token’. Select a token type.
  3. Fill out the details and configure transferability. Click ‘Done’.

Integrate into your application

You can skip the following requirements if you’ve already configured your group’s developer settings.

  1. In the Dashboard, go to the ‘Settings’ tab.
  2. Go to the ‘API keys’ tab and click ‘Add’ to generate a new key. API.png
  3. Name your API key and click ‘Generate’.

    Copy and save the key in a secured location. We don’t store or retrieve your API keys.

  4. Go to the ‘Allowed domains’ tab and add your app’s domain

Next, add a code snipped to distribute rewards for your users to claim:

import { useClaimTokens } from "@groupos/walletkit/apps"

const { claimTokens, loading } = useClaimTokens({chainId: 1, contractAddress: "0x..."})
const { claimNfts, loading } = useClaimNfts({chainId: 1, contractAddress: "0x..."})

return (
    // ERC-20
    <button
        disabled={loading}
        onClick={() => claimTokens({amount: 10, claimRef: "2month-streak"})}
    >
        {loading ? "Claiming..." : "Claim Streak Points"}
    </button>
    // ERC-721
    <button
        disabled={loading}
        onClick={() => claimNfts({claimRef: "membership"})}
    >
        {loading ? "Claiming..." : "Claim Membership"}
    </button>
)