⚡
claimr
  • Getting started
    • Create an account
    • Sign in to your account
    • Reset password
    • Edit profile
  • ⚡️claimr core components
  • Team roles and management
  • Campaigns
    • Create new campaign
    • Campaign settings
  • Groups
    • Create new group
    • Group settings
  • Quests
    • Create new quest
    • Quest settings
  • Tasks
    • Create new task
    • Task settings
    • Telegram tasks
    • X (Twitter) tasks
    • TikTok tasks
    • Discord tasks
    • YouTube tasks
    • Web3 tasks
      • Connect a wallet
      • Transactions count
      • Wallet balance
      • Token balance
      • NFT balance
      • Link3 balance
      • Mint an NFT (721)
      • Mint an NFT (1155)
      • Verify transactions
    • PoW tasks
    • HTTP request tasks
    • Referral tasks
    • Form tasks
    • Poll tasks
    • Events tasks
    • API tasks
  • Widget
    • Publish campaign
    • Widget configurations
    • Widget attributes
    • Integrate claimr widget into your website
    • claimr widget integrations
      • Google Analytics integration
      • Google Analytics Client ID
      • Google Tag Manager integration
      • HotJar integration
  • Rewards
    • Reward settings
    • Custom rewards
  • Events
    • Daily check-ins
    • Challenges
    • Ranks
    • KOLs
  • Codes
    • Secret codes
    • Invite codes
      • Enter invite code task
      • Claim invite code task
    • Gift codes
  • Test users
  • Pop-ups
    • Into pop-up
    • Completion pop-up
  • API
    • API token
    • API methods
    • User token
  • Webhooks
    • Set up webhooks
    • Assign webhooks
    • Webhook scopes
  • SDK
  • Forms
    • Create forms
    • Form settings
    • Pages
    • Blocks
    • Quizzes
  • Data analytics
    • Activity
    • PoW analytics
    • User information
    • Failed actions
    • Issues analytics
  • How to
    • Create X campaign
    • Create Discord campaign
    • Integrate claimr widget into dApp
    • Integrating claimr widget into Telegram mini app
    • Customize user experience with tags and attributes
    • Add custom points to users
  • UX requirements
    • Campaign UX requirements
    • Group UX requirements
    • Quest card UX requirements
    • Quest UX requirements
    • Task UX requirements
    • User progress UX requirements
    • Pop-ups UX requirements
    • Interactive components UX requirements
Powered by GitBook
On this page
  • Understanding user tokens
  • How it works
  • Behind the scenes
  • Benefits of user tokens
  • Generate user token
  • Initiate token request
  • Response
  • Integrate user token with your application

Was this helpful?

  1. API

User token

By integrating user tokens, you can seamlessly track user progress within your campaigns.

Understanding user tokens

User tokens are like digital keys that link your users' accounts on your platform to their claimr profiles. This connection allows for a smoother, more personalized experience within your campaigns.

How it works

Your users already have accounts on your platform – whether it's a mobile app, a website, or a crypto exchange. They've signed up, verified their identity, and are ready to engage with your claimr campaigns.

Instead of asking them to create another account or log in separately for claimr, user tokens let you seamlessly connect their existing account with their claimr activity.

Behind the scenes

  • Your application sends a special request to claimr server to generate a unique token for each user.

  • This token is then included in claimr widget that you embed on your platform.

  • When a user opens the widget, claimr uses the token to identify them and personalize their experience.

Benefits of user tokens

  • No extra logins: Users enjoy a frictionless experience without having to remember separate credentials.

  • Personalized content: You can tailor the claimr experience to each user's preferences and progress.

  • Seamless cross-device experience: Users can access their claimr profile and progress from any device, as long as they're logged in to your platform.

Generate user token

To generate a user token, follow these steps:

Initiate token request

  • Send a GET request to the /token endpoint from your server.

Include the following required parameters in your request:

  • Account: A unique identifier for the user within your system (e.g., user ID, email address).

  • Platform: A short name representing your organization or platform.

  • Authorization: Include your organization's secret API token as a Bearer authorization header in the request. This authenticates your application's access to the token generation endpoint.

Response

Upon successful request, a unique user token will be generated and return in the response. This token is permanent and does not expire. You can store it securely to avoid repeated generation.

Integrate user token with your application

Once you have generated the user token, you need to integrate it with your web or native application. This allows claimr to recognize and associate the authenticated user with their activities.

  1. Pass the token: Transmit the generated user token from your server to your web or application.

  2. Set the token value: For SDK integration with claimr, you have 2 options:

  • Via the data-user-token attribute in the embed script.

  • Using the SDK method with window.claimr.set_user_token.

PreviousAPI methodsNextWebhooks

Last updated 7 months ago

Was this helpful?

For troubleshooting or support, reach our ⚡️claimr support team or email us .

yo@claimr.io