Fairspin Dev | Web3 GameFi API & Blockchain SDK Documentation
WEB3 GAMEFI INFRASTRUCTURE

The Open Protocol for
Decentralized Gaming.

Fairspin Dev (fairspindev.com) provides the essential API endpoints, SDKs, and smart contract documentation for integrating TruePlay blockchain transparency into next-gen applications.

const fairspin = require('@fairspin/web3-sdk');

async function verifyTransaction(hash) {
  const data = await fairspin.getTxStatus(hash);
  if (data.isVerified) {
    console.log("Blockchain Integrity Confirmed: " + data.blockHeight);
    return true;
  }
}

Core API Reference

GET /v1/ledger/status

Returns the current synchronization status of the Fairspin blockchain node and TruePlay widget integration.

POST /v1/auth/wallet

Authenticates a user session via Web3 wallet signature (Metamask/TrustWallet) for decentralized login.

GET /v1/token/tfs

Retrieves real-time Tokenomics data, including circulating supply, staking pool APY, and burn rate.

POST /v1/game/fairness

Verifies the cryptographic hash of a game round against the server seed to prove outcome randomness.

Integration SDKs

📦
Node.js Client

Server-side integration for game state management.

🐍
Python Tools

Data analysis scripts for blockchain ledger parsing.

⚛️
React Components

UI widgets for displaying TruePlay transparency data.

Developer Changelog

v2.4.0 (Current)
Enhanced Smart Contract Audit
  • Integrated Chainlink Oracles for real-time TFS price feeds.
  • Optimized gas fees for "Play-to-Earn" token distribution.
  • Security patch for wallet connection timeout protocols.
v2.3.5
TruePlay Widget Update
  • Added support for Polygon (MATIC) chain transparency.
  • Improved rendering speed of the public ledger explorer.
  • Fixed API rate limiting for high-frequency trading bots.
v2.1.0
Staking Protocol Launch
  • Released "Hold-to-Earn" smart contracts to mainnet.
  • Updated API documentation for staking pool queries.

Technical Support

What is the API rate limit?
The public API allows for 100 requests per minute. Institutional partners can request higher throughput via the enterprise key.
How do I verify a game hash?
Use the `/v1/game/fairness` endpoint with the session ID. The response will include the client seed, server seed, and final nonce.
Is the TFS token ERC-20 compliant?
Yes, TFS is a standard ERC-20 token deployed on the Ethereum blockchain, fully compatible with all EVM wallets.
Where can I find the Smart Contract address?
All verified contract addresses are listed in the `contracts.json` file in the SDK root directory.