# Welcome to Belong ::doc-figure --- height: 450 width: 800 alt: A stack of violet product modules beside One Stack. Endless Possibilities. caption: Explore the public products for event discovery, venue and community operations, private agents, liquidity, and integrations. placement: lead source-url: https://t.me/belongnet/369 src: https://docs.belong.net/media/social/belong-product-suite.webp --- :: Belong connects event discovery, venue and community operations, private AI agents, and token liquidity tools. Choose a product below to see what it does, who it serves, and where to start. Use the product guides for a practical task, then open the linked reference when you need exact API fields, supported networks, or signing requirements. ## Products ### Belong CheckIn For **venues, organizers, promoters, and guests**. Run check-ins, sell tickets, configure customer rewards, and track promoter campaigns across web, iOS, and Android. [Open the CheckIn documentation](https://docs.belong.net/belong-checkin) · [Use CheckIn](https://checkin.belong.net) Start with [Venue Quick Start](https://docs.belong.net/belong-checkin/venue-quickstart) to prepare a venue, [Customer Rewards](https://docs.belong.net/belong-checkin/customer_rewards_guide) to understand an offer, or [Promoter Earnings](https://docs.belong.net/belong-checkin/promoter-earnings-guide) to follow attributed rewards. ### Belong Platform For **communities, creators, brands, and event teams**. Connect hubs, membership passes, event access, gated content, and branded experiences in one platform. [Open the platform documentation](https://docs.belong.net/belong-platform) · [Explore Belong](https://belong.net) Start with [media collections](https://docs.belong.net/guides/media/collection), [event creation](https://docs.belong.net/belong-checkin/event-creation), or the [whitelabel launch kit](https://docs.belong.net/guides/whitelabel), depending on what you want to publish. ### Belong Events For **people planning what to attend**. Find events, event weeks, artists, and venues worldwide, then follow a listing to its schedule and ticket destination. [Open the discovery guide](https://docs.belong.net/belong-events) · [Browse Belong Events](https://belong.events) ### LONG Events For **developers and AI agents working with event data**. Search the event catalogue through REST or MCP, retrieve schedules and artist context, and use the advertised API allowance or payment-per-call access. [Open the LONG Events guide](https://docs.belong.net/long-events) · [Explore LONG Events](https://long.events) ### Crypto Events For **conference visitors and crypto communities**. Explore crypto conferences, protocol meetups, hackathons, and the side events around a conference week. [Open the Crypto Events guide](https://docs.belong.net/crypto-events) · [Browse Crypto Events](https://cryptoevents.ai) ### AI Deploy For **people and teams running their own agents**. Launch an AI agent on your own infrastructure, choose its model provider, and connect supported messaging channels such as Telegram, WhatsApp, or Slack. [Open the AI Deploy documentation](https://docs.belong.net/ai-deploy/overview) · [Launch an agent](https://aideploy.co) Start with [Quick Start](https://docs.belong.net/ai-deploy/quickstart) for the guided setup or [Open Source](https://docs.belong.net/ai-deploy/open-source) for self-hosting. [Private Access](https://docs.belong.net/ai-deploy/private-access) explains how to reach the management dashboard. ### Hexagon MM For **token teams, liquidity desks, and market-making partners**. Monitor orders, fills, and inventory, and manage buy and sell liquidity within operator-defined limits. [Open the Hexagon MM guide](https://docs.belong.net/hexagon-mm) · [Explore Hexagon MM](https://hexagonmm.com) The guide covers the public operating models, execution controls, monitoring, and partner onboarding. ### Belong API & Docs For **developers integrating Belong into their applications or assistants**. Use the REST API, JavaScript SDK, MCP tools, and contract guides to build on the product workflows. [Open the developer overview](https://docs.belong.net/developer-platform) · [Open the live API reference](https://api.belong.net/api/v3/docs) Start with [API authentication](https://docs.belong.net/getting-started/api-docs), [the SDK](https://docs.belong.net/getting-started/sdk), or [MCP connections](https://docs.belong.net/getting-started/mcp). Use [LONG Events](https://docs.belong.net/long-events) when your task is querying the public event catalogue. ## What You Can Build - A venue campaign that rewards eligible visits and attributes referrals through [CheckIn](https://docs.belong.net/belong-checkin/venue-quickstart). - A community experience with event access, media, and your own branding through [Belong Platform](https://docs.belong.net/belong-platform). - A travel or event assistant that retrieves programme data through [LONG Events](https://docs.belong.net/long-events). - A private agent that works in your team's messaging channels through [AI Deploy](https://docs.belong.net/ai-deploy/quickstart). - A liquidity desk with account visibility and controlled execution through [Hexagon MM](https://docs.belong.net/hexagon-mm). - A custom frontend or backend integration through [Belong API & Docs](https://docs.belong.net/developer-platform). Some Belong access workflows use **token gating**: checking whether a wallet holds the digital asset required for entry or content. An **NFT** is a unique digital asset that can represent a ticket or membership. The relevant product guide explains when those concepts apply. ::doc-figure --- height: 450 width: 800 alt: A violet search bar asking What is token-gating? caption: Token gating checks whether a wallet holds the digital asset required for access. placement: inline source-url: https://t.me/belongnet/121 src: https://docs.belong.net/media/social/understand-token-gating.webp --- :: ## What’s Next Choose the product closest to your goal and follow its starting guide. The sidebar groups the documentation by product; technical guides and references remain available within the relevant section. Need support? Contact or join the [Telegram community](https://t.me/belongchat). # API Documentation ::doc-figure --- height: 450 width: 800 alt: Developer tools and digital assets beside Ship Faster with Belong. caption: Use authenticated API requests from a trusted backend and follow the documented inputs and responses. placement: lead source-url: https://t.me/belongnet/362 src: https://docs.belong.net/media/social/build-with-belong.webp --- :: Access Belong’s public API to build, integrate, or automate token-gated experiences. :br Our latest version includes OpenAPI documentation, REST endpoints, and developer-friendly responses. Start here if you are connecting your own application to Belong. First create an API key, then try a read-only request such as listing events before adding writes or payments. **REST** endpoints are HTTP addresses your application calls; the **OpenAPI** reference describes their inputs and responses. ## Production Environment Belong’s production stack powers the live customer experience. You’ll see `Belong` in domains like [checkin.belong.net](https://checkin.belong.net/) and [belong.net](https://belong.net/). Use this tier for all integrations, launch prep, and real user data. ## Getting an API Key Generate API keys from the Belong CheckIn dashboard: - [checkin.belong.net](https://checkin.belong.net/) ## Using the x-api-key Header For protected routes, include your API key in the request headers as `x-api-key`. ```js const response = await fetch('https://api.belong.net/api/v3/events', { method: 'GET', headers: { 'Content-Type': 'application/json', 'x-api-key': '', }, }); const data = await response.json(); console.log(data); ``` ::mermaid ```text flowchart TD accTitle: A protected Belong API request accDescr: A trusted application sends its API key to Belong and receives the endpoint response. A[Create an API key] --> B[Trusted app sends x-api-key] B --> C[Belong checks the request] C --> D[Read the JSON response] ``` :: Keep the key in your trusted application or backend. Begin with a read-only endpoint so you can verify authentication and response handling before adding writes. ## API Versions ### Belong API v3 Use our OpenAPI explorers to browse, test, and integrate faster than ever. | Environment | Base URL | Docs | OpenAPI JSON | LLMs | | ----------- | ---------------------------------------------------------------- | --------------------------------------------- | ------------------------------------------------------------- | ----------------------------------------------------- | | Production | [`https://api.belong.net/api/v3`](https://api.belong.net/api/v3) | [`/docs`](https://api.belong.net/api/v3/docs) | [`/openapi.json`](https://api.belong.net/api/v3/openapi.json) | [`/llms.txt`](https://api.belong.net/api/v3/llms.txt) | --- ### Belong API v2 (Deprecated) Fully deprecated. Use v3 for all integrations. ### Belong API v1 (Legacy) Fully deprecated. ## Getting Started 1. **Explore the docs**:br[Open API interactive Docs](https://api.belong.net/api/v3/docs) 2. **Authenticate if needed**:br Use `x-api-key: ` for protected routes. 3. **Test requests in browser**:br Use the interactive API explorer to run and debug calls directly. 4. **Start building**:br Fetch events, manage addresses, and mint collections via simple REST endpoints. ## Example Use Cases - **Create token-gated events**:br → `POST /events` — Add event with NFT access & visibility rules. - **Autocomplete address input**:br → `GET /adresses/autocomplete?q=Burning` — Get venue suggestions with coordinates. - **Publish Sui NFT collections**:br → `POST /crypto/sui/collection/publish` — Create access tokens for events. - **Run sponsored gas flows with Belong ledger accounting**:br → `GET/POST /sponsorship/*` — Track deposits, balances, settings, and eligibility checks for sponsored EVM flows. - **Accept store payment and issue an NFT** → `POST /checkout/sessions` — Create a hosted, server-owned NFT checkout for an external order. ## NFT Checkout API The NFT Checkout API lets a Shopify or custom store keep its own products and orders while Belong handles crypto payment and NFT issuance. Key routes: - `POST /api/v3/checkout/sessions` — create or replay an idempotent checkout session; requires `checkout:create` API-key permission. - `GET /api/v3/checkout/sessions/:checkoutId` — read the client-safe hosted session using `X-Checkout-Client-Secret`. - `POST /api/v3/checkout/sessions/:checkoutId/webhook/retry` — retry the signed completion webhook; requires `checkout:retry` API-key permission. The server API key and webhook signing secret must stay on the store backend. For the full flow, payloads, SDK embed, top-up behavior, and webhook verification, see [NFT Checkout](https://docs.belong.net/belong-checkin/developer/nft-checkout). ## Sponsorship API Belong API v3 now includes sponsorship ledger endpoints for sponsored on-chain flows such as CheckIn, NFT mint, and future membership flows. For CheckIn promoter reward withdrawals, the same ledger can also authorize a backend-submitted `distribute_promoter_payments` transaction when the venue sponsor has explicitly enabled that operation type. Key routes: - `GET /api/v3/sponsorship/balance?walletAddress=0x...&chainId=...` - `GET /api/v3/sponsorship/usage?walletAddress=0x...&chainId=...` - `GET /api/v3/sponsorship/deposits?walletAddress=0x...&chainId=...` - `GET /api/v3/sponsorship/settings?walletAddress=0x...&chainId=...` - `POST /api/v3/sponsorship/settings` - `POST /api/v3/sponsorship/check` - `POST /api/v3/sponsorship/thirdweb/verify` - `POST /api/v3/sponsorship/thirdweb/complete` - `POST /api/v3/sponsorship/thirdweb/cancel` - `POST /api/v3/sponsorship/deposits/record` - `POST /api/v3/sponsorship/usage/record` - `POST /api/v3/crypto/evm/venue-gasless` - `POST /api/v3/nft-collection/:id/gasless` Authentication summary: - `balance`, `usage`, `deposits`, `settings`, `check`, `thirdweb/complete`, and `thirdweb/cancel` require the authenticated owner/session. - `thirdweb/verify` is called by thirdweb and requires `x-belong-thirdweb-verifier-secret`. - `check`, `deposits/record`, and `usage/record` are rate-limited to reduce reservation, RPC lookup, and ledger-write abuse. - `deposits/record` is integrity-protected by on-chain verification and does not move funds. - `usage/record` requires a server-side Belong API key with `sponsorship:write` (`{ "sponsorship": ["write"] }`). - Browser thirdweb flows must follow `check -> thirdweb sponsored tx with verifier -> thirdweb/complete` when a transaction is broadcast or has a receipt. Use `thirdweb/cancel` only for thirdweb pre-broadcast denials with no `txHash`. - `thirdweb/complete` must include the same `clientId`, `targetAddress`, `callData`, and `nativeValueWei` that were verified before sponsorship. For direct EOA and EIP-7702, usage is recorded against the EOA `actorAddress` or `ownerAddress`; EIP-7702 completion verifies the delegated EOA execution account and wrapped thirdweb call. For ERC-4337, include `smartAccountAddress`. - `thirdweb/cancel` does not accept `sponsorAddress`, `txHash`, or receipt data; it resolves the sponsor server-side and releases only a matching active reservation. - For ERC-4337 account-abstraction transactions, `thirdweb/complete` also verifies `entryPointAddress` and the on-chain `UserOperationEvent`. - Do not expose `usage/record` to browsers or clients; it is only for trusted server integrations. For the full flow, examples, and payloads, see [Sponsored Gas Ledger Guide](https://docs.belong.net/guides/crypto/sponsorship). # MCP Integration ::doc-figure --- height: 450 width: 800 alt: A phone and robotic hand with the words Build Smarter Web3 Apps With MCP. caption: MCP connects an assistant to structured Belong tools; choose the endpoint and authentication model for your client. placement: lead source-url: https://t.me/belongnet/275 src: https://docs.belong.net/media/social/mcp-assistants.webp --- :: You can connect AI assistants and developer tools to Belong using [Model Context Protocol (MCP)](https://modelcontextprotocol.io/). MCP gives an assistant named tools with defined inputs and outputs. For example, an organizer can ask for upcoming events while the client calls the event tool in the background. Choose the authentication route below before connecting a client: public assistants and trusted backend integrations use different endpoints. This allows you to: - Ask natural-language questions about your events or places - Interact with your token collections and schedules - Use Belong's API without writing custom integration code Belong has two MCP surfaces: | Use case | Endpoint | Auth | | -------------------------------------------- | ----------------------------------------------------------- | --------------------------------- | | Public AI assistants and external connectors | `https://join.belong.net/functions/v1/belong-agent-mcp/mcp` | OAuth 2.1 with email-code sign-in | | Trusted backend or first-party integrations | `https://api.belong.net/mcp` | `x-api-key` | Use the public assistant MCP for ChatGPT-style or OAuth-capable remote MCP clients. Use the API-key MCP only from trusted developer tooling, servers, or first-party integrations that already hold a Belong API key. ::mermaid ```text flowchart TD accTitle: Choose the MCP connection accDescr: Public assistants use the OAuth connector; trusted integrations use the backend API-key connector. A[Choose your client context] --> B[Public assistant] A --> C[Trusted backend or developer tool] B --> D[Public MCP with OAuth sign-in] C --> E[Backend MCP with x-api-key] ``` :: The endpoint choice sets the authorization boundary. The public assistant flow uses scoped user access and Belong confirmation links for sensitive actions; the backend flow belongs in trusted tooling. ## Getting Started Belong provides ready-to-use MCP servers. Choose the endpoint that matches your integration. ### Public Assistant MCP This is the recommended endpoint for external assistants: | Environment | MCP Server URL | | ----------- | ------------------------------------------------------------------------------------------------------------------------ | | Production | [`https://join.belong.net/functions/v1/belong-agent-mcp/mcp`](https://join.belong.net/functions/v1/belong-agent-mcp/mcp) | The public assistant MCP uses OAuth 2.1, PKCE, scoped permissions, and email-code sign-in. Protected actions such as organizer updates, venue operations, and signing-link preparation require the user to connect their Belong account. Sensitive wallet or payment operations return a Belong confirmation link rather than executing directly in chat. ### Backend API-Key MCP The backend MCP remains available for trusted integrations: | Environment | MCP Server URL | | ----------- | ---------------------------------------------------------- | | Production | [`https://api.belong.net/mcp`](https://api.belong.net/mcp) | This endpoint uses the same `x-api-key` header as the Belong REST API. Follow [Getting an API Key](https://docs.belong.net/getting-started/api-docs#getting-an-api-key) to create one for your environment. ### LLM Manifest MCP-capable clients that support discovery can bootstrap backend API-key tooling from the plain-text manifest at [`https://api.belong.net/api/v3/llms.txt`](https://api.belong.net/api/v3/llms.txt). OAuth-capable public assistants should use the public assistant MCP endpoint above and its OAuth discovery metadata. ## How to Connect with AI Tools MCP clients commonly use JSON configuration like the examples below. ::note Belong uses **Streamable HTTP** . The public assistant MCP responds with JSON when the client accepts JSON and streams tool calls as `text/event-stream` when the client advertises SSE support. :: ### Public Assistant MCP For OAuth-capable clients that support remote MCP servers: ```json { "mcpServers": { "belong": { "url": "https://join.belong.net/functions/v1/belong-agent-mcp/mcp" } } } ``` ### Backend API-Key MCP For trusted clients or servers that use a Belong API key: ```json { "mcpServers": { "belong-api": { "url": "https://api.belong.net/mcp", "headers": { "x-api-key": "YOUR_API_KEY_HERE" } } } } ``` For MCP clients that only support local (stdio) servers, use a remote proxy only with the backend API-key MCP: ```json { "mcpServers": { "belong-api": { "command": "npx", "args": [ "mcp-remote", "https://api.belong.net/mcp", "--header", "x-api-key: ${AUTH_TOKEN}" ], "env": { "AUTH_TOKEN": "YOUR_API_KEY_HERE" } } } } ``` This allows local-only clients to communicate with Belong's backend MCP through a local proxy. ::warning Replace `YOUR_API_KEY_HERE` with your actual Belong API key. Keep API keys server-side or in trusted developer tooling only; do not paste API keys into public assistant chats. :: ## How to Connect ### Cursor 1. Open Cursor 2. Go to `Cursor Settings` → `MCP` → `Add new global MCP server` 3. Paste the public assistant MCP or backend API-key MCP configuration above, depending on the auth model your workspace supports ![Cursor MCP Settings](https://docs.belong.net/media/mcp-cursor.png) ### Claude Desktop 1. Download and install [Claude Desktop](https://claude.ai/download) 2. Open the configuration file: - **macOS**: `~/Library/Application Support/Claude/claude_desktop_config.json` - **Windows**: `%APPDATA%\Claude\claude_desktop_config.json` 3. Add the public assistant MCP or backend API-key MCP configuration above, depending on the auth model your client supports ![Claude Desktop Config File](https://docs.belong.net/media/mcp-cloude.png) ### Postman 1. Open Postman 2. Click `Add` → Select `MCP` 3. Enter the backend MCP server URL: `https://api.belong.net/mcp` 4. Go to the `Headers` section and add `x-api-key` with your API key value ![Postman MCP Request](https://docs.belong.net/media/mcp-postman.png) ## What You Can Do Once connected, you can ask your AI assistant questions like: - "Show me all my upcoming events" - "What's the current value of my tokens?" - "Create a new event for next Friday" - "List all my venues" The AI will interact with your Belong account directly through the MCP connection, making it easy to manage your events and tokens without switching between applications. ## Need Help? If you encounter any issues, refer to the [Claude Desktop quickstart guide](https://modelcontextprotocol.io/quickstart/) for detailed integration steps, or contact our support team. # SDK ::doc-figure --- height: 450 width: 800 alt: "A code card and robotic hand with the words Belong SDK: Web3 Integration, Simplified." caption: Embed the widget in the storefront; create merchant checkout sessions and verify completion on the store backend. placement: lead source-url: https://t.me/belongnet/214 src: https://docs.belong.net/media/social/javascript-sdk-widget.webp --- :: Use the SDK when you need a Belong experience inside an existing website. For a store checkout, your backend creates the session and the widget displays it in the storefront; the store continues to own its catalog and order records. Start with the linked NFT Checkout guide before choosing a payment target. ::note For new merchant NFT payment integrations, use `PaymentTarget.Checkout` . The older event-ticket and hub-minting payment targets remain legacy surfaces. :: `@belongnet/sdk` - the official JavaScript SDK for integrating the Belong widget into your website or application. It enables seamless payment experiences, NFT access checks, and event interactions — all from your frontend. The hosted NFT checkout keeps the store's products and orders in its own system while Belong handles wallet payment, NFT issuance, and signed completion notifications. See [NFT Checkout](https://docs.belong.net/belong-checkin/developer/nft-checkout) for the complete server and storefront integration. To get started with implementation, visit the full SDK documentation or check out the Github repository. - [View SDK Documentation](https://belongnet.github.io/sdk/) - [Github Repository](https://github.com/belongnet/sdk) - [NFT Checkout Guide](https://docs.belong.net/belong-checkin/developer/nft-checkout) # Smart Contracts ::doc-figure --- height: 450 width: 800 alt: A purple robot surrounded by HubRegistry, HubMembership, and CheckIn labels beside Belong Smart Contracts v2. caption: The contract architecture separates hub registration, membership, and check-in logic. placement: lead source-url: https://t.me/belongnet/236 src: https://docs.belong.net/media/social/modular-smart-contracts.webp --- :: # Smart Contracts v2 This section of the repository contains the second-generation smart contracts designed for the **check-in system** and related hub membership logic within the Belong ecosystem. Use this page to find the contract source and understand how hubs, membership, and check-in fit together. A **hub** is the venue or community container; its membership rules determine who can use the access flow. Application developers can start with the [API](https://docs.belong.net/getting-started/api-docs) before working directly with contract code. View the source code and documentation here: :br 👉 [GitHub — checkin-contracts](https://github.com/belongnet/checkin-contracts/) --- ## 🧩 Architecture Overview The **Smart Contracts v2** are modular and built with extensibility in mind. :br They define the core logic for hub membership, user verification, and activity check-ins. ### Main Components #### `HubRegistry` - Manages registration and ownership of hubs. - Keeps track of hub metadata and authorized administrators. - Provides access control for other contracts interacting with specific hubs. #### `Membership` - Handles user memberships within hubs. - Supports joining and leaving hubs, as well as assigning roles. - Integrates with `HubRegistry` for permission validation. #### `CheckIn` - Implements the check-in mechanism for events or hubs. - Verifies user membership and eligibility. - Emits on-chain events for transparency and analytics. #### `Utils` and `Interfaces` - Contain shared utilities and standardized interfaces for interoperability. - Ensure that external integrations can interact safely with the core contracts. --- ## ⚙️ Technical Details - **Language:** Solidity - **Framework:** Hardhat - **Network Support:** EVM-compatible chains (BNB, Polygon, Skale, etc.) - **Version:** `v2` branch (active development) # Hexagon MM ::doc-figure --- height: 900 width: 1440 alt: The Hexagon MM demo cockpit with portfolio metrics, market charts, an AI desk brief, and execution controls. caption: The public cockpit image uses demo data to illustrate the market-making workspace. placement: lead source-label: Product website source-url: https://hexagonmm.com src: https://docs.belong.net/media/products/hexagon-mm.webp --- :: ## Overview [Hexagon MM](https://hexagonmm.com) gives token teams and liquidity desks visibility into orders, fills, inventory, and market-making execution. Teams can monitor an external market maker's activity or operate their own desk with explicit execution limits. A **CEX** is a centralized exchange. A **DEX** is a decentralized exchange where liquidity and trades settle on-chain. Hexagon MM's public product information lists Gate and PancakeSwap as live, with MEXC, Binance, and OKX connector work handled through partner onboarding. ## Choose an operating model | Your task | Starting point | | -------------------------------------------- | ------------------------------------------------------------------------------------------- | | Monitor activity and receive incident alerts | Read-only observer access and monitoring credentials | | Run a desk's CEX execution | Desktop application, separately scoped write credentials, and configured execution controls | | Review an on-chain correction | A prepared action with explicit Ledger signing | | Offer the control room under your own brand | Partner onboarding for a branded, isolated client deployment | The desktop application runs its worker on loopback. An optional hosted observer provides monitoring with read-only credentials. Keep the credentials and operating permissions aligned with the model you choose. ## Get started 1. Review the [public product information](https://hexagonmm.com) and [token launch liquidity guide](https://hexagonmm.com/assets/token-launch-liquidity-guide.pdf). 2. Prepare the token, trading pairs, exchanges, on-chain liquidity venues, and monitoring or execution goals for the desk. 3. Use the [onboarding call](https://calendly.com/belongnet/30-min-call-with-jay) to confirm the supported connectors and deployment requirements for that mandate. 4. During onboarding, configure the desk's deployment, ledger, secret storage, account labels, credential scopes, and alert routing. 5. Review monitoring and controls with the operator before enabling live execution. A **mandate** is the set of markets, accounts, objectives, and limits the desk is allowed to operate under. Branded partner deployments are configured during onboarding. ## Understand an execution action Every execution action follows the same documented sequence: 1. **Arm:** an operator arms a session with an expiry. 2. **Check controls:** the venue switch, kill switch, notional caps, price band, and open-order limit govern the action. 3. **Execute:** apply the approved CEX action or explicitly sign the prepared on-chain correction. 4. **Record:** the execution log records the result, including applied, submitted, simulated, blocked, or failed attempts. **Notional** is the value of an order or set of orders. A per-order cap limits one action; a rolling-window cap limits activity over the configured period. ## AI companion and alerts The AI companion reads desk context such as the order book, risk, inventory, and profit and loss. It can explain the state of the desk and draft a bounded proposal for review. Human approval takes place in the authenticated application, with the execution controls still applied. Telegram monitoring reports incidents with their venue or account and supporting observations. Use the dashboard and execution log to investigate the underlying activity and outcome. ## Partner deployments Partners can offer a dashboard and desktop experience under their own branding. The public partner model uses a separate deployment, ledger, and secrets for each client token. See the [partner edition](https://hexagonmm.com/partners.html) and discuss its connector, licensing, and onboarding requirements with the team. Public feature details, current venue coverage, and pricing: [hexagonmm.com](https://hexagonmm.com). # Belong API & Docs ::doc-figure --- height: 450 width: 800 alt: Developer tools and digital assets beside Ship Faster with Belong. caption: Choose the interface for your application, then follow its authentication and transaction requirements. placement: lead source-url: https://t.me/belongnet/362 src: https://docs.belong.net/media/social/build-with-belong.webp --- :: ## Overview Use the Belong developer platform to integrate events, hubs, access, payments, rewards, and related product operations into your own application or assistant. Start with the interface that matches your integration. The REST API defines application requests, the SDK embeds supported frontend experiences, MCP exposes structured tools to assistants, and the contract guides explain chain-specific operations. ## Choose an interface | You are building | Start here | | ---------------------------------------------------------- | ----------------------------------------------------------------------------------------------------- | | A backend integration with Belong | [API authentication and access](https://docs.belong.net/getting-started/api-docs) | | A frontend with an embedded Belong experience | [JavaScript SDK](https://docs.belong.net/getting-started/sdk) | | An assistant that creates or manages Belong resources | [MCP connections](https://docs.belong.net/getting-started/mcp) | | A venue, payment, or rewards integration | [CheckIn integration overview](https://docs.belong.net/belong-checkin/developer/integration-overview) | | An external store that issues an NFT after checkout | [NFT Checkout](https://docs.belong.net/belong-checkin/developer/nft-checkout) | | An application that searches the worldwide event catalogue | [LONG Events REST and MCP](https://docs.belong.net/long-events) | ## Authentication and execution The [API guide](https://docs.belong.net/getting-started/api-docs) explains `x-api-key` authentication for trusted integrations. The [MCP connection guide](https://docs.belong.net/getting-started/mcp) distinguishes the public OAuth connector from the backend API-key endpoint. Tools that prepare a blockchain operation can return transaction parameters for the caller to sign. Follow each response's documented execution path; some sponsored operations may be submitted by the backend. The [CheckIn crypto guide](https://docs.belong.net/guides/crypto/checkin) and [MCP tool reference](https://docs.belong.net/mcp/overview) cover those inputs, outputs, and conditions. ## Product integration guides - **Venue operations:** [CheckIn API reference](https://docs.belong.net/belong-checkin/developer/api-reference), [MCP tools](https://docs.belong.net/belong-checkin/developer/mcp-tools), [POS payment requests](https://docs.belong.net/belong-checkin/developer/webhooks-and-pos), and [networks](https://docs.belong.net/belong-checkin/developer/networks). - **Community and content:** [Belong Platform](https://docs.belong.net/belong-platform), [media collections](https://docs.belong.net/guides/media/collection), and the [whitelabel launch kit](https://docs.belong.net/guides/whitelabel). - **Your own agents:** [AI Deploy](https://docs.belong.net/ai-deploy/overview) and its [enterprise API and MCP setup](https://docs.belong.net/ai-deploy/enterprise-api). - **Event discovery:** [LONG Events](https://docs.belong.net/long-events), with its own [REST contract](https://long.events/openapi.json) and [agent documentation](https://long.events/docs/agents). ## Contract guides Use the guide for the chain and operation you are implementing: - [Smart contract architecture](https://docs.belong.net/getting-started/contracts) - [EVM NFT minting](https://docs.belong.net/guides/crypto/minting) - [Starknet NFT minting](https://docs.belong.net/guides/crypto/starknet) - [Sui NFT minting](https://docs.belong.net/guides/crypto/sui) - [Sponsored gas](https://docs.belong.net/guides/crypto/sponsorship) - [LONG staking](https://docs.belong.net/guides/crypto/staking) - [LONG vesting](https://docs.belong.net/guides/crypto/vesting) ## Reference and machine-readable documentation - [Live application API reference](https://api.belong.net/api/v3/docs) - [Backend MCP tool reference](https://docs.belong.net/mcp/overview) - [Documentation manifest](https://docs.belong.net/llms.txt) and [full documentation text](https://docs.belong.net/llms-full.txt) - [Live API documentation manifest](https://api.belong.net/api/v3/llms.txt) The product guides supply the operating context; the API and tool references specify the exact fields, network support, and signing requirements. # Belong CheckIn Guide for MCP ::doc-figure --- height: 450 width: 800 alt: A transparent campaign-budget vessel with the words Marketing With No Surprises. caption: Fund the venue campaign budget before inviting customers; each later customer payment is a separate operation. placement: lead source-url: https://t.me/belongnet/223 src: https://docs.belong.net/media/social/funded-campaign-budget.webp --- :: ## Overview This guide explains how to manage **venue deposits**, **customer payments**, **promoter distributions**, **venue rule updates**, and **payment cancellations** using MCP tools for the **Belong CheckIn** workflow on EVM-compatible blockchains. The process supports **bounty configurations** (e.g., visit and spend bounties), **referrals**, sponsored gas eligibility, and venue settings. For detailed tool specifications, see [CheckIn MCP Tools](https://docs.belong.net/mcp/tools-check-in). This is the developer workflow behind a venue campaign. The venue funds a reward budget, the customer completes a payment, and configured customer or promoter rewards are accounted for through the on-chain flow. A **bounty** is the reward amount or spend percentage configured by the venue; use the [Venue Quick Start](https://docs.belong.net/belong-checkin/venue-quickstart) for dashboard setup. > **Prerequisites:** Make sure [MCP integration](https://docs.belong.net/getting-started/mcp) is set up and your API key is configured. ## Process Flow ::mermaid ```text flowchart TD; A[Start: Venue Setup] --> B[Venue Deposit] B --> C[Configure Rules] C --> D[Customer Payment to Venue] D --> E[Promoter Payment Distribution] E --> F[Rewards Distributed] ``` :: | Enum | Description | Values | | ------------------------- | ---------------------------------- | ------------------------------------------------------------- | | **PaymentTypes** | Defines accepted payment tokens. | `0`: NoType · `1`: USDC · `2`: LONG · `3`: Both | | **BountyTypes** | Defines reward trigger types. | `0`: NoType · `1`: VisitBounty · `2`: SpendBounty · `3`: Both | | **BountyAllocationTypes** | Defines bounty recipient. | `0`: NoType · `1`: ToPromoter · `2`: ToCustomer · `3`: Both | | **LongPaymentTypes** | Defines LONG token handling logic. | `0`: NoType · `1`: AutoStake · `2`: AutoConvert | --- ## Important Notes ### Owner vs Venue Address For venue management operations, the API now distinguishes two addresses: - `ownerAddress` — the main EOA wallet used for ownership/auth checks. It must belong to the authenticated user. - `venueAddress` — the target venue account used in on-chain calls and signatures. Behavior notes: - `venueDeposit` and `updateVenueSettings` validate ownership using `ownerAddress`. - Transactions are still prepared for `venueAddress`. - Existing venue records are protected: if a venue already belongs to another user, update/deposit is rejected with ownership error. - Venue storage is keyed by `venueAddress + chainId`, so one owner can manage multiple venue addresses. - Venue can be linked to one hub (`hubId`) and one activity (`activityId`). - Each hub/activity can reference only one venue. ### Gasless Venue Flag `venueDeposit` and `updateVenueSettings` also support `gasless?: boolean`. - `gasless: true` enables sponsorship eligibility checks for the venue. - `venue` responses now include `gasless`. - For sponsored flows, the venue flag is only one part of the check. The actual sponsor balance, allowed operations, and reservations are validated through the sponsorship API. See [Sponsored Gas Ledger](https://docs.belong.net/sponsorship). ### Bounty Configuration Validation The system validates bounty configurations based on `bountyType` and `bountyAllocationType` at the service layer (in `getAndValidateBountyAllocations` method): 1. **Bounty Type Validation** (`bountyType`): - `NoType (0)`: Both `visitBountyAmount` and `spendBountyPercentage` must be `0` for all allocations - `VisitBounty (1)`: `spendBountyPercentage` must be `0` for all allocations - `SpendBounty (2)`: `visitBountyAmount` must be `0` for all allocations - `Both (3)`: `visitBountyAmount` and `spendBountyPercentage` must be non-negative. Active allocation can use visit, spend, or both. 2. **Bounty Allocation Type Validation** (`bountyAllocationType`): - `ToPromoter (1)`: `toCustomerBounty` must be `{ visitBountyAmount: 0, spendBountyPercentage: 0 }` - `ToCustomer (2)`: `toPromoterBounty` must be `{ visitBountyAmount: 0, spendBountyPercentage: 0 }` - `NoType (0)`: Both `toCustomerBounty` and `toPromoterBounty` must be zero - `Both (3)`: Both can have non-zero values (subject to `bountyType` validation) 3. **During payment** (`payToVenue`): - System validates that `toCustomerBounty` and `toPromoterBounty` are provided from the database - Validates venue token balance (must be > 0) - Validates promoter exists if `bountyAllocationType` is `ToPromoter` or `Both` - Validates customer address ownership **Example error scenarios:** - `bountyType = 3` (Both), `bountyAllocationType = 1` (ToPromoter), `toPromoter = {visitBountyAmount: 1, spendBountyPercentage: -1}` - Result: Validation fails - values must be non-negative - `bountyAllocationType = 1` (ToPromoter), `toCustomerBounty = {visitBountyAmount: 5, spendBountyPercentage: 2}` - Result: Validation fails - `toCustomerBounty` must be zero when `bountyAllocationType = ToPromoter` ### Bounty Allocation Types The `bountyAllocationType` enum values match the contract: - `0`: NoType — No bounty allocation - `1`: ToPromoter — Bounty goes to promoter only - `2`: ToCustomer — Bounty goes to customer only - `3`: Both — Bounty split between customer and promoter ### LONG Payment Preconditions For LONG token payments (`paymentIn = 2`), the system validates that the escrow contract has sufficient LONG token balance before processing the payment. If the escrow balance is insufficient, the request will fail with `INSUFFICIENT_BALANCE` error. ### Bounty Allocations The API requires `toCustomerBounty` and `toPromoterBounty` in `venueDeposit`. In `updateVenueSettings`, these fields are optional and used when reward config must be changed. These fields define the bounty distribution: - `toCustomerBounty`: Required object with `visitBountyAmount` (USDC, human-readable) and `spendBountyPercentage` (0-100, human-readable) - `toPromoterBounty`: Required object with `visitBountyAmount` (USDC, human-readable) and `spendBountyPercentage` (0-100, human-readable) **Validation:** All bounty allocations are validated at the service layer using the `getAndValidateBountyAllocations` method, which checks: - Values must match the `bountyAllocationType`: - If `bountyAllocationType = ToPromoter`, then `toCustomerBounty` must be `{ visitBountyAmount: 0, spendBountyPercentage: 0 }` - If `bountyAllocationType = ToCustomer`, then `toPromoterBounty` must be `{ visitBountyAmount: 0, spendBountyPercentage: 0 }` - If `bountyAllocationType = NoType`, both must be zero - If `bountyAllocationType = Both`, both can have non-zero values - Values must match the `bountyType` constraints (see Bounty Configuration Validation above) --- ## MCP Integration MCP tools for CheckIn live in the dedicated guide. See [CheckIn MCP Tools](https://docs.belong.net/mcp/tools-check-in) for configuration, inputs, and outputs. ::doc-figure --- height: 450 width: 800 alt: A glowing on-chain reward engine with the words App-Integrated On-Chain Rewards. caption: Venue funding and configured reward rules are prepared through the documented CheckIn tools. placement: inline source-url: https://t.me/belongnet/250 src: https://docs.belong.net/media/social/contracts-on-chain-rewards.webp --- :: --- ## Usage Examples ### Venue Deposit The venue deposit funds the campaign reward budget. Keep the venue payment account separate from the owner address and from each visitor's later payment. ```ts /* * venueDeposit(ownerAddress, venueAddress, rules, amount, referralAddress, toCustomerBounty, toPromoterBounty) * Deposits funds into a venue contract and configures payment rules. */ const depositResult = await mcp.callTool("/crypto/evm/venue-deposit", { method: "POST", body: { chainId: 56, ownerAddress: "0xOwnerEOA", // Required: EOA used for ownership check venueAddress: "0xVenueAddress", amount: 10, // Deposit amount in USDC (human-readable format) rules: { paymentType: 3, // Both (USDC + LONG) bountyType: 3, // Both (Visit + Spend) bountyAllocationType: 3, // Both (ToCustomer + ToPromoter) longPaymentType: 1, // AutoStake }, referralAddress: "0xPromoterAddress", // Optional: promoter address for affiliate tracking toCustomerBounty: { // Required: customer bounty allocation visitBountyAmount: 5, // USDC (human-readable) spendBountyPercentage: 2, // 0-100 (human-readable) }, toPromoterBounty: { // Required: promoter bounty allocation visitBountyAmount: 3, // USDC (human-readable) spendBountyPercentage: 1, // 0-100 (human-readable) }, dailyLimits: 100, // Optional: daily limits for venue hubId: "68da7c5fadf298b35a9b411b", // Optional: hub ID for venue (MongoDB ObjectId) activityId: "68da7c5fadf298b35a9b411b", // Optional: activity ID for venue (MongoDB ObjectId) gasless: true, // Optional: enable sponsorship eligibility checks for this venue }, }); // Response structure: // { // address_token: string, // Token address for approval (USDC) // address: string, // Check-in contract address // venueAddress: string, // params: [venueInfo, protection], // method: { ... }, // ABI-encoded method details // totalAmountToApprove: string // Total amount needed for token approval (deposit amount + all fees) // } // venueInfo contains: rules, venue, amount, affiliateReferralCode, uri // protection contains: nonce, deadline, signature // venue-deposit is crypto-only and always returns signable transaction params. // Sign and broadcast approve + deposit transaction ``` ### Pay to Venue ```ts /* * payToVenue(customer, venueToPayFor, promoter, amount, paymentIn) * Processes customer payments to a venue with automatic bounty distribution. * Note: promoter is optional, but required if bountyAllocationType is ToPromoter or Both. */ let promoter = testAddresses.promoter; // Check if the promoter exists on-chain const isExistsPromoter = await mcp.callTool("/crypto/evm/find-promoter", { method: "POST", body: { chainId: 56, promoter, }, }); // If promoter does not exist, deploy a new one and use the user's address if (isExistsPromoter === "failed") { // You need to deploy a promoter first. See the guide here: Deploy Promoter promoter = account.address.value!; } // Fetch venue data to determine which tokens are available for payment const venueData = await mcp.callTool("/crypto/evm/venue", { method: "POST", body: { address: "0xVenueAddress", chainId: 56, }, }); // Prepare payment request body // Note: Requires authentication - customer address must be owned by authenticated user const body = { chainId: 56, customer: "0xCustomerAddress", // Must be owned by authenticated user venueToPayFor: "0xVenueAddress", promoter: "0xPromoterAddress", // Optional: required if bountyAllocationType is ToPromoter or Both amount: 5, // Payment amount in human-readable format paymentIn: 1, // 1 = USDC, 2 = LONG (enum PaymentTypes) }; // For LONG payments (paymentIn = 2), the system automatically validates // that the escrow contract has sufficient LONG token balance. // If balance is insufficient, the request will fail with INSUFFICIENT_BALANCE error. // Get transaction parameters from MCP const { params, address_token, address, method } = await mcp.callTool( "/crypto/evm/pay-to-venue", { method: "POST", body, }, ); // params structure: [customerInfo, protection] // customerInfo contains: // - paymentInUSDtoken: boolean (true = USDC, false = LONG) // - toCustomer: { visitBountyAmount: string, spendBountyPercentage: string } // - toPromoter: { visitBountyAmount: string, spendBountyPercentage: string } // - customer: address // - venueToPayFor: address // - promoterReferralCode: bytes32 // - amount: string (in wei) // protection contains: nonce, deadline, signature // Convert amount to the correct token units (if needed for approval) const parseAmount: bigint = body.paymentIn === PaymentTypes.LONG ? parseUnits(String(body.amount), 18) // LONG has 18 decimals : parseUnits(String(body.amount), 6); // USDC has 6 decimals // Approve the token for the payment contract (if using ERC20) // Send the payment transaction and wait for confirmation ``` ### Distribute Promoter Payments When a venue sponsor covers this operation, the backend can sign and broadcast `distributePromoterPayments` itself and return only the transaction hash. If backend submission is disabled or the sponsor is not eligible/funded, the tool falls back to the legacy client-submitted transaction params. ```ts /* * distributePromoterPayments(promoter, venue, paymentInUSDC) * Transfers accumulated promoter rewards from a venue contract. */ const distributeResult = await mcp.callTool( "/crypto/evm/distribute-promoter-payments", { method: "POST", body: { chainId: 56, promoter: "0xPromoterAddress", venue: "0xVenueAddress", paymentInUSDC: false, // true = USDC, false = LONG }, }, ); // Backend-submitted response: // { // address: "0xCheckInAddress", // submitted: true, // txHash: "0x...", // transactionStatus: "success" | "pending", // signatureExpiresAt?: string // } // // In this case, do not ask the user to sign another transaction. Store/show the // txHash and refresh the rewards state. // Client-submitted fallback response: // { // address: "0xCheckInAddress", // params: [promoterInfo, protection], // method: { ... } // } // promoterInfo contains: paymentInUSDtoken, promoterReferralCode, venue, amountInUSD // protection contains: nonce, deadline, signature // For fallback responses only, sign and broadcast the distribution transaction. ``` ### Get Venue Data ```ts const venueData = await mcp.callTool("/crypto/evm/venue", { method: "POST", body: { address: "0xVenueAddress", chainId: 56, }, }); // Response: { // venue: "0xVenueAddress", // hubId: "68da7c5fadf298b35a9b411b", // activityId: "68da7c5fadf298b35a9b411b", // gasless: true, // rules: {...}, // remainingCredits: number, // toCustomerBounty: { visitBountyAmount: number, spendBountyPercentage: number }, // toPromoterBounty: { visitBountyAmount: number, spendBountyPercentage: number }, // venueId: string, // venueTokenBalance: string, // usdTokenDeposits: string, // longDeposits: string // } // venueData.venue - Venue address // venueData.hubId - Linked hub ID // venueData.activityId - Linked activity ID // venueData.gasless - Whether sponsorship eligibility checks are enabled for this venue // venueData.rules - Current venue rules (paymentType, bountyType, etc.) // venueData.remainingCredits - Number of free deposits without commission (limit is 2) // venueData.toCustomerBounty - Customer bounty allocation from database // venueData.toPromoterBounty - Promoter bounty allocation from database // venueData.venueId - Venue ID (on-chain identifier) // venueData.venueTokenBalance - Venue ERC-1155 credit balance in USD token units (human-readable format) // venueData.usdTokenDeposits - Current USD token balance remaining in escrow (human-readable format) // venueData.longDeposits - Current LONG balance remaining in escrow (human-readable format) ``` ### Emergency Cancel Payment ```ts /* * emergencyCancelPayment(venue, promoter) * Compatibility-only route. * Server-side execution is temporarily disabled on the backend. */ const cancelResult = await mcp.callTool( "/crypto/evm/emergency-cancel-payment", { method: "POST", body: { chainId: 56, venue: "0xVenueAddress", promoter: "0xPromoterAddress", }, }, ); // Current behavior: backend returns a disabled error ``` ### Update Venue Settings ```ts /* * updateVenueSettings(ownerAddress, venueAddress, paymentType?, longPaymentType?, toCustomerBounty?, toPromoterBounty?, dailyLimits?, hubId?, activityId?, gasless?) * Updates venue settings (payments, rewards, and venue links) in a single operation. * Ownership is verified by ownerAddress, but on-chain venue rules apply to venueAddress. * All fields are optional, but at least one must be provided: paymentType, longPaymentType, toCustomerBounty, toPromoterBounty, dailyLimits, hubId, activityId, or gasless. * For payments: updates paymentType and/or longPaymentType. * For rewards: automatically determines bountyType and bountyAllocationType based on provided bounty values. * Validates all inputs and updates both on-chain rules (if changed) and off-chain database. * If any rules changed, returns transaction parameters for updateVenueRules method. * If rules unchanged, returns only updated data without transaction parameters. */ const updateResult = await mcp.callTool("/crypto/evm/update-venue-settings", { method: "POST", body: { ownerAddress: "0xOwnerEOA", // Required: EOA used for ownership check venueAddress: "0xVenueAddress", chainId: 56, // Payment settings (optional) paymentType: 3, // Optional: 0=NoType, 1=USDC, 2=LONG, 3=Both longPaymentType: 2, // Optional: 0=NoType, 1=AutoStake, 2=AutoConvert // Reward settings (optional) toCustomerBounty: { // Optional: customer bounty allocation // Used to automatically determine bountyType and bountyAllocationType visitBountyAmount: 5, // USDC (human-readable) spendBountyPercentage: 2, // 0-100 (human-readable) }, toPromoterBounty: { // Optional: promoter bounty allocation // Used to automatically determine bountyType and bountyAllocationType visitBountyAmount: 3, // USDC (human-readable) spendBountyPercentage: 1, // 0-100 (human-readable) }, // Additional settings (optional) dailyLimits: 100, // Optional: daily limits for venue hubId: "68da7c5fadf298b35a9b411b", // Optional: hub ID for venue (MongoDB ObjectId) activityId: "68da7c5fadf298b35a9b411b", // Optional: activity ID for venue (MongoDB ObjectId) gasless: true, // Optional: enable sponsorship eligibility checks for this venue }, }); // Response structure (if rules changed): // { // venueAddress: "0xVenueAddress", // chainId: 56, // venueId: "1", // Venue ID from blockchain // gasless: true, // rules: { // Updated venue rules with automatically determined bountyType and bountyAllocationType // paymentType: 3, // bountyType: 3, // Automatically determined from bounty values // bountyAllocationType: 3, // Automatically determined from bounty values // longPaymentType: 2 // }, // dailyLimits: 100, // Present if provided // hubId: "68da7c5fadf298b35a9b411b", // Present if provided // activityId: "68da7c5fadf298b35a9b411b", // Present if provided // toCustomerBounty: { visitBountyAmount: 5, spendBountyPercentage: 2 }, // Present only if provided in input // toPromoterBounty: { visitBountyAmount: 3, spendBountyPercentage: 1 }, // Present only if provided in input // address: "0xCheckInAddress", // Present only if rules changed // params: [rules], // Array with VenueRules struct - present only if rules changed // method: { ... } // ABI-encoded method details - present only if rules changed // } // Response structure (if rules unchanged): // { // venueAddress: "0xVenueAddress", // chainId: 56, // venueId: "1", // gasless: true, // rules: { ... }, // Updated venue rules // dailyLimits: 100, // Present if provided // hubId: "68da7c5fadf298b35a9b411b", // Present if provided // activityId: "68da7c5fadf298b35a9b411b", // Present if provided // toCustomerBounty: { visitBountyAmount: 5, spendBountyPercentage: 2 }, // Present only if provided in input // toPromoterBounty: { visitBountyAmount: 3, spendBountyPercentage: 1 } // Present only if provided in input // // No address, params, or method fields // } // Note: This method replaces the old update-accepted-payments and update-rewards endpoints. // You can now update payments, rewards, and additional settings in a single call. // The method automatically determines bountyType and bountyAllocationType based on // the provided toCustomerBounty and toPromoterBounty values. If these types changed // compared to current venue rules, transaction parameters are returned for on-chain update. // The database is always updated with validated settings. // Sign and broadcast update transaction if address, params, and method are present ``` ### Deploy Promoter ```ts /* * deployPromoter(promoter) * Deploys a promoter contract for the specified wallet address. * Requires authentication and checks for promoter uniqueness and ownership. */ const deployResult = await mcp.callTool("/crypto/evm/deploy-promoter", { method: "POST", body: { chainId: 56, promoter: "0xPromoterAddress", }, }); // Response: { address: "0xFactoryAddress", method: {...} } // Sign and broadcast the transaction to create a referral code ``` ### Find Promoter ```ts /* * findPromoter(promoter) * Verifies if a promoter is registered in the system. * Returns 'success' if the promoter exists with a valid referral code, or 'failed' otherwise. */ const promoterStatus = await mcp.callTool("/crypto/evm/find-promoter", { method: "POST", body: { chainId: 56, promoter: "0xPromoterAddress", }, }); // Response: "success" | "failed" // Promoter status: promoterStatus ``` ### Get Belong CheckIn Storage ```ts /* * getBelongCheckInStorage(chainId) * Retrieves the Belong CheckIn contract storage data including contract addresses, * payment configuration, fees structure, and helper/check-in contract addresses. * Returns data with BigInt values converted to strings for JSON serialization. */ const storage = await mcp.callTool("/crypto/evm/get-belong-check-in-storage", { method: "POST", body: { chainId: 56, }, }); // Response structure: // { // contracts: { // factory: string, // Factory contract address // escrow: string, // Escrow contract address // staking: string, // Staking contract address // venueToken: string, // Venue token contract address // promoterToken: string, // Promoter token contract address // longPF: string, // LONG price feed address // }, // paymentsInfo: { // dexType: number, // DEX type enum value // slippageBps: number, // Max slippage in basis points // router: string, // DEX router address // usdToken: string, // USD token address (USDC) // long: string, // LONG token address // maxPriceFeedDelay: number, // Max delay for price feeds (seconds) // poolKey: string, // Pool key bytes // hookData: string, // Hook data bytes // }, // fees: { // referralCreditsAmount: number, // Referral credit value // affiliatePercentage: number, // Affiliate fee percentage // longCustomerDiscountPercentage: number, // LONG discount for customers // platformSubsidyPercentage: number, // Platform subsidy percentage // processingFeePercentage: number, // Processing fee // buybackBurnPercentage: number, // Buyback and burn percentage // }, // helperContract: string, // Helper contract address // checkInContract: string, // Check-In contract address // } ``` ## Error Handling MCP tools return standardized errors in the response's `error` field. **Example:** ```tson { "error": "VENUE_NOT_FOUND", "message": "The specified venue contract was not found on this chain." } ``` **Common Errors:** - `VENUE_NOT_FOUND` — Venue address not registered or has no venue token balance. - `INSUFFICIENT_FUNDS` — Insufficient deposit balance. - `INSUFFICIENT_BALANCE` — Insufficient balance (e.g., LONG escrow balance insufficient for LONG payments). - `INVALID_SIGNATURE` — Authentication or signing issue. - `UNSUPPORTED_CHAIN` — Chain ID not supported by MCP. - `INVALID_BOUNTY_CONFIGURATION` — Bounty configuration violates contract requirements (e.g., `bountyType = Both` but missing visit or spend bounty). - `INVALID_BOUNTY_PERCENTAGE` — Spend bounty percentage is outside valid range (0-100). - `NO_BOUNTY_CREDITS` — Venue has no venue token balance (venueToken balance is zero). - `PAYMENT_TYPE_NOT_SUPPORTED` — Payment type not compatible with venue rules. --- ✅ **Result:** You now have a complete flow for deposits, payments, promoter rewards, and vesting management in the Belong CheckIn system. # EVM NFT Minting Guide for MCP ::doc-figure --- height: 450 width: 800 alt: A purple minting machine beside the words Just Mint It. caption: Create a collection, prepare the mint, and sign the transaction using the selected chain's workflow. placement: lead source-url: https://t.me/belongnet/67 src: https://docs.belong.net/media/social/mint-digital-assets.webp --- :: ## Overview This document outlines the process of minting NFTs on EVM-compatible blockchains (e.g., BNB, Ethereum, Polygon) using MCP (Model Context Protocol) tools. The workflow involves preparing transactions with MCP tools, signing and broadcasting them on the frontend, and finalizing operations on the backend. The minting process has been updated to use `/deploy-collection` and `/complete-collection` endpoints for deployment, with minting handled via `/evm-mint` (now active) and `/mint-complete`. **Minting** creates a new NFT on the selected network. For frontend developers, the key boundary is preparation versus execution: an MCP response can contain a transaction for the user to sign, while the completion call records the confirmed result. Keep the transaction hash from the wallet so the backend can finalize the same operation. > **📋 Prerequisites:** Ensure [MCP integration](https://docs.belong.net/getting-started/mcp) is set up with your API key. ## Supported Payment Tokens Collections can accept payments in two types of tokens: - **`NATIVE`**- Chain's native token (automatically resolved based on chain ID): - Ethereum (1): ETH - Polygon (137): POL - Celo (42220): CELO - Sepolia (11155111): ETH - Base (8453): ETH - And other EVM chains - **`USDC`** - USD Coin stablecoin (chain-specific addresses are automatically resolved) - **`BUSD`** - Binance USD stablecoin (chain-specific addresses are automatically resolved) > **💡 Note:** When using `paymentToken: 'NATIVE'`, users pay with the chain's native currency (e.g., ETH on Ethereum, POL on Polygon). When using `paymentToken: 'USDC'` or `'BUSD'`, users must approve the collection contract to spend the ERC20 token before minting. ### Price Format All prices (`mintPrice`, `whitelistMintPrice`) should be specified in **human-readable format**: - `1` = $1 (or 1 USDC/ETH/POL) - `7` = $7 - `0.5` = $0.50 - `0.001` = $0.001 The system automatically converts these values to the correct on-chain format based on the token's decimals (18 for native tokens, 6 for USDC). ## Process Flow ::mermaid ```text flowchart TD; A[Start: User Authentication] --> B[Deploy Collection] B --> C[Complete Deployment] C --> D{Payment Token} D --> E[Native Token] D --> F[Approve ERC20 Token] E --> G[Mint NFTs] F --> G G --> H[Complete Mint] H --> I[End: NFTs Minted] ``` :: ## MCP Tools ### 1. Deploy Collection **Tool:** `deploy-collection` **Description:** Prepares a new NFT collection transaction for signing. Updated to use `/crypto/evm/deploy-collection` endpoint. No database collection is created until `complete-collection` confirms the deployment transaction. **Input data:** ```text { name: string, // Collection name symbol: string, // Collection symbol (no spaces allowed) description?: string, // Description feeNumerator: number, // Royalty fraction (basis points, max 6) mintPrice: number, // Mint price in human-readable format (e.g., 1 for $1, 7 for $7, 0.5 for $0.50) whitelistMintPrice: number, // Whitelist mint price in human-readable format (e.g., 0.3 for $0.30) transferable: boolean, // NFT transferability maxTotalSupply: number, // Max NFT count paymentToken: 'NATIVE' | 'USDC' | 'BUSD', // Payment token ('NATIVE' for chain native token like ETH/POL, 'USDC' or 'BUSD' for stablecoin) creator: string, // Creator wallet address chainId: number, // EVM chain ID externalUrl: string | null, // External link (required, can be null) attributes?: Array<{ // Optional attributes trait_type: string, display_type?: string, value: string }>, referralCode?: string // Optional referral code } ``` **Output data:** ```text { params: [{ creator: string, // Creator wallet address paymentToken: string, // Token contract address (resolved from NATIVE/USDC/BUSD input) feeNumerator: number, transferable: boolean, maxTotalSupply: number, mintPrice: string, // Price in wei/token units whitelistMintPrice: string, // Price in wei/token units metadata: { name: string, symbol: string }, contractURI: string }, "0x0...", { nonce: number, deadline: number, signature: string }], verifyingContract: string, // Address of the verifying contract method: object, // ABI-encoded method details for the transaction } ``` > **Note:** The `paymentToken` in output is the resolved token contract address (e.g., `0xEee...` for NATIVE, or USDC/BUSD contract address), automatically converted from the `'NATIVE' | 'USDC' | 'BUSD'` input. ### 2. Complete Deployment **Tool:** `complete-collection` **Description:** Finalizes collection deployment after broadcasting the transaction. Updated to use `/crypto/evm/complete-collection` endpoint. This is the step that persists the backend collection. **Input data:** ```text { chainId: number, // EVM chain ID hash: string, // Deployment transaction hash hubId?: string, // Optional hub ID activityId?: string, // Optional activity ID gasless?: boolean, // Gasless mode whitelist_hubIDs?: string[], // Whitelist hub IDs whitelist_userIDs?: string[] // Whitelist user IDs } ``` The backend reconstructs the collection from the deployment transaction calldata and receipt. It verifies that the transaction was sent to the configured NFT factory and that the deployed collection belongs to the authenticated creator wallet. > **Sponsored minting note:** `gasless: true` only enables sponsorship eligibility for the collection. Sponsor balances, preflight checks, and post-transaction usage recording are handled through the sponsorship API. See [Sponsored Gas Ledger Guide](https://docs.belong.net/guides/crypto/sponsorship). **Output data:** ```text { id: string, // Backend collection ID for minting/media/checkout // Created or updated collection data (includes nftAddress, produce_data, etc.) } ``` > **📸 Media Upload:** After completing the collection deployment, you can add a cover image and NFT images to your collection. See [Upload Collection Media](https://docs.belong.net/guides/media/collection#upload-collection-media) for details. ### 3. Approve Payment Token (Required before Mint if using USDC or BUSD) **⚠️ Important:** If `paymentToken` is set to `"USDC"` or `"BUSD"` (ERC20 tokens), you must approve the collection contract to spend tokens before minting. This step is not needed for `"NATIVE"` tokens (ETH, POL, etc.). **Implementation:** ```typescript // Only needed if paymentToken is "USDC" or "BUSD" const totalAmount = mintTokens.reduce( (sum, token) => sum + token.price * BigInt(token.quantity), BigInt(0), ); await walletClient.writeContract({ address: payingTokenAddress, // USDC or BUSD contract address abi: erc20Abi, functionName: "approve", args: [collectionAddress, totalAmount], }); ``` ### 4. Mint NFT **Tool:** `evm-mint` **Description:** Prepares a crypto NFT minting transaction, returning data for signing. The endpoint does not accept `paymentsMethod` and does not return checkout provider data. **Input data:** ```text { collectionId: string, // Backend collection ID chainId: number, // EVM chain ID walletAddress: string, // Minter's wallet address nfts: Array<{ // NFTs to mint receiver: string, // Receiver address for this NFT (where the NFT will be sent) name: string, // Name of the individual NFT description: string, // Description of the NFT mintPrice: number, // Price in human-readable format (e.g., 1 for $1, 0.5 for $0.50) image?: string, // Image URI (optional) attributes?: Array<{ trait_type: string, display_type?: string, value: string }>, // NFT attributes (optional) external_url?: string, // External link for the NFT (optional) quantity: number, // Quantity to mint (number of copies) animation_url?: string, // Animation URI for video NFTs (optional) youtube_url?: string // YouTube embed URL (optional) }> } ``` **Output data:** ```text { chainId: number, verifyingContract: string, // Collection contract address method: object, // ABI-encoded method details for the transaction params: [ string, // Payment token address (0xEee... for NATIVE or USDC/BUSD contract address) Array, // Receivers array - one address per NFT Array<{ // DynamicPriceParameters array - one per NFT tokenId: bigint, // Token ID (bigint format) price: bigint, // Price in wei/token units (bigint format) tokenUri: string // Metadata URI }>, Array<{ // SignatureProtection array - one per NFT nonce: bigint, // Nonce for replay protection deadline: bigint, // Expiration timestamp signature: string // ECDSA signature (hex format, 0x...) }> ], tokens: Array<{ token_id: string, token_uri: string, minted_price: number, name: string, image?: string, attributes?: Array<{...}>, description?: string, external_url?: string, animation_url?: string, youtube_url?: string }> } ``` **Important:** All arrays (`receivers`, `dynamicPriceParameters`, `protections`) must have the same length and be synchronized by index. Element at index `i` in each array corresponds to the same mint operation. The signature in `protections[i]` is generated for the parameters in `dynamicPriceParameters[i]` and `receivers[i]`. ### 5. Complete Mint **Tool:** `mint-complete` **Description:** Completes the NFT minting process and saves token data. Requires authenticated user. **Input data:** ```text { chainId: number, // EVM chain ID hash: string // Mint transaction hash } ``` The backend reconstructs `collectionId`, `walletAddress`, and token data from the mint transaction calldata, receipt logs, and token metadata URI. All minted receivers must belong to the authenticated user on the same chain. **Output data:** ```text Array<{ id: string, name?: string, hash?: string, address: string, block_number?: string, token_id: string, token_uri?: string, image?: string, userId?: string, minted_price?: number, attributes?: Array<{...}>, cryptoAddress?: { address: string } }> ``` ## Usage ### Deploy Collection ```js const deployResult = await mcp.callTool("/crypto/evm/deploy-collection", { data: { name: "My Collection", symbol: "MC", description: "My awesome NFT collection", feeNumerator: 5, mintPrice: 1, // $1 in human-readable format whitelistMintPrice: 0.5, // $0.50 for whitelisted users transferable: true, maxTotalSupply: 1000, chainId: 1, creator: account.address, paymentToken: "USDC", // or "NATIVE" for ETH, or "BUSD" for BUSD externalUrl: "https://example.com", }, }); const { params, verifyingContract, method } = deployResult; const hash = await walletClient.writeContract({ address: verifyingContract, abi: [method], functionName: method.name, args: params, }); ``` ### Complete Deployment ```js const collection = await mcp.callTool("/crypto/evm/complete-collection", { data: { chainId: 1, hash, }, }); const collectionId = collection.id; ``` ### Create Referral Code ```js const { address, method } = await mcp.callTool( "/crypto/evm/create-referral-code", { data: { chainId: 1 }, }, ); await walletClient.writeContract({ address, abi: [method], functionName: method.name, }); ``` ### Get Referral Code by Creator ```js const { referralCode } = await mcp.callTool( "/crypto/evm/get-referral-code-by-creator", { data: { chainId: 1, walletAddress: "0x1234567890abcdef1234567890abcdef12345678", }, }, ); // referralCode is a bytes32 hash, returns zeroHash if no valid code exists ``` ### Mint NFTs ```js const mintResult = await mcp.callTool("/crypto/evm/evm-mint", { data: { collectionId, chainId: 1, walletAddress: account.address, nfts: [ { receiver: account.address, // Receiver address (where NFT will be sent) name: "NFT 1", description: "First NFT", mintPrice: 1, quantity: 1, }, // $1 per NFT ], }, }); const { verifyingContract, params } = mintResult; // params structure: [paymentToken, receivers, dynamicPriceParameters, protections] const [paymentTokenAddress, receivers, dynamicPriceParameters, protections] = params; // Check if payment token is ERC20 (not native token) const isNativeToken = paymentTokenAddress.toLowerCase() === "0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee"; if (!isNativeToken) { // Approve ERC20 token (e.g., USDC, BUSD) // Calculate total amount needed for all NFTs const totalAmount = dynamicPriceParameters.reduce( (sum, item) => sum + BigInt(item.price), 0n, ); await walletClient.writeContract({ address: paymentTokenAddress, // ERC20 token address abi: erc20Abi, functionName: "approve", args: [verifyingContract, totalAmount], }); } // Call mintDynamicPrice function const mintHash = await walletClient.writeContract({ address: verifyingContract, abi: mintAbiV2, // Use mint-abi-v2.ts ABI functionName: "mintDynamicPrice", args: [paymentTokenAddress, receivers, dynamicPriceParameters, protections], }); ``` **Note:** The `mintDynamicPrice` function signature is: ```solidity mintDynamicPrice( address expectedPayingToken, address[] calldata receivers, DynamicPriceParameters[] calldata dynamicPriceParameters, SignatureProtection[] calldata protections ) external payable ``` Where `DynamicPriceParameters` is `(uint256 tokenId, uint256 price, string tokenUri)` and `SignatureProtection` is `(uint256 nonce, uint256 deadline, bytes signature)`. ### Complete Mint ```js await mcp.callTool("/crypto/evm/mint-complete", { data: { chainId: 1, hash: mintHash, }, }); ``` ## Errors MCP tools return errors in the standard MCP format, with details in the `error` field (e.g., "INVALID\_CHAIN\_ID", "INSUFFICIENT\_BALANCE"). # Sponsored Gas Ledger Guide ::doc-figure --- height: 562 width: 800 alt: A ticket illustration with the words No Gas Needed, Mint the Pass. caption: "" placement: lead source-url: https://t.me/belongnet/433 src: https://docs.belong.net/media/social/sponsored-network-fees.webp --- :: ## Overview Belong API includes a sponsorship ledger for shared sponsored-gas flows. Use this guide when integrating gas sponsorship in a browser or trusted service. Treat the ledger as budget accounting and verification: reserving gas allowance is a different step from broadcasting a transaction. A customer can still owe the purchase price even when the network fee is sponsored. This is a general backend layer, not a CheckIn-only feature. It is designed to support: - CheckIn - NFT mint - future NFT membership flows - other sponsored EVM operations For browser-based thirdweb sponsorship, the backend does **not** broadcast the transaction. It only: - verifies sponsor top-ups into the shared platform wallet - tracks sponsor balances inside Belong API - stores sponsor operation settings - checks eligibility before a sponsored operation - verifies thirdweb sponsored-gas callbacks against the checked calldata - records sponsored usage from transaction receipts after completion There is one server-side exception: CheckIn promoter reward withdrawals can be backend-submitted when the venue sponsor has explicitly enabled `distribute_promoter_payments` and has enough gas-bank balance. In that flow, Belong API reserves the estimated gas, signs and broadcasts `distributePromoterPayments`, returns the tx hash to the client, and later records actual receipt gas against the sponsor ledger. For browser-based thirdweb sponsored gas, the enforced flow is: 1. call `POST /api/v3/sponsorship/check` 2. submit the sponsored transaction through thirdweb 3. thirdweb calls `POST /api/v3/sponsorship/thirdweb/verify` 4. after the transaction has a receipt, the frontend calls `POST /api/v3/sponsorship/thirdweb/complete` If thirdweb rejects the sponsored transaction before broadcast and there is no `txHash`, the frontend may call `POST /api/v3/sponsorship/thirdweb/cancel` to release the temporary reservation. Once a transaction is broadcast or a receipt exists, use `/thirdweb/complete` even when the receipt failed, because sponsored gas may already have been spent. For server-side integrations that do not use thirdweb verifier callbacks, a trusted backend can still call `POST /api/v3/sponsorship/usage/record` directly with a Belong API key. There should be no sponsored execution path that bypasses the check and ledger reservation. ## Core Model Ledger key: - `sponsorAddress + chainId` Balance formula: - `remainingWei = confirmed deposits - recorded/confirmed/failed usage` `failed` usage is counted as spent because a failed on-chain transaction can still burn sponsored gas. Do not record `failed` usage for operations that were never broadcast. Important properties: - one shared sponsorship wallet can be topped up by many sponsors - sponsor balances are isolated inside Belong API - deposits are idempotent by `txHash` - usage records are idempotent by `txHash` `POST /api/v3/sponsorship/check` reserves a maximum gas budget. Completion records actual gas from on-chain proof: ```text direct tx / EIP-7702 sponsored tx: actualGasWei = receipt.gasUsed * receipt.effectiveGasPrice ERC-4337: actualGasWei = UserOperationEvent.actualGasCost ``` Actual gas may be lower than the reservation. Usage is rejected only when actual gas exceeds the reserved amount. ## Supported Operation Types Current preflight sponsorship checks support: - `approve` - `mint` - `pay_to_venue` Behavior: - `approve` is implicit when a target is `gasless: true` - `mint` and `pay_to_venue` must be explicitly enabled in sponsor settings - `distribute_promoter_payments` can be enabled in sponsor settings, but it is used only by the CheckIn backend-submitted promoter withdrawal flow. It is not a browser `/sponsorship/check` operation. ## Gasless Targets Sponsorship eligibility depends on both the sponsor and the target: - `Venue.gasless` - linked `Activity.gasless` - linked `Hub.gasless` - `NftCollection.gasless` For venues, sponsorship is enabled when the venue itself, its linked activity, or its linked hub has `gasless: true`. For NFT collections, sponsorship is enabled by `NftCollection.gasless`. If `gasless` is disabled for the resolved target, sponsorship check returns `canSponsor: false`. ### Toggle Gasless Targets Venue gasless eligibility can be toggled with: `POST /api/v3/crypto/evm/venue-gasless` ```json { "ownerAddress": "0xOwnerAddress", "venueAddress": "0xVenueAddress", "chainId": 137, "enabled": true } ``` This route requires authentication and venue ownership. It updates off-chain `gasless` settings only; it does not send or sponsor a transaction. NFT collection gasless eligibility can be toggled with: `POST /api/v3/nft-collection/:id/gasless` ```json { "enabled": true } ``` This route requires authentication and collection ownership. It updates `NftCollection.gasless` and keeps the linked hub/activity gasless flag in sync when present. ## API Routes ### Get Balance `GET /api/v3/sponsorship/balance?walletAddress=0x...&chainId=137` - owner-only - returns: - `totalDepositedWei` - `totalSpentWei` - `remainingWei` ### Get Usage `GET /api/v3/sponsorship/usage?walletAddress=0x...&chainId=137` - owner-only - returns sponsorship usage history for that sponsor wallet and chain ### Get Deposits `GET /api/v3/sponsorship/deposits?walletAddress=0x...&chainId=137` - owner-only - returns sponsorship deposit history for that sponsor wallet and chain ### Get Settings `GET /api/v3/sponsorship/settings?walletAddress=0x...&chainId=137` - owner-only - returns: - `defaultOperationTypes: ["approve"]` - `additionalOperationTypes` ### Update Settings `POST /api/v3/sponsorship/settings` ```json { "walletAddress": "0x...", "chainId": 137, "additionalOperationTypes": ["mint", "pay_to_venue", "distribute_promoter_payments"] } ``` - owner-only - updates sponsor-level allowed operation types ### Record Deposit `POST /api/v3/sponsorship/deposits/record` ```json { "sponsorAddress": "0x...", "chainId": 137, "txHash": "0x...", "amountWei": "10000000000000000" } ``` Behavior: - verifies the on-chain transaction - checks: - `chainId` - `from == sponsorAddress` - `to == platform sponsorship wallet for the chain` - `value == amountWei` - records the deposit idempotently by `txHash` - rate-limited to reduce repeated RPC lookups - does not move funds or withdraw from any wallet ### Check Sponsorship Eligibility `POST /api/v3/sponsorship/check` For `approve`: ```json { "chainId": 137, "operationType": "approve", "amountWei": "25000000000000000", "approveAmountWei": "50000000", "venueAddress": "0xVenueAddress", "ownerAddress": "0xUserWallet", "tokenAddress": "0xTokenAddress", "spenderAddress": "0xSpenderAddress" } ``` For `mint`: ```json { "chainId": 137, "operationType": "mint", "amountWei": "6000000000000000", "collectionId": "collection-id", "actorAddress": "0xUserWallet" } ``` For `pay_to_venue`: ```json { "chainId": 137, "operationType": "pay_to_venue", "amountWei": "2500000000000000", "venueAddress": "0xVenueAddress", "actorAddress": "0xUserWallet" } ``` Behavior: - validates actor ownership for the authenticated user - checks target existence and `gasless` - checks sponsor settings - checks sponsor balance - for `approve`, verifies whether allowance is already sufficient for `approveAmountWei` - creates a temporary reservation lock to reduce double-spend races - rate-limited per authenticated user/client to reduce reservation spam `amountWei` is the maximum gas reservation amount. For `approve`, `approveAmountWei` is the token allowance amount being checked. These values are intentionally separate. Typical response: ```json { "canSponsor": true, "reasonCode": "ok", "reasonMessage": "Sponsorship can cover this operation", "chainId": 137, "contextType": "checkin", "operationType": "pay_to_venue", "sponsorAddress": "0xsponsoraddress", "gasless": true, "remainingWei": "7500000000000000", "amountWei": "2500000000000000", "venueAddress": "0xvenueaddress", "collectionId": null, "actorAddress": "0xuserwallet", "ownerAddress": null, "tokenAddress": null, "spenderAddress": null, "approveAmountWei": null, "additionalOperationTypes": ["mint", "pay_to_venue", "distribute_promoter_payments"] } ``` When the authenticated actor does not own the sponsor wallet, sponsor details are hidden in the response: - `sponsorAddress: null` - `remainingWei: null` - `additionalOperationTypes: []` ### Backend-Submitted CheckIn Promoter Withdrawals `distribute_promoter_payments` is not a browser preflight operation. It is an allowed sponsor setting for CheckIn promoter reward withdrawals. When a promoter withdraws venue-funded rewards, Belong API can submit the contract call itself if all conditions are true: - the venue target is `gasless: true` - the sponsor settings include `distribute_promoter_payments` - the sponsor gas-bank ledger can reserve the estimated gas cost - signer policy allows backend distribution submission The client receives: ```json { "address": "0xCheckInContract", "submitted": true, "txHash": "0x...", "transactionStatus": "success", "signatureExpiresAt": "2026-07-05T12:00:00.000Z" } ``` If the sponsor is not eligible or the gas reservation cannot be created, the same CheckIn endpoint falls back to client-submitted transaction params instead of spending platform gas. Gas accounting is based on transaction receipts for tx hashes the backend already submitted. It does not require broad `eth_getLogs` scans. ### Thirdweb Verifier `POST /api/v3/sponsorship/thirdweb/verify` Set this URL in the thirdweb dashboard as the Server Verifier URL: ```text https:///api/v3/sponsorship/thirdweb/verify ``` Configure thirdweb to send this custom header: ```text x-belong-thirdweb-verifier-secret: ``` Environment: - `THIRDWEB_SPONSORSHIP_VERIFIER_SECRET` is required for verifier callbacks - `THIRDWEB_SPONSORSHIP_CLIENT_IDS` is an optional comma-separated allowlist of thirdweb client IDs - `THIRDWEB_SPONSORSHIP_ENTRYPOINT_ADDRESSES` is an optional comma-separated allowlist of ERC-4337 EntryPoint addresses accepted by `/thirdweb/complete` For EIP-7702/direct EOA sponsored execution, thirdweb sends the EOA execution account plus one call. The backend accepts equivalent field names used by thirdweb payload variants: `from`, `accountAddress`, or `sender` for the EOA; `targetAddress`, `to`, or `contractAddress` for the target; `callData` or `data` for calldata; and `nativeValueWei` or `value` for native value. ```json { "clientId": "thirdweb-client-id", "chainId": 137, "accountAddress": "0xUserEOA", "targetAddress": "0xContract", "callData": "0x...", "nativeValueWei": "0", "gasLimit": "120000", "gasPrice": "30000000000" } ``` The legacy ERC-4337 payload is still supported: ```json { "clientId": "thirdweb-client-id", "chainId": 137, "userOp": { "sender": "0xSmartAccount", "targets": ["0xContract"], "gasLimit": "120000", "gasPrice": "30000000000", "data": { "targets": ["0xContract"], "callDatas": ["0x..."], "values": ["0"] } } } ``` Response: ```json { "isAllowed": true } ``` Policy denials return `200`: ```json { "isAllowed": false, "reason": "Matching sponsorship reservation was not found" } ``` Missing or invalid verifier secret returns `401`. Verifier behavior: - rejects batch operations; exactly one target, calldata, and value are allowed - rejects non-zero native value for ERC20 `approve`; `mint` and `pay_to_venue` may use native value when the decoded operation and reservation match - calculates `gasBudgetWei = gasLimit * gasPrice` - decodes calldata instead of trusting frontend labels - checks target contract, business context, sponsor settings, gasless state, and active reservation - rejects approve calldata if token, spender, or approve amount differs from the checked reservation - stores a short-lived server-side approval marker for the exact EOA actor/owner, execution account, target, calldata, native value, sponsor, chain, and operation that was allowed Supported calldata: - ERC20 `approve(address spender, uint256 amount)` - CheckIn `payToVenue(...)` - NFT `mintDynamicPrice(...)` - NFT `mintStaticPrice(...)` ### Complete Thirdweb Usage `POST /api/v3/sponsorship/thirdweb/complete` Frontend calls this route after the thirdweb-sponsored transaction has a receipt. For direct EOA and thirdweb EIP-7702 transactions, `smartAccountAddress` is not required. The backend records the operation against `actorAddress` or `ownerAddress` and uses the execution account from `smartAccountAddress`, `accountAddress`, `from`, or the actor/owner address. Direct EOA completion verifies that the RPC transaction `from`, `to`, `input`, and `value` match the completed operation. Thirdweb EIP-7702 sponsored completion verifies the transaction type 4 / `authorizationList` proof, requires `tx.to` to be the delegated EOA execution account, decodes the wrapped `executeWithSig` call, and verifies the inner target, calldata, and native value. ```json { "clientId": "thirdweb-client-id", "chainId": 137, "txHash": "0x...", "targetAddress": "0xCollectionContract", "callData": "0x...", "nativeValueWei": "0", "operationType": "mint", "contextType": "nft", "collectionId": "collection-id", "actorAddress": "0xUserWallet" } ``` For `approve`: ```json { "clientId": "thirdweb-client-id", "chainId": 137, "txHash": "0x...", "targetAddress": "0xTokenAddress", "callData": "0x...", "nativeValueWei": "0", "operationType": "approve", "contextType": "checkin", "venueAddress": "0xVenueAddress", "ownerAddress": "0xUserWallet", "tokenAddress": "0xTokenAddress", "spenderAddress": "0xSpenderAddress", "approveAmountWei": "50000000" } ``` For ERC-4337 account-abstraction transactions, include the EntryPoint proof fields: ```json { "entryPointAddress": "0xEntryPointAddress", "userOpHash": "0xOptionalUserOperationHash" } ``` Security rules: - requires ordinary Belong user auth - frontend does not send `sponsorAddress` - frontend does not send `amountWei` - backend resolves the sponsor from the venue or collection - backend reads the transaction receipt from RPC - backend computes actual gas as `gasUsed * effectiveGasPrice` for direct and EIP-7702 transactions - for ERC-4337 transactions, backend uses `UserOperationEvent.actualGasCost` - backend records `confirmed` for successful receipts and `failed` for reverted receipts - backend verifies authenticated ownership of `actorAddress` or `ownerAddress` - backend requires a matching active reservation - backend requires the matching verifier approval marker for the same `clientId`, EOA actor/owner, execution account, target, calldata, native value, sponsor, chain, and operation - for direct transactions, backend also checks that the RPC transaction `from`, `to`, `input`, and `value` match the completed operation - for EIP-7702 transactions, backend requires type 4 / `authorizationList`, checks `tx.to` against the execution account, decodes thirdweb `executeWithSig`, and verifies the single inner call target, calldata, and native value - for ERC-4337 account-abstraction transactions, frontend must also send `entryPointAddress` and may send `userOpHash` - for ERC-4337 transactions, backend decodes `EntryPoint.handleOps`, verifies the inner smart-account `execute`/`executeBatch` target, value, and calldata, and reads actual gas/status from `UserOperationEvent` - if `txHash` is already recorded, the route returns idempotent success only after ownership, sponsor, chain, context, operation, and metadata match If the transaction was not broadcast or no receipt exists, usage is not recorded. ### Cancel Thirdweb Reservation `POST /api/v3/sponsorship/thirdweb/cancel` Frontend calls this route only when thirdweb rejects a sponsored transaction before broadcast, for example because a thirdweb sponsor policy denies the target contract. The request does not include `txHash`, receipt data, or `sponsorAddress`. For `approve`: ```json { "chainId": 137, "contextType": "checkin", "operationType": "approve", "amountWei": "25000000000000000", "approveAmountWei": "50000000", "venueAddress": "0xVenueAddress", "ownerAddress": "0xUserWallet", "tokenAddress": "0xTokenAddress", "spenderAddress": "0xSpenderAddress" } ``` For `mint`: ```json { "chainId": 137, "contextType": "nft", "operationType": "mint", "amountWei": "6000000000000000", "collectionId": "collection-id", "actorAddress": "0xUserWallet" } ``` For `pay_to_venue`: ```json { "chainId": 137, "contextType": "checkin", "operationType": "pay_to_venue", "amountWei": "2500000000000000", "venueAddress": "0xVenueAddress", "actorAddress": "0xUserWallet" } ``` Response: ```json { "success": true, "released": true } ``` Behavior: - requires ordinary Belong user auth - frontend does not send `sponsorAddress` - frontend does not send `txHash` or receipt data - backend resolves the sponsor from the venue or collection using the same target resolution as `/sponsorship/check` - backend verifies authenticated ownership of `ownerAddress` for `approve`, or `actorAddress` for `mint` and `pay_to_venue` - backend releases only the active reservation matching the resolved sponsor, `chainId`, operation type, and operation metadata - for `approve`, the matching metadata is `ownerAddress`, `tokenAddress`, `spenderAddress`, and `approveAmountWei` - for `mint`, the matching metadata is `actorAddress` and `collectionId` - for `pay_to_venue`, the matching metadata is `actorAddress` and `venueAddress` - if no matching reservation exists, the route is idempotent and returns `success: true, released: false` - the route never records usage Do not use cancellation for failed on-chain transactions. If a transaction was broadcast or has a receipt, call `/api/v3/sponsorship/thirdweb/complete` so the backend can record actual gas usage and release the reservation. ### Record Usage `POST /api/v3/sponsorship/usage/record` ```json { "sponsorAddress": "0x...", "chainId": 137, "txHash": "0x...", "amountWei": "2500000000000000", "status": "confirmed", "contextType": "checkin", "operationType": "pay_to_venue", "metadata": { "actorAddress": "0xUserWallet", "venueAddress": "0xVenueAddress" } } ``` Authentication: - requires a Belong API key with `sponsorship:write` - permission shape: `{ "sponsorship": ["write"] }` - API key must be kept server-side only and rotated if exposed Notes: - this is a trusted server-only completion route - use it after the external sponsored transaction succeeds or fails - browsers should use `/api/v3/sponsorship/thirdweb/complete` for thirdweb-sponsored flows - `sponsorAddress` must be an EVM address - endpoint is rate-limited before API-key verification by client fingerprint and after verification by authenticated API-key session - for `approve`, `mint`, and `pay_to_venue`, metadata is required so reservation locks can be released correctly - for reserved operations, `amountWei` must be less than or equal to the active reservation amount - `failed` usage counts as spent and should only be recorded after a transaction was broadcast - usage is rejected if the sponsor balance is no longer sufficient after accounting for active reservations - usage records are idempotent by `txHash`; retries may advance status from `recorded`, but cannot change amount, context, operation, sponsor, chain, or metadata ## End-to-End Flow 1. Owner enables `gasless` on a venue or collection. 2. Sponsor updates allowed operations if needed. 3. Sponsor tops up the shared platform wallet. 4. Client calls `POST /api/v3/sponsorship/deposits/record`. 5. Before `approve`, `mint`, or `pay_to_venue`, client calls `POST /api/v3/sponsorship/check`. 6. Thirdweb calls `POST /api/v3/sponsorship/thirdweb/verify` before sponsoring gas. 7. External wallet or executor signs and broadcasts only the checked transaction. 8. Frontend calls `POST /api/v3/sponsorship/thirdweb/complete` after the transaction has a receipt, passing the same target, calldata, and native value that thirdweb sent to the verifier. For non-thirdweb server integrations, step 8 can be replaced by a trusted backend call to `POST /api/v3/sponsorship/usage/record`. ## Notes on Privacy and Auth - `balance` and `usage` are owner-only - `check` is actor-owned, not public - `usage/record` is not a browser route - thirdweb verifier is unauthenticated but protected by `x-belong-thirdweb-verifier-secret` - `usage/record` is a server-only integration route; call it only from a trusted executor/integration - sponsorship is tracked in Belong API, not inferred from shared wallet balances # Staking Guide ::doc-figure --- height: 450 width: 800 alt: Purple tokens and gift boxes beside Unlock Bigger Rewards with LONG. caption: LONG staking tiers determine the fee and reward benefits listed in this guide. placement: lead source-url: https://t.me/belongnet/201 src: https://docs.belong.net/media/social/long-staking-rewards.webp --- :: ## Overview This guide provides frontend examples for performing staking operations with LONG tokens on EVM-compatible chains directly from the user's wallet. It covers minting, depositing, withdrawing, redeeming, and emergency operations. **Staking** places LONG into a staking contract; withdrawing or redeeming follows the contract functions below. Start by matching the wallet network and token amount to the operation you intend to sign. For the customer-facing effect of staking on venue fees, see [Fees & Staking](https://docs.belong.net/belong-checkin/fees-and-staking). --- ## Important Note Throughout the examples below, `parseEther("")` is used to convert token amounts into their on-chain `uint256` representation. Although the function name refers to “Ether”, **it represents LONG tokens, not ETH**. For example, `parseEther("0.5")` corresponds to **0.5 LONG tokens**. --- ## Process Flow ::mermaid ```text flowchart TD; A[Start: User Connect] --> B[Staking Mint] B --> C[Staking Deposit] C --> D{Withdraw or Redeem?} D --> E[Staking Withdraw] D --> F[Staking Redeem] E --> G[Emergency Functions] F --> G G --> H[End: Tokens Managed] ``` :: --- ## Usage Examples ### Staking Mint ```ts /* * mint(uint256 shares, address user) * The user mints sLONG shares by depositing LONG. * Note: parseEther("0.5") means 0.5 LONG tokens (not ETH). */ async function stakingMint() { // Approve LONG token before mint const transaction = prepareContractCall({ contract, method: "mint", params: [parseEther("0.5"), "0xUserAddress"], }); } ``` --- ### Staking Deposit ```ts /* * deposit(uint256 assets, address user) * The user deposits LONG tokens and receives sLONG. * Note: parseEther("0.5") means 0.5 LONG tokens (not ETH). */ async function stakingDeposit() { // Approve LONG token before deposit const transaction = prepareContractCall({ contract, method: "deposit", params: [parseEther("0.5"), "0xUserAddress"], }); } ``` --- ### Staking Withdraw ```ts /* * withdraw(uint256 assets, address receiver, address owner) * The user withdraws LONG by burning sLONG. * Note: parseEther("0.1") means 0.1 LONG tokens (not ETH). */ async function stakingWithdraw() { const transaction = prepareContractCall({ contract, method: "withdraw", params: [parseEther("0.1"), "0xUserAddress", "0xUserAddress"], }); } ``` --- ### Staking Redeem ```ts /* * redeem(uint256 shares, address receiver, address owner) * The user redeems sLONG and receives LONG. * Note: parseEther("0.1") means 0.1 LONG tokens (not ETH). */ async function stakingRedeem() { const transaction = prepareContractCall({ contract, method: "redeem", params: [parseEther("0.1"), "0xUserAddress", "0xUserAddress"], }); } ``` --- ### Emergency Withdraw ```ts /* * emergencyWithdraw(uint256 assets, address receiver, address owner) * Emergency withdrawal in case of issues. * Note: parseEther("0.1") means 0.1 LONG tokens (not ETH). */ async function emergencyWithdraw() { const transaction = prepareContractCall({ contract, method: "emergencyWithdraw", params: [parseEther("0.1"), "0xUserAddress", "0xUserAddress"], }); } ``` --- ### Emergency Redeem ```ts /* * emergencyRedeem(uint256 shares, address receiver, address owner) * Emergency redemption for stuck positions. * Note: parseEther("0.1") means 0.1 LONG tokens (not ETH). */ async function emergencyRedeem() { const transaction = prepareContractCall({ contract, method: "emergencyRedeem", params: [parseEther("0.1"), "0xUserAddress", "0xUserAddress"], }); } ``` --- ## Errors MCP tools return errors in the standard JSON format: ```json { "error": "STAKING_INSUFFICIENT_BALANCE" } ``` ### Common error codes | Code | Description | | ------------------------------ | ---------------------------------------------------- | | `STAKING_INSUFFICIENT_BALANCE` | Not enough LONG tokens to complete the transaction. | | `APPROVE_REQUIRED` | Token approval is missing or insufficient. | | `EMERGENCY_ONLY` | Operation allowed only in emergency mode. | | `INVALID_AMOUNT` | Provided amount is invalid (zero or exceeds limits). | --- # Starknet NFT Minting Guide for MCP ::doc-figure --- height: 450 width: 800 alt: Starknet and Belong logos with the words Grant Recipient. caption: Starknet collection deployment and minting use their own chain-specific tooling, separate from EVM operations. placement: lead source-url: https://t.me/belongnet/58 src: https://docs.belong.net/media/social/starknet-ecosystem.webp --- :: ## Overview This document describes the complete process of minting NFTs on the Starknet blockchain using MCP (Model Context Protocol) tools. The process involves several steps that must be executed in a specific order to successfully create and mint NFTs. Use the Starknet-specific preparation and completion calls together. A transaction prepared for Starknet must be signed by the appropriate Starknet account, and a deployed account is required for the calls described below. Follow the sequence even if you have already integrated the separate [EVM minting flow](https://docs.belong.net/guides/crypto/minting). > **📋 Prerequisites:** Before using these tools, make sure you have [set up MCP integration](https://docs.belong.net/getting-started/mcp) with your API key. > > **Account deployment note:** Starknet wallet addresses are account contracts. The `creator_address` and each `items[].receiver` must be **deployed** on the target network, otherwise you may see errors like `Requested contract address ... is not deployed`. The same operations are available as **REST API** endpoints (see `starknet.hono.ts`): `POST /deploy`, `POST /complete-deploy`, `POST /mint`, `POST /complete-mint`. REST routes require auth and accept the same JSON bodies as the `data` payloads described below. All four operations are now **network-aware**. Pass the same `network` value through the full lifecycle (`deploy -> complete-deploy -> mint -> complete-mint`). Supported values are `"SN_MAIN"` and `"SN_SEPOLIA"`, and the connected wallet must be on the same network. ## Process Flow ::mermaid ```text sequenceDiagram participant MCP as MCP Client participant Tools as MCP Tools participant API as Backend API participant Frontend as Frontend participant Blockchain as Starknet Note over MCP,Blockchain: Deploy Collection MCP->>Tools: starknet-deploy-collection Tools-->>MCP: calls[] MCP->>Frontend: pass calls[] Frontend->>Blockchain: account.execute(calls) Blockchain-->>Frontend: receipt (transaction_hash) Note over MCP,Blockchain: Complete Deployment MCP->>Tools: starknet-complete-deploy Tools-->>MCP: collection data Note over MCP,Blockchain: Approve Token Before Mint Frontend->>Blockchain: approve(collection_address, total_amount) Blockchain-->>Frontend: approve receipt Note over MCP,Blockchain: Mint NFT MCP->>Tools: starknet-mint-nft Tools-->>MCP: calls[] MCP->>Frontend: pass calls[] Frontend->>Blockchain: account.execute(calls) Blockchain-->>Frontend: receipt (transaction_hash) Note over MCP,Blockchain: Complete Mint MCP->>Tools: starknet-complete-mint Tools-->>MCP: NFT records ``` :: ## MCP Tools All tools accept input under a `data` key: pass `{ data: { ...fields } }` when calling a tool. The schemas below describe the contents of `data`. ### 1. Deploy Collection **Tool:** `starknet-deploy-collection` **Description:** Deploy a collection. As a result of executing this command, you will receive a transaction that needs to be signed and sent to the blockchain. **Input data:** ```typescript { name: string, // Collection name (required, min 1 char, cannot be empty/whitespace) symbol: string, // Collection symbol (required, min 1 char, cannot contain spaces) description?: string, // Optional description feeNumerator: number, // Royalty numerator in percentage (0-8, e.g., 8 = 8%) transferable: boolean, // Whether NFT can be transferred maxTotalSupply: number, // Maximum NFT count mintPrice: number, // Base price per mint (human amount, e.g., 2, 0.5) whitelistMintPrice: number, // Discounted price for whitelisted minters (human amount) paymentToken: "STRK"|"ETH"|"USDC", // Payment token creator: string, // Creator wallet address (Starknet address format) externalUrl?: string | null, // Optional external website/app link referralCode?: string, // Optional referral code network: "SN_MAIN"|"SN_SEPOLIA" // Target Starknet network } ``` **Note:** The backend automatically calculates total royalty (platform fee + creator fee) and validates it doesn't exceed 80%. **Output data:** ```typescript { calls: [ { contractAddress: string, // Factory contract address entrypoint: "produce", // Entrypoint name calldata: any[] // Compiled calldata } ] } ``` **Note:** Returns an object `{ calls: [...] }` (or `{ error: string }` on failure). After executing the transaction, use the transaction hash with `starknet-complete-deploy` and payload under `data` to finalize collection creation in the database. ### 2. Complete Deployment **Tool:** `starknet-complete-deploy` **Description:** Validates the deployment transaction receipt and creates or refreshes the collection record in the database. When `activityId` or `hubId` is provided, the linked entity is published with `passStrategy: STATIC` to enable QR pass flow. **Input:** Pass as `{ data: { ... } }`: ```typescript { hash: string, // Transaction hash from deploy step (required, non-zero) gasless?: boolean, // Enable gasless transactions (optional) hubId?: string | null, // Optional hub ID for whitelisting activityId?: string | null, // Optional activity ID whitelist_hubIDs?: string[], // Array of hub IDs for whitelist (optional) whitelist_userIDs?: string[], // Array of user IDs for whitelist (optional) attributes?: [ // Default attributes for NFTs (optional) { trait_type: string, display_type?: "string" | "number" | "date" | "boost_number" | "boost_percentage", // Optional, defaults to "string" value: string } ], network: "SN_MAIN"|"SN_SEPOLIA" // Same network used during deploy } ``` **Output data:** ```typescript { // NftCollection object with all collection data id: string, contractAddress: string, // ... other collection fields } ``` ### 3. Approve Payment Token (Required before Mint) **⚠️ Important:** Before minting NFTs, you must approve the collection contract to spend the required amount of payment tokens on your behalf. **Important units:** ERC20 `approve(amount)` expects the **base-units** amount (u256), not a human decimal string. If your `items[].price` values are human amounts, convert them to base units using token decimals before summing and approving. **Token addresses depend on the selected Starknet network:** ```typescript const STARKNET_TOKEN_ADDRESSES = { SN_MAIN: { STRK: "0x04718f5a0fc34cc1af16a1cdee98ffb20c31f5cd61d6ab07201858f4287c938d", ETH: "0x049d36570d4e46f48e99674bd3fcc84644ddd6b96f7c741b1562b82f9e004dc7", USDC: "0x033068f6539f8e6e6b131e6b2b814e6c34a5224bc66947c47dab9dfee93b35fb", }, SN_SEPOLIA: { STRK: "0x04718f5a0fc34cc1af16a1cdee98ffb20c31f5cd61d6ab07201858f4287c938d", ETH: "0x049d36570d4e46f48e99674bd3fcc84644ddd6b96f7c741b1562b82f9e004dc7", USDC: "0x0512feac6339ff7889822cb5aa2a86c848e9d392bb0e3e237c008674feed8343", }, }; ``` **Implementation:** ```typescript // Example: approve 1 token (18 decimals) => 1e18 base units const approveCall = { contractAddress: STARKNET_TOKEN_ADDRESSES[network].STRK, entrypoint: "approve", calldata: [ collection_address, // spender "1000000000000000000", // amount "0", // high part ], }; await account.execute([approveCall]); ``` ### 4. Mint NFT **Tool:** `starknet-mint-nft` **Description:** Mint an NFT. As a result of executing this command, you will receive a transaction that needs to be signed and sent to the blockchain. **Input data:** ```typescript { collection_address: string, // Created collection address items: [ { receiver: string, // NFT receiver address name: string, // NFT name description: string, // NFT description price: string, // Human amount string (e.g. "0.2") - backend converts to u256 base-units by token decimals quantity: number, // Number of copies image?: string, // NFT image URL externalUrl?: string, // External link animation_url?: string, // Animation URL attributes?: [ // NFT attributes { trait_type: string, value: string } ] } ], network: "SN_MAIN"|"SN_SEPOLIA" // Same network used during deploy } ``` **Output data:** ```typescript { calls: [ { contractAddress: string, entrypoint: string, calldata: any[] } ] } ``` **Note:** Returns an object `{ calls: [...] }`. After executing the transaction, use the transaction hash with `starknet-complete-mint` MCP tool to parse the receipt and create NFT records in the database. ### 5. Complete Mint **Tool:** `starknet-complete-mint` **Description:** Parses the mint transaction receipt, extracts minted NFT information (token IDs, receivers), fetches metadata from `tokenUri`, calculates `minted_price`, and creates NFT records in the database. It also returns the minter Starknet wallet in `cryptoAddress` response field without persisting Starknet wallet addresses in `crypto_addresses`. **Requires MCP auth** (API key / user context). **Input:** Pass as `{ data: { hash, network } }`: ```typescript { hash: string, // Transaction hash from mint step (required) network: "SN_MAIN"|"SN_SEPOLIA" // Same network used during mint } ``` **Output data:** ```typescript [ { id: string, name: string, hash: string, address: string, block_number: string | null, token_id: string, token_uri: string | null, image: string | null, userId: string, minted_price: number | null, attributes: [ { trait_type: string, display_type?: "string" | "number" | "date" | "boost_number" | "boost_percentage", value: string } ] | null, cryptoAddress: { address: string }, receiver: string | null, serialNumber?: string } ] ``` **Note:** - Automatically parses `Transfer` events from the transaction receipt to identify minted NFTs and the actual NFT contract - Fetches and parses metadata from `tokenUri` (supports JSON strings, HTTP/HTTPS URLs, and Data URIs) - Creates NFT records in DB during `complete-mint`; repeat calls for the same transaction are not intended as the primary flow - `complete-deploy` and `complete-mint` must be called with the same `network` value that was used for the original transaction - Extracts metadata fields: `name`, `image`, `description`, `external_url`, `animation_url`, and `attributes` - If the collection is linked to an `activityId` or `hubId`, QR passes are created during NFT persistence and QR emails use Voyager links for Starknet ## Usage ```js // 1. Deploy collection using MCP tool const collectionData = { name: "My NFT Collection", symbol: "MNFT", description: "A unique collection", feeNumerator: 5, // 5% royalty transferable: true, maxTotalSupply: 10000, mintPrice: 2, whitelistMintPrice: 1, paymentToken: "USDC", creator: "0x...", // Your Starknet wallet address externalUrl: "https://example.com", referralCode: "0", // Optional }; const deployResult = await mcp.callTool("starknet-deploy-collection", { data: collectionData, }); const calls = JSON.parse(deployResult.content[0].text); // Extract calls array from MCP response // On frontend: Execute transaction const receipt = await account.execute(calls); const transactionHash = receipt.transaction_hash; // 2. Complete deployment (create collection in database) // After transaction is confirmed, call complete-deploy MCP tool with payload under data const completeResult = await mcp.callTool("starknet-complete-deploy", { data: { hash: transactionHash, gasless: false, // Optional hubId: null, // Optional activityId: null, // Optional whitelist_hubIDs: [], // Optional whitelist_userIDs: [], // Optional attributes: [ // Optional { trait_type: "Color", display_type: "string", value: "Blue", }, ], }, }); const collection = JSON.parse(completeResult.content[0].text); // Extract collection data from MCP response const collectionAddress = collection.contractAddress; // Get collection address from response // 3. Before minting: Approve payment token import { parseUnits } from "viem"; const tokenDecimals = 18; // STRK/ETH are 18; USDC is 6 (see token address section below) const totalAmount = mintData.items .reduce((sum, item) => { const itemBaseUnits = parseUnits(item.price, tokenDecimals); return sum + itemBaseUnits * BigInt(item.quantity); }, 0n) .toString(); const tokenAddress = { STRK: "0x04718f5a0fc34cc1af16a1cdee98ffb20c31f5cd61d6ab07201858f4287c938d", ETH: "0x049d36570d4e46f48e99674bd3fcc84644ddd6b96f7c741b1562b82f9e004dc7", // USDC addresses differ by network. Prefer the addresses used by the backend configuration: // - Sepolia (native USDC): 0x0512feAc6339Ff7889822cb5aA2a86C848e9D392bB0E3E237C008674feeD8343 // - Mainnet (native USDC): 0x033068F6539f8e6e6b131e6B2B814e6c34A5224bC66947c47DaB9dFeE93b35fb USDC: "0x0512feAc6339Ff7889822cb5aA2a86C848e9D392bB0E3E237C008674feeD8343", }[paymentToken]; // Use the same payment token as in collection const approveCall = { contractAddress: tokenAddress, entrypoint: "approve", calldata: [collection_address, totalAmount, "0"], }; // Execute approve transaction await account.execute([approveCall]); // 4. Mint NFT using MCP tool const mintData = { collection_address: collectionAddress, // From complete-deploy response items: [ { receiver: "0x...", // Receiver wallet address name: "NFT One", description: "Description of the NFT", price: "0.2", // Human amount string quantity: 1, image: "https://example.com/image.png", // Optional externalUrl: "https://example.com/external-link.html", // Optional animation_url: "https://example.com/animation.mp4", // Optional attributes: [ // Optional { trait_type: "Rarity", value: "Common", }, ], }, ], }; const mintResult = await mcp.callTool("starknet-mint-nft", { data: mintData, }); const { calls } = JSON.parse(mintResult.content[0].text); // Extract calls from MCP response // On frontend: Execute mint transaction const mintReceipt = await account.execute(calls); const mintTransactionHash = mintReceipt.transaction_hash; // 5. Complete mint (parse receipt and create NFT records in database) // After transaction is confirmed, call complete-mint MCP tool const completeMintResult = await mcp.callTool("starknet-complete-mint", { data: { hash: mintTransactionHash, }, }); const nfts = JSON.parse(completeMintResult.content[0].text); // Extract NFT records from MCP response console.log(`Successfully created ${nfts.length} NFT records`); ``` ## Errors MCP tools return errors in the standard MCP error format when operations fail. # Sui NFT Minting Guide for MCP ::doc-figure --- height: 450 width: 800 alt: A purple minting machine beside the words Just Mint It. caption: Create a collection, prepare the mint, and sign the transaction using the selected chain's workflow. placement: lead source-url: https://t.me/belongnet/67 src: https://docs.belong.net/media/social/mint-digital-assets.webp --- :: ## Overview This document describes the complete process of minting NFTs on the Sui blockchain using MCP (Model Context Protocol) tools. The process involves several steps that must be executed in a specific order to successfully create and mint NFTs. On Sui, publishing the package, creating the collection, and saving its backend record are separate steps. Keep the returned identifiers between calls so later kiosk and mint operations refer to the same collection. A **kiosk** is the Sui container used in this workflow to manage NFT ownership and trading. > **📋 Prerequisites:** Before using these tools, make sure you have [set up MCP integration](https://docs.belong.net/getting-started/mcp) with your API key. ## Process Flow ::mermaid ```text flowchart TD; A[Start: User Authentication] --> B[Publish Collection] B --> B1[publish-collection tool] B1 --> B2[Get transaction bytes] B2 --> B3[Sign transaction] B3 --> C[Create Collection] C --> C1[create-collection tool] C1 --> C2[Get transaction bytes] C2 --> C3[Sign transaction] C3 --> D[Save Collection] D --> D1[save-collection tool] D1 --> D2[Get collection address] D2 --> E[Kiosk Management] E --> E1{Check existing kiosk} E1 -->|Yes| F1[get-kiosk tool] E1 -->|No| G1[sign-kiosk tool] F1 --> F2[Get kiosk data] G1 --> G2[Get transaction bytes] G2 --> G3[Sign transaction] G3 --> G4[create-kiosk tool] G4 --> G5[Get kiosk data] F2 --> S[Sponsor Setup - One Time] G5 --> S S --> S1{Need sponsor?} S1 -->|Yes| S2[create-sponsored-collection tool] S1 -->|No| L[Mint NFT] S2 --> S3[Fund sponsor account] S3 --> L L --> L1[mint-sign tool] L1 --> L2[Check sponsor + Get transaction bytes] L2 --> L3[Sign transaction] L3 --> L4[mint tool] L4 --> M[End: NFT Minted Successfully] ``` :: ## Detailed Process Steps ### 1. Publish Collection **Tool:** `publish-collection` **Description:** Publish a collection. As a result of executing this command, you will receive a transaction that needs to be signed and sent to the blockchain. **Input:** ```json { "walletAddress": "0x...", "name": "Collection Name", "symbol": "SYMBOL", "description": "Collection Description", "image_url": "https://...", "feeNumerator": 2, "mintPrice": 2, "whitelistMintPrice": 1, "transferable": true, "maxTotalSupply": 9999, "collectionExpire": 1785508320, "isSui": false } ``` **Output:** ```json { "transactionBytes": "base64_encoded_transaction", "name": "Collection Name", "symbol": "SYMBOL", "collectionCap": "0x..." } ``` ### 2. Create Collection **Tool:** `create-collection` **Description:** Creating a collection. As a result of executing this command, you will receive a transaction that needs to be signed and sent to the blockchain. **Input:** ```json { "signature": { "signature": "0x...", "bytes": "0x..." }, "walletAddress": "0x...", "name": "Collection Name", "symbol": "SYMBOL", "collectionCap": "0x..." } ``` **Output:** ```json { "transactionBytes": "base64_encoded_transaction" } ``` ### 3. Save Collection **Tool:** `save-collection` **Description:** Save a collection to the database after it has been created on the blockchain. **Input:** ```json { "signature": { "signature": "0x...", "bytes": "0x..." }, "name": "Collection Name", "symbol": "SYMBOL" } ``` **Output:** ```json { "collectionAddress": "0x...", "produce_data": { "name": "Collection Name", "symbol": "SYMBOL", "creator": "0x...", "feeReceiver": "0x..." } } ``` ### 4. Kiosk Management #### 4a. Get Existing Kiosk **Tool:** `get-kiosk` **Description:** Get an existing kiosk for a collection. **Input:** ```json { "collection": "0x...", "owner": "0x..." } ``` **Output:** ```json { "kioskId": "0x...", "kioskCap": "0x...", "collection": "0x...", "owner": "0x..." } ``` #### 4b. Create New Kiosk **Step 1: Sign Kiosk****Tool:** `sign-kiosk` **Description:** Receive data for the kiosk creation transaction. As a result of executing this command, you will receive a transaction that needs to be signed and sent to the blockchain. **Input:** ```json { "walletAddress": "0x..." } ``` **Output:** ```json { "transactionBytes": "base64_encoded_transaction" } ``` **Step 2: Create Kiosk****Tool:** `create-kiosk` **Description:** Create a kiosk for the collection. The kiosk data will be returned for further use in minting. **Input:** ```json { "signature": { "signature": "0x...", "bytes": "0x..." }, "owner": "0x...", "collection": "0x..." } ``` **Output:** ```json { "kioskId": "0x...", "kioskCap": "0x...", "collection": "0x...", "owner": "0x..." } ``` ### 5. Sponsor Management (Optional) #### 5a. Skip Sponsor If you don't want to sponsor gas payments, you can proceed directly to minting. #### 5b. Create Sponsor **Tool:** `create-sponsored-collection` **Description:** Create a gas payment sponsor for the collection. You will need to pass the collection address and your wallet address. **Input:** ```json { "collectionAddress": "0x...", "walletAddress": "0x..." } ``` **Output:** ```json { "sponsorAddress": "0x...", "ownerAddress": "0x...", "collectionAddress": "0x..." } ``` #### 5c. Fund Sponsor Account **Important:** After creating a sponsor, you must fund the sponsor account with SUI tokens to cover gas fees for minting operations. ### 6. Mint NFT #### 6a. Sign Mint Transaction **Tool:** `mint-sign` **Description:** Get the data to sign a mint transaction. To do this, you need to create a kiosk or use data from an existing kiosk. Also, if you want to sponsor gas payments, you should create a sponsor. As a result of executing this command, you will receive a transaction that needs to be signed and sent to the blockchain. **Input:** ```json { "collectionName": "Collection Name", "collectionSymbol": "SYMBOL", "mintCapProps": { "name": "NFT Name", "description": "NFT Description", "metadataLink": "https://...", "imageUrl": "https://...", "whitelisted": true, "uses": 1, "capReceiver": "0x..." }, "senderAddress": "0x...", "kioskId": "0x...", "kioskCap": "0x..." } ``` **Output:** ```json { "transactionBytes": "base64_encoded_transaction", "sponsorSignature": { "signature": "0x...", "bytes": "0x..." } } ``` #### 6b. Execute Mint **Tool:** `mint` **Description:** Mint a token using the provided signatures. If you want to sponsor gas payments, you should create a sponsor first. The minted token data will be returned. **Input:** ```json { "senderSignature": { "signature": "0x...", "bytes": "0x..." }, "sponsorSignature": { "signature": "0x...", "bytes": "0x..." } } ``` **Output:** ```json { "id": { "id": "0x..." }, "name": "NFT Name", "description": "NFT Description", "metadataLink": "https://...", "image_url": "https://...", "block_number": 12345, "hash": "0x..." } ``` ## Error Handling ### Common Errors 1. **Invalid Address**: Ensure all Sui addresses are valid and properly formatted 2. **Insufficient Balance**: Make sure the wallet has enough SUI for gas fees 3. **Sponsor Not Funded**: If using a sponsor, ensure the sponsor account is funded 4. **Collection Already Exists**: Check if the collection name/symbol combination is unique 5. **Kiosk Not Found**: Verify the kiosk exists for the collection/owner combination ### Error Response Format MCP tools return errors in the standard MCP error format when operations fail. ## Best Practices 1. **Always verify addresses** before submitting transactions 2. **Test on testnet** before deploying to mainnet 3. **Keep track of transaction hashes** for debugging 4. **Monitor gas fees** and ensure sufficient balance 5. **Use sponsors for better UX** when possible 6. **Validate metadata URLs** before minting ## Usage Examples ```ts // 1. Publish collection using MCP tool const publishResult = await mcp.callTool("publish-collection", { data: { walletAddress: "0x...", name: "Collection Name", symbol: "SYMBOL", description: "Collection Description", image_url: "https://...", feeNumerator: 2, mintPrice: 2, whitelistMintPrice: 1, transferable: true, maxTotalSupply: 9999, collectionExpire: 1785508320, isSui: false, }, }); const { transactionBytes, name, symbol, collectionCap } = publishResult.content[0].text; // Sign transaction with wallet const signature = await walletInstance.signTransaction(transactionBytes); // 2. Create collection const createResult = await mcp.callTool("create-collection", { data: { signature, walletAddress: "0x...", name, symbol, collectionCap, }, }); // 3. Save collection const saveResult = await mcp.callTool("save-collection", { data: { signature: createSignature, name, symbol, }, }); const { collectionAddress } = saveResult.content[0].text; // 4. Get or create kiosk let kioskData; try { const kioskResult = await mcp.callTool("get-kiosk", { data: { collection: collectionAddress, owner: walletAddress, }, }); kioskData = kioskResult.content[0].text; } catch (error) { // Create new kiosk const signKioskResult = await mcp.callTool("sign-kiosk", { data: { walletAddress }, }); const kioskSignature = await walletInstance.signTransaction( signKioskResult.content[0].text.transactionBytes, ); const createKioskResult = await mcp.callTool("create-kiosk", { data: { signature: kioskSignature, owner: walletAddress, collection: collectionAddress, }, }); kioskData = createKioskResult.content[0].text; } // 5. Optional: Create sponsor const sponsorResult = await mcp.callTool("create-sponsored-collection", { data: { collectionAddress, walletAddress, }, }); // 6. Mint NFT const mintSignResult = await mcp.callTool("mint-sign", { data: { collectionName: name, collectionSymbol: symbol, mintCapProps: { name: "NFT Name", description: "NFT Description", metadataLink: "https://...", imageUrl: "https://...", whitelisted: true, uses: 1, capReceiver: walletAddress, }, senderAddress: walletAddress, kioskId: kioskData.kioskId, kioskCap: kioskData.kioskCap, }, }); const senderSignature = await walletInstance.signTransaction( mintSignResult.content[0].text.transactionBytes, ); const mintResult = await mcp.callTool("mint", { data: { senderSignature, sponsorSignature: mintSignResult.content[0].text.sponsorSignature, }, }); console.log("NFT minted:", mintResult.content[0].text); ``` # Vesting Guide ::doc-figure --- height: 450 width: 800 alt: LONG tokens beside the words Why the LONG token matters. caption: LONG vesting schedules define when an allocation becomes available to its beneficiary. placement: lead source-url: https://t.me/belongnet/164 src: https://docs.belong.net/media/social/long-token-utility.webp --- :: ## Overview This guide provides instructions for deploying and managing vesting contracts for LONG tokens on EVM-compatible blockchains (e.g., BSC, Ethereum, Polygon) using MCP (Model Context Protocol) tools. The process involves deploying a vesting wallet with customizable schedules (cliff, TGE, and linear vesting) and releasing vested tokens. **Vesting** releases allocated tokens over time. A **cliff** delays scheduled releases, the **TGE** (token generation event) allocation specifies the initial release, and linear vesting unlocks its assigned allocation over the configured duration. Decide the beneficiary and schedule before preparing the wallet deployment; deployment still requires the returned transaction to be signed. **Important:** The `deploy-vesting-wallet` tool returns transaction parameters that must be executed on the frontend. The user's wallet must have sufficient LONG tokens and approve the factory contract before deployment. > **📋 Prerequisites:** > > - Ensure [MCP integration](https://docs.belong.net/getting-started/mcp) is set up with your API key > - User wallet must have sufficient LONG tokens (at least `totalAllocation`) > - User wallet must approve the factory contract for `totalAllocation` amount --- ## Process Flow ::mermaid ```text flowchart TD; A[Start: User Authentication] --> B[Get Deployment Parameters
from Backend via MCP] B --> C[Check LONG Token Balance] C --> D{Has Enough
Tokens?} D -->|No| E[Error: NotEnoughFundsToVest] D -->|Yes| F[Approve Factory Contract] F --> G[Execute Transaction
on Frontend] G --> H[Deploy Vesting Wallet] H --> I{Configuration
Finalized?} I -->|No| J[Add Tranches if needed] J --> K[Finalize Configuration
Owner Only] K --> L{Allocation
Balanced?} L -->|No| M[Error: AllocationNotBalanced] L -->|Yes| N[Release Vested Tokens] I -->|Yes| N N --> O[End: Tokens Released] ``` :: --- ## MCP Tools ### 1. Deploy Vesting Wallet **Tool:** `deploy-vesting-wallet` **Description:**:br Returns transaction parameters for deploying a time-locked vesting contract for LONG tokens. The transaction must be executed on the frontend by the user's wallet. The user must have sufficient LONG tokens and approve the factory contract before calling this tool. **Important Requirements:** - User's wallet (`walletAddress`) must have at least `totalAllocation` LONG tokens - User's wallet must approve the factory contract for `totalAllocation` amount - The transaction is executed on the frontend, not by the backend - Backend only provides the signature and transaction parameters **Input:** ```typescript { vestingWalletInfo: { startTimestamp: number, // Start time of vesting (Unix timestamp) cliffDurationSeconds: number, // Cliff period duration in seconds durationSeconds: number, // Total vesting duration in seconds beneficiary: string, // Address receiving vested tokens totalAllocation: number, // Total tokens to vest (human-readable format, e.g., 2 for 2 tokens) tgeAmount: number, // Tokens released at TGE (human-readable format, e.g., 0.5) linearAllocation: number, // Tokens released linearly (human-readable format, e.g., 1.5) description: string, // Description of vesting contract // Note: token address is automatically resolved from LONG token on the specified chain }, chainId: number, // EVM chain ID walletAddress: string, // User's wallet address (will be owner and msg.sender) } ``` **Output:** ```json { address: string, // Factory contract address address_token: string, // LONG token address method: object, // ABI method details for deployVestingWallet params: [ // Transaction parameters string, // walletAddress (owner) { startTimestamp: string, // Start timestamp (BigInt as string) cliffDurationSeconds: string, // Cliff duration (BigInt as string) durationSeconds: string, // Duration (BigInt as string) token: string, // Token address beneficiary: string, // Beneficiary address totalAllocation: string, // Total allocation (BigInt as string, in wei) tgeAmount: string, // TGE amount (BigInt as string, in wei) linearAllocation: string, // Linear allocation (BigInt as string, in wei) description: string, // Description }, { nonce: string, // Signature nonce (BigInt as string) deadline: string, // Signature deadline (BigInt as string) signature: string, // Backend signature (hex string) } ], totalAllocationApprove: string, // Total allocation in wei (for approve check) } ``` > **Note:** > > - The response contains transaction parameters that must be executed on the frontend > - All BigInt values are converted to strings for JSON compatibility > - The backend creates a signature, but the transaction is sent from the user's wallet > - The user's wallet must have tokens and approve before executing the transaction --- ## Contract Functions The following functions are called directly on the smart contracts (not MCP tools): ### Finalize Vesting Configuration **Description:**:br Before releasing tokens, the vesting configuration must be finalized. This ensures that `TGE + linear + tranches == totalAllocation`. Only the owner can finalize the configuration. **Requirements:** - Must be called by the vesting wallet owner - `TGE amount + linear allocation + tranches total` must equal `totalAllocation` - Can only be called once (configuration becomes immutable after finalization) **Implementation:** ```typescript import { getContract } from "thirdweb"; import { prepareContractCall, sendTransaction } from "thirdweb"; async function finalizeTranchesConfiguration() { // Get contract instance const contract = getContract({ client, chain: 56, // BSC address: vestingWalletAddress, }); // Check if owner const owner = await contract.call({ functionName: "owner", }); if (owner !== currentAddress) { throw new Error("Unauthorized: Only owner can finalize"); } // Check if already finalized const isFinalized = await contract.call({ functionName: "tranchesConfigurationFinalized", }); if (!isFinalized) { // Prepare and send finalization transaction const transaction = prepareContractCall({ contract, method: "function finalizeTranchesConfiguration()", }); await sendTransaction({ transaction, account, }); } } ``` ### Release Vested Tokens **Description:** Releases vested LONG tokens to the beneficiary according to the vesting schedule. This is a contract-level function called directly on the vesting wallet. **Requires the configuration to be finalized first.** **Important:** This function can be called by **any user** (not just the owner). Once the configuration is finalized, anyone can trigger the release of vested tokens to the beneficiary. **Requirements:** - Configuration must be finalized (`tranchesConfigurationFinalized == true`) - **Anyone can call `release()`** - no owner privileges required - There must be vested tokens available to release **Implementation:** ```typescript import { getContract } from "thirdweb"; import { prepareContractCall, sendTransaction } from "thirdweb"; async function release() { // Get contract instance const contract = getContract({ client, chain: 56, // BSC address: vestingWalletAddress, }); // Verify finalization status const isFinalized = await contract.call({ functionName: "tranchesConfigurationFinalized", }); if (!isFinalized) { throw new Error( "VestingNotFinalized: Configuration must be finalized before release", ); } // Prepare and send release transaction const transaction = prepareContractCall({ contract, method: "function release()", }); await sendTransaction({ transaction, account, }); } ``` ### Usage Examples **Deploy Vesting Wallet** ```typescript import { getContract } from "thirdweb"; import { prepareContractCall, sendTransaction } from "thirdweb"; async function deployVestingWallet() { // 1. Get deployment parameters from backend const { address, address_token, method, params, totalAllocationApprove } = await mcp.tools.call("deploy-vesting-wallet", { chainId: 56, // BSC walletAddress: userAddress, // User's wallet address vestingWalletInfo: { startTimestamp: Math.floor(Date.now() / 1000), cliffDurationSeconds: 60 * 60 * 24 * 30, // 30 days durationSeconds: 60 * 60 * 24 * 365, // 1 year beneficiary: "0xBeneficiaryAddress", totalAllocation: 2, // 2 tokens (human-readable) tgeAmount: 0.5, // 0.5 tokens at TGE linearAllocation: 1.5, // 1.5 tokens linearly description: "Team vesting wallet", }, }); // 2. Get token contract instance const tokenContract = getContract({ client, chain: 56, // BSC address: address_token, }); // 3. Check token balance const tokenBalance = await tokenContract.call({ functionName: "balanceOf", params: [userAddress], }); const totalAllocationBigInt = BigInt(totalAllocationApprove); if (tokenBalance < totalAllocationBigInt) { throw new Error( `Insufficient balance: need ${totalAllocationBigInt.toString()}`, ); } // 4. Check and approve if needed const allowance = await tokenContract.call({ functionName: "allowance", params: [userAddress, address], }); if (allowance < totalAllocationBigInt) { const approveTransaction = prepareContractCall({ contract: tokenContract, method: "function approve(address spender, uint256 amount)", params: [address, totalAllocationBigInt], }); await sendTransaction({ transaction: approveTransaction, account, }); } // 5. Get factory contract instance const factoryContract = getContract({ client, chain: 56, // BSC address: address, }); // 6. Convert string params to BigInt for transaction const convertedParams = [ params[0], // walletAddress (string) { ...params[1], startTimestamp: BigInt(params[1].startTimestamp), cliffDurationSeconds: BigInt(params[1].cliffDurationSeconds), durationSeconds: BigInt(params[1].durationSeconds), totalAllocation: BigInt(params[1].totalAllocation), tgeAmount: BigInt(params[1].tgeAmount), linearAllocation: BigInt(params[1].linearAllocation), }, { ...params[2], nonce: BigInt(params[2].nonce), deadline: BigInt(params[2].deadline), }, ]; // 7. Execute deployment transaction const deployTransaction = prepareContractCall({ contract: factoryContract, method: "function deployVestingWallet(address _owner, (uint64 startTimestamp, uint64 cliffDurationSeconds, uint64 durationSeconds, address token, address beneficiary, uint256 totalAllocation, uint256 tgeAmount, uint256 linearAllocation, string description) vestingWalletInfo, (uint256 nonce, uint256 deadline, bytes signature) protection)", params: convertedParams, }); await sendTransaction({ transaction: deployTransaction, account, }); // 8. Get deployed vesting wallet address const vestingWallets = await factoryContract.call({ functionName: "getVestingWalletInstanceInfos", params: [beneficiaryAddress], }); const vestingWalletAddress = vestingWallets[vestingWallets.length - 1].vestingWallet; console.log("Deployed vesting wallet:", vestingWalletAddress); } ``` > **Important:** > > - Token amounts (`totalAllocation`, `tgeAmount`, `linearAllocation`) should be specified in human-readable format (e.g., `2` for 2 tokens). The system automatically converts them to wei (18 decimals) for LONG tokens. > - The `token` field is automatically resolved from the LONG token address on the specified chain and should not be included in the request. > - Requires admin authentication (`UserRole.admin`). > - **User Requirements:** The `walletAddress` must have at least `totalAllocation` LONG tokens and must approve the factory contract. > - **Transaction Execution:** The transaction is executed on the frontend from the user's wallet, not by the backend. > - **Allocation Balance:** `tgeAmount + linearAllocation + tranches` must equal `totalAllocation` before finalization. **Get Vesting Wallet Info by Beneficiary** ```typescript import { getContract } from "thirdweb"; // Get all vesting wallets for a beneficiary (direct contract call, not MCP tool) const factoryAddress = "0xFactoryAddress"; // Factory contract address const beneficiary = "0xBeneficiaryAddress"; // Get factory contract instance const factoryContract = getContract({ client, chain: 56, // BSC address: factoryAddress, }); // Call the function const vestingWallets = await factoryContract.call({ functionName: "getVestingWalletInstanceInfos", params: [beneficiary], }); // Returns array of vesting wallet instances for this beneficiary console.log(vestingWallets); ``` **Finalize Configuration (Owner Only)** ```typescript import { getContract } from "thirdweb"; import { prepareContractCall, sendTransaction } from "thirdweb"; // Get vesting wallet contract instance const contract = getContract({ client, chain: 56, // BSC address: vestingWalletAddress, }); // Before releasing tokens, owner must finalize the configuration const owner = await contract.call({ functionName: "owner", }); if (owner !== currentAddress) { throw new Error("Unauthorized: Only owner can finalize"); } // Check if already finalized const isFinalized = await contract.call({ functionName: "tranchesConfigurationFinalized", }); if (!isFinalized) { // Prepare finalization transaction // This will fail if TGE + linear + tranches != totalAllocation const transaction = prepareContractCall({ contract, method: "function finalizeTranchesConfiguration()", }); // Send transaction await sendTransaction({ transaction, account, }); } ``` **Release Vested Tokens** ```typescript import { getContract } from "thirdweb"; import { prepareContractCall, sendTransaction } from "thirdweb"; // Get vesting wallet contract instance const contract = getContract({ client, chain: 56, // BSC address: vestingWalletAddress, }); // Verify finalization before release const isFinalized = await contract.call({ functionName: "tranchesConfigurationFinalized", }); if (!isFinalized) { throw new Error("VestingNotFinalized: Configuration must be finalized first"); } // Prepare release transaction // IMPORTANT: Anyone can call release() - no owner privileges required // The function only requires that the configuration is finalized const transaction = prepareContractCall({ contract, method: "function release()", }); // Send transaction await sendTransaction({ transaction, account, }); ``` ### Errors MCP tools return errors in the standard JSON format: ```json { "error": "UNAUTHORIZED", "message": "Unauthorized: user session not found or expired." } ``` ## Common Error Codes ### MCP Tool Errors | Code | Description | | ------------------------ | ------------------------------------------------------------------- | | `UNAUTHORIZED` | User session is missing or expired. | | `INSUFFICIENT_ALLOWANCE` | Insufficient token approval for the factory contract. | | `INVALID_SIGNATURE` | Signature verification failed. | | `INVALID_INPUT` | Input parameters do not match schema (e.g., Zod validation failed). | | `UNSUPPORTED_CHAIN` | Chain ID is not supported by MCP. | ### Contract-Level Errors | Error Code | Description | | ------------------------- | -------------------------------------------------------------------------------------------------------- | | `NotEnoughFundsToVest()` | The `walletAddress` (msg.sender) does not have enough LONG tokens. Must have at least `totalAllocation`. | | `VestingNotFinalized()` | Configuration has not been finalized. Call `finalizeTranchesConfiguration()` first (owner only). | | `VestingFinalized()` | Configuration is already finalized and cannot be modified. | | `Unauthorized()` | Caller is not the owner of the vesting wallet. Only owner can finalize or add tranches. | | `AllocationNotBalanced()` | `TGE + linear + tranches` does not equal `totalAllocation`. Cannot finalize until balanced. | | `OverAllocation()` | `TGE + linear + tranches` exceeds `totalAllocation`. Cannot add more tranches. | | `NothingToRelease()` | No vested tokens are available to release at the current time. | | `TrancheBeforeStart()` | Tranche timestamp is before the vesting start timestamp. | | `TrancheAfterEnd()` | Tranche timestamp is after the vesting end timestamp. | | `NonMonotonic()` | Tranche timestamps must be in non-decreasing order. | ## Important Notes 1. **Backend Signature, Frontend Execution:** - The backend creates a signature for the vesting wallet deployment - The transaction is executed on the frontend from the user's wallet (`walletAddress`) - The user's wallet must have tokens and approve the factory contract - This allows separation of concerns: backend handles authorization, frontend handles execution 2. **Token Requirements:** - The `walletAddress` must have at least `totalAllocation` LONG tokens - The `walletAddress` must approve the factory contract for `totalAllocation` amount - Tokens are transferred from `walletAddress` to the vesting wallet during deployment - The `walletAddress` becomes the owner of the vesting wallet 3. **Finalization Requirement:** The vesting configuration must be finalized before tokens can be released. This is a one-time operation that makes the schedule immutable. 4. **Allocation Balance:** The sum of `tgeAmount + linearAllocation + tranchesTotal` must exactly equal `totalAllocation` for finalization to succeed. 5. **Owner vs Beneficiary:** - **Owner:** The `walletAddress` that deployed the vesting wallet. Only owner can finalize configuration and add tranches. - **Beneficiary:** The address that receives vested tokens when `release()` is called. Can be different from the owner. 6. **Function Access Control:** - **Owner-only functions:** - `addTranche()` - Add a single tranche - `addTranches()` - Add multiple tranches - `finalizeTranchesConfiguration()` - Finalize the vesting configuration - **Public functions (anyone can call):** - `release()` - Release vested tokens to beneficiary (requires finalized configuration) - View functions (`vestedAmount()`, `releasable()`, etc.) - Read-only, anyone can call 7. **Release Access:** Once finalized, **anyone can call `release()`** to transfer vested tokens to the beneficiary. The beneficiary does not need to call it themselves, and the owner is not required to trigger releases. 8. **Tranches:** Optional step-based vesting amounts that unlock at specific timestamps. Must be added before finalization. # Media Upload Guide for MCP ::doc-figure --- height: 450 width: 800 alt: A ring of purple digital assets beside Powering the Future of the Creator Economy. caption: Use media collections to organize and gate access to the content you publish. placement: lead source-url: https://t.me/belongnet/216 src: https://docs.belong.net/media/social/creator-economy.webp --- :: ## Overview This document outlines the process of uploading media assets (e.g., images, videos) to NFT collections using MCP (Model Context Protocol) tools and APIs. The process involves authenticating a user, uploading media files to a storage service, and attaching them to an NFT collection. The media is then used to update the collection's metadata, including generating a contract URI for blockchain integration. Use this flow after you have a collection to attach assets to. Uploading a file and associating it with a collection are distinct operations: the resulting metadata tells apps which image or video belongs to that collection. Keep the collection identifier consistent from upload through metadata update. > **📋 Prerequisites:** Ensure [MCP integration](https://docs.belong.net/getting-started/mcp) is set up with your API key and user authentication is configured. ## Process Flow ::mermaid ```text flowchart TD A[Start: User Authentication] --> B[1. Validate Collection Ownership] B --> C[2. Upload Media Files] C --> G[3. Update Collection Media] G --> H[4. Generate Contract URI] H --> I[End: Media Attached] ``` :: ## MCP Tools ### Upload Collection Media **Tool:** `add-collection-media` **Description:** Uploads media files and attaches them to an NFT collection by ID. Validates user ownership and ensures the total media count does not exceed the maximum allowed (`2` files). **Input data:** ```typescript { id: string, // Collection ID files: Array<{ // Media files to upload (max 2) base64: string, // Base64-encoded media (e.g., "data:image/png;base64,...") filename?: string // Optional filename }> } ``` > **📝 File Order:** The order of files matters: > > - **First file** — NFT image (used for individual NFT display) > - **Second file** — Collection cover image (used for collection display) **Output data:** ```typescript Array<{ id: string; // Media asset ID url: string; // Media URL mime: string; // MIME type (e.g., "image/png") size: number; // File size in bytes w: number; // Width (for images) h: number; // Height (for images) lg: string | null; // Large thumbnail URL md: string | null; // Medium thumbnail URL sm: string | null; // Small thumbnail URL xs: string | null; // Extra-small thumbnail URL blurhash: string; // Blurhash for image preview }>; ``` ## API Endpoint ### POST `/media/:id/collection` **Summary:** Upload media and attach them to an NFT collection by ID. **Description:** Uploads up to `2` media files (max `10MB` each, supported MIME types: `image/jpeg`, `image/png`, `image/webp`, `video/mp4`, `video/webm`) and attaches them to the specified collection. Requires user authentication and ownership of the collection. > **📝 File Order:** The order of files matters: > > - **First file** — NFT image (used for individual NFT display) > - **Second file** — Collection cover image (used for collection display) **Request:** - **Path Parameters:** ```typescript { id: string; // Collection ID } ``` - **Form Data:** ```typescript { files: File[] // Media files (max 2, 10MB each) } ``` **Responses:** - **200 Success:** ```typescript Array<{ id: string; url: string; mime: string; size: number; w: number; h: number; lg: string | null; md: string | null; sm: string | null; xs: string | null; blurhash: string; }>; ``` - **400 Bad Request:** If the total media count exceeds `2` or files are invalid. - **403 Forbidden:** If the user is not the collection owner. ## Usage ### Upload Media via MCP Tool ```js const result = await mcp.callTool("add-collection-media", { id: "collection-id-123", files: [ { base64: "data:image/png;base64,iVBORw0KGgo...", filename: "nft-image.png", }, // First: NFT image { base64: "data:image/png;base64,iVBORw0KGgo...", filename: "cover.png" }, // Second: Collection cover ], }); const media = result.content[0].text; // Array of MediaAsset console.log("Uploaded Media:", media); ``` ### Upload Media via HTTP API ```js const formData = new FormData(); formData.append("files", nftImageFile); // First: NFT image (e.g., from ) formData.append("files", coverImageFile); // Second: Collection cover const response = await fetch("/media/collection-id-123/collection", { method: "POST", headers: { "x-api-key": "your-token" }, body: formData, }); const media = await response.json(); console.log("Uploaded Media:", media); ``` ## Errors - **Maximum Files Exceeded:** `"Cannot upload X files. Maximum allowed is 2 files total. Current count: Y"` - **Forbidden:** `"Forbidden"` (if the user is not the collection owner) - **Invalid Files:** Thrown if files exceed `10MB` or have unsupported MIME types. # Whitelabel Launch Kit ::doc-figure --- height: 450 width: 800 alt: Branded phone screens beside Whitelabel iOS, Android and Web Apps. caption: Prepare your branding and launch requirements for a custom iOS, Android, and web experience. placement: lead source-url: https://t.me/belongnet/281 src: https://docs.belong.net/media/social/whitelabel-apps.webp --- :: ## Overview Belong delivers a fully branded iOS, Android, and Web experience for eligible organizations: your logo, colors, and domain running on our infrastructure. Payments (Apple Pay, Google Pay, cards, crypto), memberships, events, referrals, and analytics ship out of the box so teams can focus on programs instead of wiring platforms together. Start with this checklist if your organization wants a branded app operated by Belong. Gather the brand assets, app identity, and store-account details together before requesting a build, so the same identity carries from the website to the mobile app and check-in experience. > Want the full marketing rundown? Read the public overview at [belong.net](https://belong.net). **Launch pacing:** most orgs go live in under two weeks with standard features; deeper integrations can take longer. The platform fee is waived for qualified organizations (normal payment processing still applies). ## Launch Requirements Prepare the items below before requesting a branded Belong app. Required items unblock build and review; optional items can be added later if they are not ready at launch. ### 1. App Identity - Localized app name, with exact spelling for each target language. - Public domain (`https://...`) that will host the experience. - iOS `bundleId`. - Android `packageName`. - UID slug (2–60 characters). ### 2. Branding Assets - App icon (`iconOnly`, required). SVG is preferred; PNG, WebP, or JPEG can be used when vector artwork is unavailable. - Icon foreground and background variants (optional). - Splash screen (required). Layered vector artwork is preferred. - Splash dark variant (optional). - Logo (optional, for in-app and marketing surfaces). SVG is preferred for crisp scaling. ::doc-figure --- height: 1013 width: 1440 alt: A purple and gold check-in kiosk with the words Check In Your Brand. caption: Prepare your own logos, colors, and check-in presentation for the branded experience. placement: inline source-url: https://t.me/belongnet/478 src: https://docs.belong.net/media/social/check-in-your-brand.webp --- :: ### 3. Experience Settings - Default theme (`auto`, `dark`, or `light`). - Onboarding redirect path (must match `/activities/...` or `/hubs/...`). - App switcher disabled? (`true` / `false`). ### 4. Access & Localization - Desired login providers (facebook, google, apple, phone, siwe, sui) with enable/disable flag per provider. - Target deployment environment (production or dev). - Linked App Locale entry (name, description, JSON reference). - AI chat URL (optional, localized). ### 5. Store & Support Details - App Store ID (9–10 digit numeric, optional). - Support channels with values (telegram, facebook, instagram, x, email, link). ### 6. Integrations - Analytics: - Meta Pixel ID. - Google Analytics ID. - Cookie3 Site ID. - Plausible enabled? If yes, Plausible API host. - Google Maps map IDs (iOS / Android / Web). - SEO metadata (localized): meta title, meta description (50–160 chars), meta image, meta social entries, keywords, robots, structured data, viewport, canonical URL. ## Request Flow 1. Gather the launch requirements above. 2. Mark any optional values that should be deferred. 3. Submit the request through the organization request form or Belong support channel. 4. Belong reviews eligibility, confirms blockers, and coordinates the launch timeline. ## Localization Bundle Pull the latest English copy from the JSON bundle below. Share with translators or clone it for additional locales. Keep vector asset preferences in mind when requesting localized splash or icon updates. ::u-button --- icon: i-lucide-download target: _blank to: https://docs.belong.net/source/en.json --- Download `en.json` :: ### How to Request Localization Updates 1. Download the current `en.json`. 2. Duplicate only the keys you plan to change into a new file (e.g., `en.your-whitelabel-name.json`). Keep the JSON shape flat: key/value pairs with no extra copy. 3. For each string that needs translation or revision, include: - The existing key. - The current English value. - The requested new value (if already translated) or a comment showing “NEEDS TRANSLATION”. 4. Share that patch file with the Belong team. Belong will merge approved updates and regenerate downstream locale bundles. **Example patch (`en.mission-hills.json`):** ```json { "alert-google-contacts": "Enable Google Contacts to find friends to follow on Mission Hills", } ``` ## Reference Materials - Canonical marketing copy: [Whitelabel App](https://belong.net) # Belong CheckIn App Features ::doc-figure --- height: 451 width: 800 alt: A phone showing Belong beside App Version 2.0 Is Now Live. caption: Use the app to discover events, manage access, and check in at participating venues. placement: lead source-url: https://t.me/belongnet/336 src: https://docs.belong.net/media/social/belong-app-experience.webp --- :: ## Overview Belong CheckIn brings venues, events, communities, wallets, rewards, and AI-assisted creation into one public app experience. The app is wallet-optional for visitors and supports more advanced wallet, ticketing, and venue-payment flows when a user chooses to connect or create a wallet. Use this map to choose the guide for your role: guests can start with [Wallet & Sign-In](https://docs.belong.net/belong-checkin/wallet-and-auth), venue teams with [Venue Quick Start](https://docs.belong.net/belong-checkin/venue-quickstart), and builders with [Integration Overview](https://docs.belong.net/belong-checkin/developer/integration-overview). Each feature depends on the venue or event configuration described in its guide. Use this page as a product-level map of the shipped app surfaces. For low-level API and MCP tool details, see [Belong CheckIn Crypto Guide](https://docs.belong.net/guides/crypto/checkin), [CheckIn MCP Tools](https://docs.belong.net/mcp/tools-check-in), and [Sponsored Gas Ledger Guide](https://docs.belong.net/guides/crypto/sponsorship). ## CheckIn Modes Belong CheckIn supports one primary access mode per venue or hub: | Mode | Visitor experience | Best for | | -------------- | -------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------- | | Free check-in | Visitor scans the venue QR and confirms attendance without payment. | Meetups, free community visits, simple attendance tracking. | | Venue payment | Visitor completes the offered wallet or enabled thirdweb card flow and can receive configured rewards after payment. | Restaurants, bars, cafes, venues, and paid local experiences. | | NFT ticket | Visitor must hold or buy the event ticket NFT before check-in. | Conferences, concerts, ticketed events, and gated entry. | | NFT membership | Visitor must hold a membership NFT before check-in. | Clubs, communities, recurring programs, and member-only spaces. | Venue payment supports three amount flows: - Customer-entered amount. - Owner-set quote sent after the visitor requests a payment. - Fixed amount configured by the venue. Static payment-request QR codes are available for owner-set quote flows. A venue can place a QR at a table, bar, register, or receipt; the visitor scans it, staff enters the amount, and the visitor completes payment from the app. ## Regular and NFT tickets Organizers can offer **regular (non-NFT) tickets** with **Stripe Connect** card payments, or **NFT tickets** through the configured NFT checkout partner with card or crypto methods where enabled. Regular checkout creates a ticket registration and entry QR without requiring an NFT collection. NFT checkout delivers the configured ticket NFT. The hub access modes above describe venue settings; they do not make all event tickets NFTs. Direct venue QR payments and event-bracelet top-ups have their own supported routes and availability. See [Payments](https://docs.belong.net/belong-checkin/payments-and-onramp). ## Venue Setup Venue operators can configure: - Payment network: BNB Chain Mainnet or BSC Testnet. - Accepted payment tokens: USDC, LONG, or both. - LONG handling: auto-stake, auto-convert to USDC, or direct transfer. - Visitor rewards: fixed visit bounty and/or spend percentage. - Promoter rewards: fixed referral bounty and/or spend percentage. - Daily check-in limits. - Venue approval requirements. - Location or QR-based verification settings. Each venue has a payment account, also shown in the UI as a venue wallet. Operators can add reward balance, view the payment network, copy the address, and see whether the venue is active. ## Rewards And History Visitors can review their CheckIn history from the wallet and CheckIn areas. Venue operators can review pending approvals, recent requests, and reward activity tied to their venues. Rewards can be attributed to: - Visitors who check in directly. - Promoters who bring visitors through referral links or QR flows. - Shared reward splits when both visitor and promoter rewards are configured. ## Wallet And Sign-In The app supports guest access, email sign-in, Belong account linking, and wallet-backed flows. Users can manage wallet balances, transactions, tickets, rewards, vesting, and venue payment accounts from the wallet area. Passkeys can be linked to a signed-in account for faster future sign-in with Face ID, Touch ID, or device biometrics. Linked passkeys can be viewed and deleted from Profile Integrations. Wallet screens also show native gas token balances for EVM networks. When a sponsored flow cannot continue because gas coverage needs attention, the app can guide the user back to the wallet funding or recovery surface. ## Sponsored Gas Sponsored gas helps eligible users complete supported on-chain actions without holding the native gas token for the selected EVM network. Belong sponsors only network gas; the user still pays any ticket, NFT, venue payment, or other purchase amount. Public sponsored flows include: - NFT mint gas sponsorship when collection sponsorship is enabled and the operation passes eligibility checks. - CheckIn card and wallet flows where an ERC-20 approval or payment path is eligible. - Venue or collection gasless toggles that control whether sponsorship checks are available. The sponsorship ledger tracks balances, deposits, reservations, and usage. The frontend cannot choose the sponsor wallet or spend coverage directly; the backend validates eligibility and sponsorship approval before gas is sponsored. ## Bracelet Stored Value Venues can enable NFC bracelet payments for compatible experiences. Visitors can link a bracelet, top up balance, use it for supported venue or membership flows, and review balance activity. Operators can configure: - Display currency. - Accepted top-up tokens. - Minimum and maximum top-up amounts. - Refund availability. - Charge categories. - Pool wallet for bracelet top-ups. ## Events, Tickets, And Maps Belong supports event creation, ticketed events, event-week pages, and public event maps. Event-week maps can be shared publicly and prioritize active location context when available. Events can use regular Stripe Connect tickets without an NFT collection, or NFT ticket mode can connect hub access with NFT ticket tiers. If no ticket event is attached, the app can guide the organizer into chat-assisted paid event setup. ## AI And Voice Creation The chat assistant can help create and edit events, hubs, CheckIn campaigns, regular or NFT tickets, and related flows from natural language. Voice mode supports audio input, transcription, and event creation assistance. When a workflow needs wallet signing, the app shows an inline signing or transaction surface instead of asking users to copy contract details manually. ## Telegram Mini App Belong's public Telegram integration lets users open the app from Telegram, link a Belong account, manage event workspaces, and use Mini App flows for app-level editing and signing. Supported public Telegram experiences include: - Private bot commands for account state, event discovery, hub discovery, event creation, and workspace switching. - Linked hub groups for hub events and check-in guidance. - Event-week group commands for event-week status and map links. ## Public What's New The app includes a public What's New page at [`/changelog`](https://checkin.belong.net/changelog). It reads approved, published entries from the public changelog view and groups updates by date. Entries are categorized as: - New Feature. - Improvement. - Bug Fix. - Update. # Telegram Bot & Mini App ::doc-figure --- height: 562 width: 800 alt: "A person holding a phone beside Belong CheckIn: AI and Voice." caption: Use Telegram chat for event workspaces and the Mini App for editing and signing. placement: lead source-url: https://t.me/belongnet/414 src: https://docs.belong.net/media/social/checkin-ai-and-voice.webp --- :: ## Overview Belong's public Telegram bot lets organizers create event workspaces from chat, browse public events and hubs, link Telegram groups to hubs, configure event-week alerts, and open the **Belong Mini App** for app-level editing and signing. Start in a private chat to check your account and active workspace, then use group commands where the bot is linked to a hub or event. The bot is the chat entry point; the Mini App provides the fuller editing and signing screens. This is separate from [connecting your own AI Deploy agent to Telegram](https://docs.belong.net/ai-deploy/channels/telegram). ## Command reference ### Private bot chat | Commands | What you can do | | ------------------------------------------------------------------------------------------- | ------------------------------------------------------------------- | | `/start`, `/help`, `/status` | See bot help, account state, active workspace, and chat ID | | `/login you@example.com`, `/code 123456`, `/link YOURCODE`, `/unlink` | Link or unlink a Belong account for organizer actions | | `/events`, `/discover `, `/hubs ` | Browse public events and hubs | | `/createevent
`, `/new-event`, `/wizard free`, `/wizard paid` | Create an event from text, voice, media, or guided setup | | `/switch`, `/miniapp`, `/spaces` | Switch active workspace, open the Mini App, or link Telegram spaces | | `/myevents`, `/myhubs`, `/campaigns [days]`, `/eventstats EVENT_ID`, `/referral [EVENT_ID]` | Linked-account organizer workflows | | `/venue [HUB_ID]`, `/approve` | Review venue check-in status and pending approvals | ### Linked hub group | Commands | What you can do | | ----------------------------------------------------- | ---------------------------------------------------------- | | `/chatid`, `/help`, `/hubinfo`, `/events`, `/checkin` | Link a group to a hub and show hub/event/check-in guidance | ### Event-week group | Commands | What you can do | | -------------------------------------------------------------------------------- | ---------------------------------------------------------------------------- | | `/eventweek`, `/eventweek SLUG`, `/eventweek now`, `/eventweek off`, `/eventmap` | Link a group to an event week, post overview/map updates, and disable alerts | ::note Telegram command menus can't contain hyphens, so menu entries use `/createevent` . Aliases like `/new-event` still work when typed manually. :: ## The Mini App - `/miniapp` sends a button that opens the Belong Mini App, signs you into Belong, and loads your Telegram workspace. - Post-create prompts include a link to the new event plus a button to open the Mini App. - The Mini App is where app-level editing and signing happen from inside Telegram. ## Linking a group to a hub Hub operators can connect a Telegram group so the bot can post hub events and check-in guidance: 1. Add the bot to your Telegram group 2. Run `/chatid` in the group 3. Save that chat ID in the hub's Telegram settings card For event-week alerts, the person linking the group must be a group admin and must have linked a Belong account in private chat first. ## Related - [Event Creation](https://docs.belong.net/belong-checkin/event-creation) - [App Features](https://docs.belong.net/belong-checkin/app-features#telegram-mini-app) Telegram's own references: [Mini Apps](https://core.telegram.org/bots/webapps) and the [Bot API](https://core.telegram.org/bots/api). # Apple Wallet Passes ::doc-figure --- height: 1013 width: 1440 alt: A phone displaying a pass with the words Add the Pass Before Doors. caption: Save an issued pass ahead of arrival so its entry QR is ready at the door. placement: lead source-url: https://t.me/belongnet/482 src: https://docs.belong.net/media/social/apple-wallet-before-doors.webp --- :: ## Overview After buying a ticket in Belong CheckIn, attendees on iOS can add it to **Apple Wallet**. The pass carries the same check-in QR code used in the app, so it works quickly at the door — even offline. Save the pass before leaving for the venue so you can open the entry QR without searching through messages at the door. Adding a pass makes an already-issued ticket easier to present; it does not buy another ticket or change which payment route issued it. A regular ticket paid through Stripe Connect does not need to be an NFT. NFT tickets use their configured checkout partner, which can also accept cards. The Wallet pass is an entry credential for a supported issued ticket; it is not a payment processor or a ticket-format choice. See [Payments](https://docs.belong.net/belong-checkin/payments-and-onramp). ## Where to find it An **Add to Apple Wallet** button appears wherever you can see a purchased ticket: - The event modal, under **Your tickets** - The **Wallet → Tickets** tab ## How it works 1. Tap **Add to Apple Wallet** on a purchased ticket 2. The app securely generates a `.pkpass` for that ticket and opens the native Apple Wallet dialog 3. The pass holds your ticket details and the canonical check-in QR (the same one used in the app) 4. At the event, present the pass — staff scan the QR to verify the issued ticket and check you in If a pass can't be generated (for example on non-iOS devices), the app falls back to copying your ticket link so you can still access it. ## Requirements - An iOS device with Apple Wallet - A purchased ticket tied to your account ::note Your ticket always remains accessible in the app even if a Wallet pass isn't available — the pass is a convenience, not a requirement for entry. :: ## Related - [Event Creation](https://docs.belong.net/belong-checkin/event-creation) - [Check-In Modes](https://docs.belong.net/belong-checkin/check-in-modes) — ticket admission and NFT-specific access checks # Payments ::doc-figure --- height: 1013 width: 1440 alt: A purple card terminal with the words Card In, Ticket Out. caption: Card payment is available through different configured checkout routes; the route determines which ticket is delivered. placement: lead source-url: https://t.me/belongnet/484 src: https://docs.belong.net/media/social/card-in-ticket-out.webp --- :: ## Overview Belong CheckIn supports **regular (non-NFT) tickets and NFT tickets**. Paying by card does not determine which ticket a buyer receives: regular ticket payments use **Stripe Connect**, while NFT purchases use the configured NFT checkout partner and can also accept cards. Venue payment-request QR codes are a separate payment flow. First identify what the customer is buying: a regular event ticket, an NFT ticket, or a venue payment. Then follow that route through payment confirmation and delivery. **Onramp** means a supported way to fund a crypto wallet or enter an on-chain payment flow; availability depends on the configured provider and network. ::mermaid ```text flowchart TD accTitle: Choose the payment route accDescr: Regular tickets use Stripe Connect and deliver an entry QR. NFT checkout delivers an NFT. Venue payments record a venue payment or check-in. A[What is the payment for?] --> B[Regular event ticket] A --> C[NFT ticket] A --> D[Venue payment] B --> E[Stripe Connect] E --> F[Registration and entry QR] C --> G[NFT checkout partner] G --> H[Ticket NFT] D --> I[Venue payment route] I --> J[Venue payment recorded] ``` :: For regular tickets, confirmed payment is fulfilled into a registration and entry QR. NFT checkout instead issues the configured NFT. A venue payment records the venue transaction; it does not become a Stripe ticket order. ## Card checkout | Route | Customer payment | What the customer receives | | ------------------------------ | --------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------- | | Regular (non-NFT) event ticket | Credit or debit card through Stripe Connect | A paid ticket registration and entry QR; an NFT or crypto wallet is not required for the purchase | | NFT ticket | Card or crypto through the configured NFT checkout partner, where available | A ticket NFT after the purchase completes | | Venue payment-request QR | The venue's supported wallet payment or enabled thirdweb card route | A recorded venue payment/check-in; this is not the Stripe Connect ticket-order checkout | ### Regular ticket payments with Stripe Connect Organizers connect their Stripe payout account and enable card payments for the event. A ticket tier can accept cards without an NFT collection. The buyer chooses a tier and quantity, completes hosted Stripe Checkout, and receives a regular ticket registration and entry QR after confirmed payment and fulfillment. Stripe Connect processes the payment on the organizer's connected account. A successful card charge and delivery of the ticket are separate stages: if delivery is still pending, check the existing order rather than paying again. Available events and payment methods depend on the organizer's configuration and payment readiness. ### NFT ticket checkout by card or crypto For an NFT ticket, the configured NFT checkout partner handles the purchase. Credit and debit cards can be available as well as supported crypto wallets; a card purchase can still deliver an NFT. The available methods depend on the checkout partner, network, and collection configuration. The hosted [NFT Checkout](https://docs.belong.net/belong-checkin/developer/nft-checkout) integration documents its thirdweb wallet and enabled card methods. Do not describe every card purchase as a Stripe Connect purchase or every paid ticket as an NFT. See [Fees & Staking](https://docs.belong.net/belong-checkin/fees-and-staking) for the separate card-processing and NFT fee categories. ### Venue payments and bracelet balances The existing Venue payment flow settles supported USDC/LONG payments through the venue payment account. Where enabled, thirdweb's card checkout can help a customer complete that payment. It is separate from regular Stripe Connect ticket checkout; connecting Stripe for event tickets does not automatically enable Stripe for every venue QR payment. Stripe Connect card top-ups for event bracelets are a separate, configuration-gated route. Only describe them as available when the event and the `bracelet_topups` payment capability report availability. A regular ticket payment being available does not prove bracelet top-ups are enabled. ## Payment-request QR For venues where staff confirm the amount before a customer pays (for example, a POS total), use a **payment-request QR**. The customer scans, staff send the amount, and the customer completes the supported payment route shown in the app. ::doc-figure --- height: 562 width: 800 alt: A phone at a venue counter beside Pay Your Tab With Your Phone. caption: For a venue payment request, staff confirm the amount and the guest completes the payment on their phone. placement: inline source-url: https://t.me/belongnet/415 src: https://docs.belong.net/media/social/pay-your-tab.webp --- :: ### Operator flow 1. In **Hub details → CheckIn → General**, set **Check-in Access** to **Venue payment** 2. In **Venue**, set the venue payment flow to **owner-set amounts** 3. On the **Check-in QR Code** card, switch from **Check-in** to **Pay request** 4. Optionally add a label such as `Table 12`, `Bar`, `Patio`, or `Register 2` 5. Print, download, copy, or share the QR 6. When a visitor scans it, a pending request appears for staff with the source and label 7. Staff send the amount; the visitor pays and the check-in is marked paid ### Customer flow 1. The visitor scans the payment-request QR 2. The app confirms the venue still accepts owner-quoted payments 3. The visitor confirms the request 4. Staff send the amount 5. The visitor completes the offered wallet or enabled card route and the transaction is recorded ::note The payment-request QR uses a separate link from the standard check-in QR, and the app re-validates the venue's settings on every scan — a stale QR can't be used to force a payment. :: ## Related - [Venue Quick Start](https://docs.belong.net/belong-checkin/venue-quickstart) - [Check-In Modes](https://docs.belong.net/belong-checkin/check-in-modes) - [Fees & Staking](https://docs.belong.net/belong-checkin/fees-and-staking) # Sponsored Gas ::doc-figure --- height: 562 width: 800 alt: A ticket illustration with the words No Gas Needed, Mint the Pass. caption: Eligible sponsorship covers the network fee; the ticket or purchase price is still payable. placement: lead source-url: https://t.me/belongnet/433 src: https://docs.belong.net/media/social/sponsored-network-fees.webp --- :: ## Overview Sponsored gas lets eligible users complete supported on-chain actions — like an NFT mint or a check-in payment — **without holding the native gas token** for the network. Belong sponsors only the network gas; you still pay any ticket, NFT, or venue payment amount. **Gas** is the network fee for a blockchain transaction. Think of sponsorship as covering that fee while leaving the ticket or venue bill unchanged. For example, an eligible NFT mint can be sponsored even though the attendee still pays the NFT price. ::note This flow is in beta. Exact limits and enabled scenarios may change during testing. :: ## What sponsored gas does and doesn't do - ✅ Belong covers the **technical cost** of the blockchain transaction (gas) - ❌ Belong does **not** pay for your purchase - ❌ Belong does **not** pay a venue or collection purchase on your behalf - ✅ For eligible promoter reward withdrawals, Belong may submit the withdrawal transaction and charge only the sponsor's gas bank for network gas If a flow has a paid amount, you still need funds for that payment (or you can pay through the card flow). ## Who does what | Actor | Responsibility | | ------------------ | ---------------------------------------------------------------------------------------------------- | | **You** | Sign the operation and pay for the item, ticket, or payment amount | | **Belong CheckIn** | Shows the gasless flow, checks whether sponsorship is available, and submits the operation | | **Belong API** | Maintains the sponsorship ledger; checks permissions, settings, and limits; records actual gas usage | | **Gas sponsor** | Sponsors gas on-chain after server-side approval | | **Gas bank** | Shared sponsorship wallet that funds sponsored gas | ## What's sponsored in beta | Flow | What's sponsored | What you pay | | -------------------------- | -------------------------------------------------------- | ---------------------------------------------------------------- | | NFT mint with ERC-20 price | Gas for approve and mint (when enabled and eligible) | The NFT price in the token | | NFT mint with native price | Not sponsored | Native value and gas | | Check-in card flow | Gas for the ERC-20 approval | Payment via the checkout widget | | Check-in wallet flow | Approved low-gas ERC-20 cases | The payment amount | | Promoter reward withdrawal | Gas for the withdrawal when the venue sponsor enables it | No purchase amount; rewards come from the venue campaign balance | ## Why it's safe Sponsorship is validated entirely on the server — the frontend can't inflate spending or choose where the budget goes: - The frontend never picks the sponsor wallet or the amount to deduct - Belong API resolves the sponsor from the venue or collection - It checks that the signed-in user owns the wallet used, that sponsorship is enabled, and that the operation type and token/spender/amount match - A budget is **reserved** before spending, so the same balance can't be used twice in parallel - Gas is only sponsored after the server approves the exact operation - After the receipt, only the actual gas used is recorded against the ledger ## Related - [Sponsored Gas Ledger Guide](https://docs.belong.net/guides/crypto/sponsorship) — the developer view of eligibility checks and usage recording - [Wallet & Sign-In](https://docs.belong.net/belong-checkin/wallet-and-auth) # Fees & Staking ::doc-figure --- height: 450 width: 800 alt: Purple tokens and gift boxes beside Unlock Bigger Rewards with LONG. caption: LONG staking tiers determine the fee and reward benefits listed in this guide. placement: lead source-url: https://t.me/belongnet/201 src: https://docs.belong.net/media/social/long-staking-rewards.webp --- :: ## Overview This page explains the fees in Belong CheckIn and how staking **LONG** lowers them. The on-chain fee categories below cover NFT minting, venue campaign deposits, and withdrawals. Regular ticket card payments use Stripe Connect and have a separate checkout/payment fee breakdown. Find the fee for the action you are taking before applying a staking discount. Buying a regular ticket, funding a venue campaign, minting an NFT, and withdrawing rewards are different stages. The tables below keep those charges separate so a discount in one category is not mistaken for a discount on every payment. ## Regular tickets and card-processing fees Regular (non-NFT) tickets paid through Stripe Connect do not mint an NFT, so NFT minting and resale fees below do not apply to that purchase. Stripe processing costs and any separately configured application fee are governed by the organizer's payment setup and the checkout shown to the buyer. Do not apply the NFT mint fee to every paid ticket. NFT tickets can also be purchased by card through the configured NFT checkout partner. Card processing is a payment-method cost; minting is part of the NFT ticket route. See [Payments](https://docs.belong.net/belong-checkin/payments-and-onramp). ## NFT ticket & membership fees | Fee | Rate | Paid by | When | | ------------------------ | --------------------------- | ------- | --------- | | Primary mint fee | 2% | Buyer | At mint | | Secondary issuer royalty | 0–8% (configurable, max 8%) | Buyer | On resale | | Belong resale fee | 2% | Buyer | On resale | The 2% primary mint fee applies to every ticket or membership mint. For resales, ticket issuers can set an optional secondary-sale royalty from 0–8%, and Belong charges an additional 2% resale fee on top. ## Venue deposit fees When a venue deposits USDC to fund customer and promoter rewards: | Deposit | Platform fee | Convenience fee | | ---------------- | ------------ | --------------- | | First 2 deposits | 0% | $5 | | Standard | 10% | $5 | ### Staking discounts (deposits) Venues can reduce the platform fee by staking LONG: | Tier | LONG staked | Platform fee | | -------- | ----------- | ------------ | | Standard | 0 | 10% | | Bronze | 50,000+ | 9% | | Silver | 250,000+ | 8% | | Gold | 500,000+ | 7% | | Platinum | 1,000,000+ | 5% | ## Withdrawal fees When venues or promoters withdraw earnings: | Method | Fee | | ------------------------- | ----------------------- | | USDC withdrawal (instant) | 10% | | LONG withdrawal | 5% → 1% by staking tier | ### Staking discounts (LONG withdrawals) | Tier | LONG staked | Withdrawal fee | | -------- | ----------- | -------------- | | Standard | 0 | 5% | | Bronze | 50,000+ | 4% | | Silver | 250,000+ | 3% | | Gold | 500,000+ | 2% | | Platinum | 1,000,000+ | 1% | USDC withdrawals are always 10% regardless of tier; staking discounts apply to LONG withdrawals. ## What we don't charge for These are third-party costs passed straight through — Belong doesn't earn from them: | Service | Fee | Goes to | | -------------------------- | ------------------------------ | ---------------------------------------------- | | Card processing | Provider/account-specific rate | Stripe or the configured NFT checkout provider | | Blockchain gas | Variable | Network validators | | External payment providers | Provider's rates | Payment provider | ## At a glance | Fee source | Fee | Notes | | ------------------------ | ----------------------------------- | --------------------------- | | NFT primary mint | 2% | All ticket/membership mints | | Secondary resale | 0–8% issuer royalty + 2% Belong fee | Marketplace resales | | Venue deposit (standard) | 10% + $5 | First 2 deposits: 0% + $5 | | Venue deposit (Platinum) | 5% + $5 | 1M+ LONG staked | | USDC withdrawal | 10% | Instant cash-out | | LONG withdrawal | 5% → 1% | By staking tier | ## Related - [Venue Partner Guide](https://docs.belong.net/belong-checkin/venue-partner) - [LONG Staking Guide](https://docs.belong.net/guides/crypto/staking) — how to stake LONG # Connect Belong AI Deploy ::doc-figure --- height: 583 width: 800 alt: The AI Deploy by Belong logo on a dark violet background. caption: Connect your own deployed agent to Belong tools for event and venue workflows. placement: lead source-url: https://t.me/belongnet/403 src: https://docs.belong.net/media/social/ai-deploy-by-belong.webp --- :: ## Overview Belong CheckIn is a launch surface for [**Belong AI Deploy**](https://docs.belong.net/ai-deploy/overview) — your own AI agent running on your own cloud. You don't sign into AI Deploy separately: CheckIn uses your existing Belong-linked account and hands you off securely. Start here when you already use CheckIn and want to launch an agent from the same account. The account handoff takes you into AI Deploy; choosing a cloud, connecting an AI provider, and launching the server happen in the deployment wizard. ## How to enable it 1. Open **Settings** in Belong CheckIn 2. Find the **AI Deploy by Belong** card 3. If your account isn't linked to Belong yet, link it with the email one-time-code dialog 4. Click **Enable AI Agent for your account** 5. You're handed off to Belong AI Deploy, already signed in, to finish deploying your agent ## How the handoff works When you click enable, CheckIn issues a **short-lived, one-time code** and opens Belong AI Deploy with it. AI Deploy redeems that code server-to-server for your durable Belong identity, then continues setup. ::note The handoff is one-time and expires quickly — your browser never receives a reusable token, and your Belong account ID stays the durable link between the two products. :: ## What you get Once you're in Belong AI Deploy, you can launch a personal AI agent on your own cloud account and connect it to Telegram, WhatsApp, or Slack. See the [Belong AI Deploy Quick Start](https://docs.belong.net/ai-deploy/quickstart) to finish. ## Related - [Belong AI Deploy — Overview](https://docs.belong.net/ai-deploy/overview) - [Wallet & Sign-In](https://docs.belong.net/belong-checkin/wallet-and-auth) — Belong account linking # Venue QR Signage Examples ::doc-figure --- height: 1013 width: 1440 alt: A QR sign and phone with the words Place the QR, Beat the Queue. caption: Place your actual venue QR where guests wait. The QR drawn in this promotional illustration is not an entry credential. placement: lead source-url: https://t.me/belongnet/494 src: https://docs.belong.net/media/social/place-the-venue-qr.webp --- :: # Venue QR Signage — Marketing Message Examples Ready-to-use copy for venues to display alongside their Belong CheckIn QR code at reception desks, entrances, table cards, and digital screens. Choose the sign location before choosing the headline. Put the QR where guests can begin the intended flow while waiting, and state one action and one configured benefit. The artwork below is a placement illustration; print the real QR generated by your venue rather than a QR drawn inside promotional artwork. > **How it works:** Customers scan the QR code, check in, and earn rewards. If they refer friends who also check in, they earn a referral bounty too. Venues configure their own reward amounts. For campaign setup and reward configuration, see the [Venue Partner Guide](https://docs.belong.net/belong-checkin/venue-partner). :br Visitors can also explore the product at [belong.net/checkin](https://belong.net/checkin). --- ## Nightclubs & Bars ### Primary Messages (headline + subline) 1. **Bring Friends. Get Paid.**:br Scan to check in — earn cashback on every visit, plus a bonus when your crew shows up. 2. **Your Night Out Pays You Back**:br Check in, spend, and earn up to X% back in crypto. Refer friends for even more. 3. **Party Smart. Earn Rewards.**:br Scan this code to check in and start earning. The more friends you bring, the more you make. 4. **Get Rewarded for Being a Regular**:br Scan to check in every time you visit. Stack rewards. Cash out anytime. 5. **Turn Your Social Life Into Income**:br Check in. Bring friends. Earn real money — withdraw as USDC or LONG tokens. ### Table Card / Coaster Copy > **Scan. Check In. Earn.**:br > Every visit = rewards. Every friend you bring = bonus cash. :br > Point your camera here ➜ [QR] > **This round's on us (sort of)**:br > Check in now and get X% cashback on your tab tonight. :br[QR] --- ## Hotels & Resorts ### Reception / Front Desk 1. **Welcome Bonus: Check In Twice**:br Scan this code after you check in at the front desk — earn rewards on your stay and dining. 2. **Earn While You Stay**:br Scan to join our rewards program instantly. No app download. Earn cashback on every purchase during your visit. 3. **Loved Your Stay? Get Paid to Share It.**:br Refer friends to stay here. When they check in with your code, you both earn rewards. 4. **Your Next Stay Could Be Free**:br Earn crypto rewards every time you visit. Refer guests and watch your balance grow. 5. **Guests Who Refer Guests Get Rewarded**:br Share your referral code with friends. When they check in, you earn a percentage of their spend. ### In-Room Card > **Quick Scan, Real Rewards**:br > Check in via the QR code below to start earning cashback on spa, dining, and room service. :br > Your referral code is inside — share it and earn when friends book here too. :br[QR] --- ## Restaurants & Cafes ### Counter / Table Tent 1. **Eat Here. Earn Here.**:br Scan to check in and earn X% back on your meal. Bring a friend next time — earn even more. 2. **Cashback on Every Bite**:br Check in with Belong and earn crypto rewards on your bill today. No app needed. 3. **Your Favourite Spot Pays You Back**:br Scan. Check in. Earn rewards every time you dine with us. 4. **Tell a Friend, Earn a Meal**:br Refer friends to dine here. When they check in, you earn a bonus — every single time. 5. **Regulars Get Rewarded**:br The more you visit, the more you earn. Scan to start building your rewards today. ### Receipt / Bill Insert > Enjoyed your meal? Scan the QR on our table card to check in and earn X% cashback. :br > Share your code with friends — you'll earn a bonus every time they visit. --- ## Coworking Spaces & Gyms 1. **Work Out. Check In. Cash Out.**:br Scan to earn rewards on every visit. Refer members and earn a cut of their spend. 2. **Your Membership Pays You Back**:br Check in every visit to earn crypto rewards. Bring new members and stack referral bonuses. 3. **Sweat Now. Earn Now.**:br Scan this code, check in, and earn cashback — just for showing up. 4. **Build Your Network. Build Your Balance.**:br Refer professionals to this space. Earn a bonus every time they check in. --- ## Spas & Wellness Centres 1. **Relax and Earn**:br Scan to check in. Earn cashback on your treatment today. 2. **Self-Care That Pays**:br Check in via the QR code and earn rewards on every visit. Refer friends for extra bonuses. 3. **Share the Calm. Share the Rewards.**:br Loved your session? Refer a friend — you both earn rewards when they visit. --- ## Event Venues & Conference Centres 1. **Check In. Get Rewarded.**:br Scan to earn rewards for attending today's event. Refer others to future events and keep earning. 2. **Your Ticket Earns More Than Entry**:br Scan the QR code to check in and earn crypto rewards on your attendance. 3. **Bring Your Network. Earn Together.**:br Every colleague you refer earns you a bonus when they attend events here. --- ## Generic / Universal Messages These work across any venue type: 1. **Scan. Earn. Repeat.**:br Check in with Belong to earn rewards every visit. Refer friends to earn even more. 2. **Get Paid to Be Here**:br Scan this QR code to check in and start earning real rewards — cashback + referral bonuses. 3. **Bring Friends. Earn Cash.**:br Check in and share your referral code. Every friend who visits earns you money. 4. **Rewards for Regulars. Bonuses for Referrals.**:br Scan to check in — earn on every visit and every friend you bring. 5. **Your Social Circle = Your Income**:br Refer friends to this venue. Every time they check in, you earn a percentage. 6. **No App. No Card. Just Scan.**:br Point your camera at this code. Check in. Earn instant crypto rewards. 7. **Check In With Belong**:br Earn cashback on your spend + bonuses for every friend you bring. :br Withdraw anytime as USDC. No app download needed. --- ## Short-Form (for small signage, stickers, coasters) | Message | Best For | | ------------------------------- | ------------------ | | **Scan. Check In. Earn.** | Universal | | **Bring Friends. Get Paid.** | Nightlife, events | | **Cashback Every Visit** | Restaurants, cafes | | **Earn While You Stay** | Hotels | | **Refer & Earn** | All venues | | **No App Needed — Just Scan** | All venues | | **Your Tab Pays You Back** | Bars, restaurants | | **Get Rewarded for Showing Up** | Gyms, coworking | --- ## Messaging Guidelines for Venues **Do:** - Replace `X%` with the actual cashback percentage the venue has configured - Keep the primary message under 8 words - Always include a clear call-to-action ("Scan", "Check in", "Point your camera") - Mention referral earning if the venue has promoter rewards enabled - Emphasise "no app download" — it's a key differentiator **Don't:** - Promise specific dollar amounts unless the venue has confirmed them - Use "crypto" as the lead — lead with the benefit (cashback, earn, get paid), mention crypto as the mechanism - Overcomplicate — the QR code does the heavy lifting **Reward placeholders to customise:** - `X%` → venue's configured visitor spend percentage (e.g., 5%) - `$X` → venue's configured visit bounty (e.g., $2 per check-in) - `Y%` → venue's configured promoter spend percentage # Comprehensive Documentation ::doc-figure --- height: 450 width: 800 alt: A purple robot beside The Infrastructure for Real-World Web3. caption: Venues fund configured rewards for eligible visits and purchases. placement: lead source-url: https://t.me/belongnet/233 src: https://docs.belong.net/media/social/real-world-web3-infrastructure.webp --- :: ## Executive Summary Belong CheckIn creates the first on-chain affiliate network for physical venues, transforming the $580-750B venue marketing opportunity. The platform's core innovation: venues pay only for verified customers who actually visit and make purchases, creating perfect alignment between marketing spend and results. The model connects three participants: venues fund a campaign, customers complete eligible visits or purchases, and promoters bring attributable referrals. Read the mechanics below as the overall system; use the linked fee, network, and setup guides for the operational details of a particular campaign. Building on earlier Belong products, which have powered 15,000+ events for 1,500+ organizations, CheckIn offers a comprehensive Web2.5 solution that requires no crypto wallet, enables instant rewards, and provides transparent ROI tracking. The platform combines gasless transactions, AI-powered features, voice agent integration, and a sustainable token economy designed to minimize sell pressure and maximize platform growth. ## Platform Innovation Overview ### The Core Value Proposition: Venues Pay Only for Verified Customers This is the fundamental innovation that transforms venue marketing. Unlike traditional advertising where venues pay upfront with uncertain results, CheckIn ensures venues only pay when a promoter successfully brings a customer who actually visits and makes a purchase. This creates perfect alignment between venue success and marketing spend. **Venue Control**: Each venue sets their own two-part reward structure based on their unique economics: - **Visit Bounty**: Fixed reward for bringing a customer (guarantees minimum earnings) - High-traffic venues: Lower bounties ($2-5) to manage costs - Exclusive venues: Higher bounties ($10-20) to drive traffic - **Spend Percentage**: Variable reward based on customer spending - Premium venues with high margins: 15-25% of bill - Volume-based businesses: 5-10% of bill - Venues can adjust both components for special promotions or slow periods - Complete flexibility to optimize for profitability and customer acquisition goals Additional platform strengths include: - Proven market traction with existing user base and venue relationships - Technical excellence across multi-chain deployment and AI integration - Economic sustainability through intelligent token design - Mainstream accessibility via Web2.5 approach requiring no crypto knowledge - Global scalability with 15+ language support and localized strategies - Real-world activation through street teams and physical presence Each component reinforces the others, creating a flywheel effect that drives adoption and value creation for all participants. ## Market Opportunity The global hospitality and entertainment marketing spend represents a massive addressable market across segments. Based on recent projections, total marketing spend is estimated at $580-750B annually, reflecting growth in industry revenues and sustained marketing budgets averaging 7-10% of revenue across sectors. Key breakdowns include: | Segment | Spend | Insight | | ------------------- | --------- | ------------------------- | | Restaurants | $150-200B | 3-10% of $1.5T+ sales | | Hotels | $80-100B | 5-8% of total revenue | | Events/Festivals | $150-200B | 14% of marketing budgets | | Bars/Nightclubs | $2-3B | 1-2% of \~$100B market | | Other Entertainment | $100-150B | OTAs, venues, attractions | This updated TAM accounts for 2025 projections, with global hospitality revenues exceeding $5T and entertainment & media (E\&M) nearing $3.1T, driven by digital advertising growth to \~$820B. ## 1. Platform Mechanics 🚀 Belong.net's CheckIn takes a **Web2.5 approach**: no crypto wallet required, with gasless transactions enabled via signature-based actions. For LONG token supply, utility, and allocation details, see the [official LONG token page](https://belong.net/token). ### Economic Sustainability Deposit fees are waived for the first two venue deposits; the $5 convenience fee still applies. Later deposit fees are 5–10% by staking tier. USDC withdrawals carry 10%; LONG withdrawals carry 1–5% by staking tier. Deposit and withdrawal percentages apply at separate stages and are not one universal commission rate. - **Dual Payouts**: Promoters can choose USDC or LONG, with swaps handled programmatically to support token stability. LONG sourcing for payouts occurs from liquidity that is pre-provisioned via usage-based fee conversions; it is not a discretionary buyback or profit distribution. - **Fees**: $5 convenience fee (converted by contract), a deposit fee of 5–10% and a withdrawal fee of 1–10%, set by staking tier and payout currency (see [Fees & Staking](https://docs.belong.net/belong-checkin/fees-and-staking)), fund operations and programmatic token sinks that are **activity-based** rather than profit-based. - **Referrals**: Earn $250 for the first $5,000 in venue spend or promoter-generated revenue, with ongoing incentives to encourage community growth. Two key platform innovations create economic sustainability. **Core Innovation**: Since venues only pay for verified customers who actually visit and make purchases, they can afford to set generous reward structures that match their margins. A steakhouse might offer $15 visit bounty + 20% of bill, while a coffee shop might offer $2 + 8% - both achieve positive ROI because they only pay for real customers. The two-part structure (visit bounty + spend percentage) ensures promoters are rewarded fairly whether bringing high-spenders or frequent visitors. By pegging rewards to USDC, venues can always pay promoters the nominal USD amount regardless of LONG token price fluctuations, ensuring predictable costs. The Problem It Solves: Traditional reward tokens face immediate sell pressure as recipients dump for cash. Additionally, single-rate commission structures don't work well across diverse venue types - a coffee shop can't afford the same percentage as a steakhouse. The Solution: Our platform implements two key innovations: 1. **Dual-option payout system** creates a self-selection mechanism: - Option A: Payout in USDC with a 10% platform fee - Option B: Payout in LONG with a 1-5% platform fee (based on staking tier) 2. **Two-part reward structure** accommodates all venue types: - Visit Bounty: Fixed amount ensures minimum earnings - Spend Percentage: Variable reward scales with customer value ### Regular and NFT event tickets Belong CheckIn supports regular (non-NFT) tickets with Stripe Connect card payments, alongside NFT tickets bought through the configured NFT checkout partner. NFT checkout can also accept cards where enabled. Payment method and ticket format are separate choices: a card payment does not always mint an NFT. Direct venue QR payments and bracelet top-ups retain their own availability and settlement routes; see [Payments](https://docs.belong.net/belong-checkin/payments-and-onramp). ## 2. Core Mechanics: Deposits, Payments, and Payouts 💳 - **Venue Deposits**: Escrowed in USDC/LONG; tracked in CreditTokens. Fees applied on deposit. - **Customer Payments**: To venues, with optional promoter attribution. Dual bounty types (visit and spend) validated against venue preferences. - **Promoter Payouts**: Distributed from escrow; burns credits. Emergency options available for risk management. - **Pricing**: LONG valued via reliable feeds; conversions for payouts. **Detailed Fee Structure**: **Step 1 - Venue Funding**: Venues pre-fund their accounts - Pay 10% deposit fee + $5 convenience fee - Example: $555 to deposit $500 ($50 fee + $5 protocol fee conversion) - **First 2 deposits**: deposit fee waived, pay only $505 - Can reduce deposit fee to 5% with maximum staking - Example: $530 to deposit $500 ($25 fee + $5 protocol fee conversion) **Step 2 - Promoter Payouts**: When paying promoters from balance - Option A: Payout in USDC with 10% platform fee - Option B: Payout in LONG with 1-5% platform fee based on staking **Why This Design Works** **Example 1: Premium Restaurant** (Customer spends $200, venue offers 25% referral rate = $50 reward) - Venue has high margins, can afford generous rewards - Promoter receives: $45 (USDC) or $47.50-49.50 (LONG) - Platform keeps: $5 (USDC) or $0.50-2.50 (LONG) **Example 2: Coffee Shop** (Customer spends $20, venue offers 15% referral rate = $3 reward) - Venue has lower margins, sets appropriate reward - Promoter receives: $2.70 (USDC) or $2.85-2.97 (LONG) - Platform keeps: $0.30 (USDC) or $0.03-0.15 (LONG) **Venue Side**: - Previously deposited funds: e.g., paid $555 to deposit $500 ($50 deposit fee + $5 protocol fee conversion) - Now pays rewards from balance based on their chosen referral rate - **First 2 deposits** have no 10% fee, so venue only pays $505 to deposit $500 **Promoter Side - Path A (USDC Payout)**: - Promoter receives payout in USDC with 10% platform fee - Result: Immediate cash **Promoter Side - Path B (LONG Payout)**: - Promoter receives payout in LONG with 1-5% platform fee (based on staking tier) - LONG for payouts is sourced from **pre-provisioned liquidity obtained via fee conversions**; this is a programmatic settlement flow, not a discretionary market buyback. **Rational Choice**: The deposit and withdrawal fee model described in [Fees & Staking](https://docs.belong.net/belong-checkin/fees-and-staking) supports platform sustainability while giving venues flexibility to set both visit bounties and spend percentages that work for their business. The two-part structure guarantees promoters earn meaningful rewards even on small transactions. USDC payers receive immediate liquidity; LONG payers receive a higher net value after a reduced fee. ## 3. Staking System 🔒 Staking LONG tokens provides tiered benefits, including fee discounts and feature unlocks. It includes time-locks to encourage long-term participation. Staking **does not distribute revenue or dividends**; rewards are limited to fee discounts, access rights, and non-financial benefits designed to improve product utility. **Promoter Staking Tiers** | LONG Staked | Tier | USDC Fee | LONG Fee | | ----------- | -------- | -------- | -------- | | 0 | None | 10% | 5% | | 50,000 | Bronze | 10% | 4% | | 250,000 | Silver | 10% | 3% | | 500,000 | Gold | 10% | 2% | | 1,000,000 | Platinum | 10% | 1% | USDC payouts always have a 10% platform fee, while LONG payouts have a 1-5% fee based on staking tier. **Venue Staking Benefits** Venues can stake LONG to reduce their deposit fees: - **No stake**: 10% deposit fee (waived for first 2 deposits) + $5 convenience fee - **Bronze tier**: 9% deposit fee + $5 convenience fee - **Silver tier**: 8% deposit fee + $5 convenience fee - **Gold tier**: 7% deposit fee + $5 convenience fee - **Platinum tier**: 5% deposit fee + $5 convenience fee Example: To deposit $500 with Platinum staking = $530 total ($25 deposit fee + $5 convenience fee) Note: The $5 convenience fee is always applied and is **converted by contract as part of protocol operations**. ::doc-figure --- height: 450 width: 800 alt: Purple tokens and gift boxes beside Unlock Bigger Rewards with LONG. caption: LONG staking tiers affect the fees and payout shares described below. placement: inline source-url: https://t.me/belongnet/201 src: https://docs.belong.net/media/social/long-staking-rewards.webp --- :: ## 4. Security and Operations 🛡️ - **Signature Gating**: Key actions verified for security. - **Roles and Controls**: Granular permissions for administration. - **Emergency Features**: Tools to pause or adjust in exceptional cases. - **Non-Transferability**: Ensures credits remain tied to their purpose. **Platform Risk Management** **1. Liquidity Management** - Maintain USDC reserves for instant payouts - Dynamic fee adjustment based on platform needs - USDC backing eliminates token price volatility risk for venue liabilities **2. Fraud Prevention** - Multi-level verification for high-value accounts - Machine learning fraud detection - Venue deposit insurance pool **3. Technical Security** - Regular audits and bug bounties: [Hacken audits](https://hacken.io/audits/belong-net/) and the [Immunefi audit competition](https://immunefi.com/audit-competition/audit-comp-belong/information/), with [published findings](https://reports.immunefi.com/belong). - Timelocks on large transactions - Multi-sig treasury management Belong continually implements additional security measures across its smart contracts, applications, infrastructure, and operational systems. External audits and ongoing security work form part of this broader security programme. ## 5. Technical Excellence ⚙️ Belong CheckIn leverages cutting-edge technology to deliver a seamless experience: - Starting with BNB chain deployment, expanding to multi-chain across 7+ blockchains for global accessibility and low fees. - AI-powered fraud detection and recommendation engines. - Voice agent integration for hands-free check-ins and promotions. - Gasless transactions via relayers and account abstraction. **Additional Technical Infrastructure**: Deploying on BNB for optimal scalability and low costs. Token gating and NFT collections are supported on several networks, listed with their uses on the [Networks](https://docs.belong.net/belong-checkin/developer/networks) page; check-ins and LONG rewards run on BNB Chain. AI Integration: MCP (Model Context Protocol) for AI agents, voice AI agent support. Developer Ecosystem: Comprehensive API/SDK with 15+ language support. ::doc-figure --- height: 450 width: 800 alt: Connected violet components beside Advanced Systems. Seamless Experience. caption: The architecture combines chain-specific contracts with the application and integration layers. placement: inline source-url: https://t.me/belongnet/344 src: https://docs.belong.net/media/social/platform-infrastructure.webp --- :: ## 6. Go-to-Market Strategy 📈 Our phased rollout focuses on proven tactics: - **Street Teams**: 25% of marketing budget allocated to physical activation in key cities. - **Community Leverage**: Integrate with existing Belong communities. - **Venue Onboarding**: Instant setup with no technical requirements. - **Promoter Network**: Recruit through social media and incentives. **Phased Market Entry** **Phase 1: Leverage Existing Ecosystem** (Months 1-2) - Convert existing Belong venues - Activate current platform users as initial promoters - Focus markets: Bangkok, Bali, Dubai (proven traction) **Phase 2: Strategic Expansion** (Months 3-6) - **College Towns**: Austin, Boston, Madison, Ann Arbor, Berkeley - Student-friendly venues set higher visit bounties to drive traffic - **Tech Hubs**: San Francisco, New York, Seattle, Toronto, London - Premium venues leverage high spend percentages for affluent customers - **Nightlife Centers**: Miami, Las Vegas, Ibiza, Bangkok, Tokyo - Clubs use dynamic bounties: higher early evening, lower at peak hours ## 7. Traction and Metrics 📊 - 15,000+ events powered for 1,500+ organizations on earlier Belong products - Belong CheckIn rewards launched in September 2026 ## 8. Ecosystem Benefits 🌐 Venues gain precise control over their reward structure, promoters earn instant rewards with guaranteed minimums through visit bounties, and customers discover great experiences while earning value. **LONG as Payment Currency** **Reducing Sell Pressure Through Utility** A critical innovation is enabling LONG as a payment method at network venues, creating real utility beyond rewards. When promoters choose LONG payouts, the settlement engine sources LONG from liquidity that has been **pre-provisioned via fee conversions**. This is a programmatic process designed to fulfill payouts without implying discretionary market activity. **Venue Benefits for Accepting LONG**: - **Instant Settlement**: No 2-3 day bank delays - **Lower Deposit Fees**: Stake LONG to reduce deposit fees from 10% to 5% - **Lower Processing Fees**: 2.5% vs 4-5% for credit cards - **Flexibility**: Venues can hold, stake, or convert LONG through CEX/DEX at their convenience - **Network Benefits**: Join the LONG economy ecosystem **Customer Incentives**: - **3% Discount**: Immediate savings when paying with LONG - **Extra Rewards**: Enhanced promoter rewards for LONG payments - **Seamless Experience**: In-app wallet integration **Key Innovation**: When customers pay with LONG at venues, it creates a circular economy where LONG circulates within the network. Venues receiving LONG can: 1. Hold LONG for feature access or fee reductions 2. Use LONG to pay other network participants 3. Convert to USDC/fiat through CEX/DEX at their convenience (automatic conversion feature coming) This multi-utility approach transforms LONG from just a reward token into a functional payment currency within the Belong ecosystem. **Detailed Flow Mechanics** ### Flow 1: Venue Onboarding & Deposits **1. Venue Registration** - Create account on Belong.net - Simple business verification - Receive unique venue ID - Set custom reward structure based on business economics: - Visit Bounty: Fixed amount for customer check-in (e.g., $5-20) - Spend Percentage: Additional percentage of customer bill (e.g., 5-25%) - Can offer time-based bonuses (happy hour, slow periods) - Adjust rates anytime through dashboard - Choose payment acceptance options (USDC/LONG/Both) **2. USDC Deposit Process** - Venue funds the campaign balance through supported payment methods - Example: To deposit $500, venue pays $555 total - $500 deposit amount - $50 deposit fee (10%) - $5 convenience fee → converted by contract for protocol operations - **First 2 deposits**: fee waived, pay only $505 ($500 + $5 convenience fee) - Operational reserves are maintained to fulfill payouts - Mint VenueTokens representing available balance ### Flow 2: Customer → Promoter → Payment **1. Customer Interaction** - Visit venue - Scan QR or tap NFC at venue (attributes visit to promoter and verifies the visit on the backend) - Receive instant venue benefit (incentivizes scanning) - Make purchase (payment method is flexible: cash, card, Apple Pay, Google Pay, crypto, etc.; does not affect attribution) - Backend tracks spend through venue confirmation of bill amount or integration with POS systems (if available) **2. Payment Calculation** - Each venue sets their own two-part reward structure: - Visit Bounty: Fixed amount per verified visit (e.g., $5-20) - Spend Bonus: Additional percentage of bill (e.g., 5-25%) - Examples by venue type: - Fine dining: $10 visit + 20% of bill - Fast casual: $5 visit + 10% of bill - Coffee shop: $2 visit + 8% of bill - Nightclub: $15 visit + 15% of bill - Total referral reward = Visit Bounty + (Spend % × Bill Amount) - Venue pays reward from pre-funded balance - Promoter receives payout after platform fee (10% for USDC or 1-5% for LONG) **3. Payment Distribution** (based on venue's two-part reward structure) - Example: $10 visit bounty + 10% of $100 bill = $20 total reward - USDC choice: Promoter gets $18, Platform keeps $2 - LONG choice: Promoter gets $19-19.80, Platform keeps $0.20-1 ### Flow 3: LONG Payment at Venues **1. Customer LONG Payment** - Select LONG payment in app - Confirm amount - 3% discount - LONG transferred to venue (with auto-stake or auto-convert options) - Transaction recorded for analytics **2. Venue Settlement Options** - Hold LONG for feature access - Convert Gradually - Use for Operations within network - Exchange for USDC/Fiat through CEX/DEX **Complete Fee Structure** ### Venue Fees | Fee Type | Amount | Purpose | Example | | ----------------------- | --------------------------------- | --------------------------------------------- | --------------------------------- | | Convenience Fee | $5 per deposit | Converted by contract for protocol operations | Always applied | | Deposit Fee | 10% (waived for first 2 deposits) | Platform operations | $500 deposit costs $555 total | | Reduced Deposit Fee | 5-9% (based on venue staking) | Incentive for venues to stake | With max staking: $500 costs $530 | | LONG Payment Processing | 2.5% | Lower than cards | On customer payments | **Protocol Fee Handling (Revised)** - Fees fund operations and may be **programmatically converted** into LONG for ecosystem needs (incentive pools, liquidity provisioning, usage-based token sinks). - **No discretionary market buybacks** and **no revenue distribution to token holders**. Any token removals are **usage-linked** and executed via smart contracts. ### Growth Mechanics #### Network Effects - More Venues → More Promoters → More Customers - More LONG Payments → Greater utility → Lower sell pressure via real usage - More Referrals → Exponential Growth → Stronger Network #### Viral Loop 1. Promoter earns LONG 2. Stakes for fee benefits 3. Refers other promoters 4. Brings more venues 5. Creates more value ## 9. Long-Term Vision The following are proposed directions, not shipped capabilities or dated delivery commitments. ### Foundation priorities - Establish market presence in the initial markets - Prove unit economics: venues save on customer acquisition costs - Build network effects across initial markets ### Possible expansion areas - International markets across all continents - Additional verticals: hotels, experiences, gyms, fitness classes - DePIN rentals implementation - Web3 Hospitality Syndicate launch ### Possible platform evolution - Open API ecosystem with marketplace - Third-party app integrations - Become global standard for venue affiliate marketing **Key Platform Differentiators**: - Venues have complete control over their two-part reward structure - Visit bounties ensure promoters earn even on small purchases - Spend percentages incentivize bringing high-value customers - High-margin venues can offer generous bounties and percentages - Budget-conscious venues can optimize both components for profitability - Dynamic adjustments possible for happy hours, slow days, or special events - All venues benefit from paying only for verified customers who actually visit The two-part payment structure (visit bounty + spend percentage) creates a win-win: promoters are guaranteed minimum earnings while being incentivized to bring valuable customers, and venues can fine-tune their customer acquisition costs to match their business model. By focusing on the entire ecosystem rather than any single feature, CheckIn creates a sustainable competitive advantage that's difficult to replicate. The platform's true innovation lies in how all components work together - from street team activation to AI integration, from multi-language support to economic incentives - creating a unified solution that delivers real value to venues, promoters, and customers alike. The core principle remains: venues pay only for verified customers. Everything else in the platform is designed to make this model scalable, sustainable, and beneficial for all participants. **Key Success Factors** The Belong CheckIn platform creates sustainable value through comprehensive innovation: 1. **Proven Foundation**: Earlier Belong products have powered 15,000+ events for 1,500+ organizations 2. **Frictionless Adoption**: No wallet needed, gasless transactions, instant onboarding 3. **Economic Sustainability**: - Self-selection mechanism reduces immediate sell pressure - Two-part rewards (bounty + percentage) work for all venue types - Venues control both components to match their margins - Promoters guaranteed fair compensation regardless of purchase size 4. **Operations-Driven Growth**: Commission model funds platform operations; fee conversions are programmatic and usage-linked 5. **Multi-Utility Token**: LONG serves as rewards, payments, and staking (for access/discounts) 6. **Network Effects**: Venue-promoter-customer flywheel with referral incentives 7. **Technical Excellence**: Blockchain-native, AI-enabled, voice-supported platform 8. **Global Scalability**: 15+ language support with localized go-to-market strategies 9. **Developer Ecosystem**: API v3 and MCP support 10. **Risk Management**: Comprehensive fraud prevention and security measures **Typical Venue Reward Strategies by Type**: - **Coffee Shops**: High visit bounty ($2-3) + low percentage (5-8%) = steady traffic - **Fast Casual**: Moderate bounty ($5) + moderate percentage (10%) = balanced approach - **Fine Dining**: High bounty ($10-15) + high percentage (15-20%) = premium acquisition - **Bars/Clubs**: Variable bounty by time + solid percentage (10-15%) = dynamic optimization The platform transforms the $580-750B venue marketing opportunity by creating a Web3-powered ecosystem that benefits all participants — venues get transparent ROI and lower CAC with complete control over their reward structure, promoters earn instant rewards with guaranteed minimums through visit bounties, and customers discover experiences while earning value. # Integration Overview ::doc-figure --- height: 562 width: 800 alt: An event organizer with the words Create the Hub, Place the Event. caption: Use the correct hub and the additive event-linking update so existing event connections are retained. placement: lead source-url: https://t.me/belongnet/446 src: https://docs.belong.net/media/social/create-hub-place-event.webp --- :: ## Overview Belong CheckIn is built on the **Belong API**. This page covers the essentials for integrating with it: authentication, identifying users, and querying hubs and events. For the full REST reference and OpenAPI docs, see [API Documentation](https://docs.belong.net/getting-started/api-docs). For a first integration, authenticate from your trusted backend, identify the Belong user, and make a read-only hubs or events request. Keep your application's identifiers separate from Belong identifiers. This establishes ownership and request handling before you introduce payments or on-chain operations. - **Base URL:** `https://api.belong.net/api/v3` - **Interactive docs:** [`https://api.belong.net/api/v3/docs`](https://api.belong.net/api/v3/docs) - **Backend MCP endpoint:** `https://api.belong.net/mcp` - **Public assistant MCP endpoint:** `https://join.belong.net/functions/v1/belong-agent-mcp/mcp` ## Authentication: `x-api-key` All requests authenticate with the **`x-api-key`** header. Do **not** use `Authorization: Bearer`. ```ts const response = await fetch('https://api.belong.net/api/v3/events', { method: 'GET', headers: { 'x-api-key': userApiKey, 'Content-Type': 'application/json', }, }) ``` The same API key works for all endpoints, including MCP operations, `/me`, and `/me/crypto-addresses`. See [Getting an API Key](https://docs.belong.net/getting-started/api-docs#getting-an-api-key) to create one. ## MCP endpoint choice CheckIn uses a two-tier MCP structure: | Surface | Use it for | Auth | | ----------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------- | | `https://join.belong.net/functions/v1/belong-agent-mcp/mcp` | External assistants and public AI connectors that need event, hub, venue, check-in, bracelet, reservation, and signing-link workflows | OAuth 2.1 with email-code sign-in and scoped permissions | | `https://api.belong.net/mcp` | Trusted backend integrations and first-party services that need raw Belong API, event, NFT, and transaction primitives | `x-api-key` | Do not expose the backend API-key MCP as a public assistant connector. Public assistants should use the OAuth MCP gateway, which audits tool calls and sends sensitive wallet or payment work to a Belong confirmation link. ## Identifying the user To find which user a request belongs to (for filtering hubs and events by ownership), call `/api/auth/get-session`: ```ts const res = await fetch('https://api.belong.net/api/auth/get-session', { headers: { 'x-api-key': userApiKey }, }) const { user } = await res.json() const belongUserId = user.id // Mongo-style ObjectID, e.g. "507f1f77bcf86cd799439011" ``` ::warning The Belong user ID is a Mongo-style ObjectID — not a UUID. If your app stores its own user IDs (for example a database UUID), keep them separate: never compare your internal IDs to Belong's `ownerId` / `membersIDs` . :: ### Profile endpoints | Endpoint | Returns | | --------------------------------- | ---------------------------------------------------------------------- | | `GET /api/v3/me` | The authenticated user's profile | | `GET /api/v3/me/crypto-addresses` | The user's linked crypto addresses (`address`, `chainId`, `connector`) | ## Hubs & events ### Filtering "My Hubs" Fetch hubs with the user's API key, then filter by the Belong user ID: ```ts const userHubs = allHubs.filter(hub => hub.ownerId === belongUserId || (Array.isArray(hub.membersIDs) && hub.membersIDs.includes(belongUserId)) ) ``` For a **Discover** view (public hubs the user hasn't joined), fetch a larger batch (50+) and filter out the user's own hubs — a small page may contain only the user's hubs and leave nothing to discover. ### Connecting events to a hub Use `connectEventIds` (additive, de-duplicates automatically) rather than replacing the whole `categorySubEventIDs` array: ```ts await fetch(`https://api.belong.net/api/v3/hubs/${hubId}`, { method: 'PUT', headers: { 'Content-Type': 'application/json', 'x-api-key': apiKey }, body: JSON.stringify({ connectEventIds: [eventId] }), }) ``` ### Query parameters | Parameter | Type | Notes | | --------- | --------------------------- | ------------------------------------------------- | | `take` | integer (1–100, default 20) | Items per page — **use `take`, not `limit`** | | `page` | integer | 1-based page index | | `cursor` | string | Cursor from a previous page | | `sort` | `createdAt` \| `updatedAt` | Default `createdAt` | | `order` | `asc` \| `desc` | Default `desc` | | `search` | string | Case-insensitive across name, slug, description | | `hubType` | `group` \| `nftCollection` | Filter by hub type | | `status` | `PUBLISHED` \| `INCOMPLETE` | Filter by status | ::warning **The `private` parameter pitfall.** It expects a boolean, but query strings are always strings — sending `private=false` causes a `400` . Omit the parameter entirely and user-specific access rules apply automatically. :: ## Ticketing and payment routes - **Regular (non-NFT) tickets:** Stripe Connect and hosted Stripe Checkout through the event ticket-order API. Confirmed payment is fulfilled into ticket registrations and entry QR codes; an NFT collection is not required. - **NFT tickets:** the configured NFT checkout partner handles supported wallet or card methods. The [hosted NFT Checkout](https://docs.belong.net/belong-checkin/developer/nft-checkout) has its own session and verification contract. - **Venue payments:** the existing venue payment-account and `payToVenue` flow is separate from Stripe ticket orders. Do not route venue requests to ticket-order endpoints or infer availability from the ticket capability. - **Bracelet card top-ups:** a separate Stripe Connect capability and order type; only offer it when available. Check `GET /api/v3/payments/capabilities` before exposing Stripe ticket or bracelet checkout. Ticket and bracelet availability are independent; organizer/event configuration still applies. See [Payments](https://docs.belong.net/belong-checkin/payments-and-onramp) for the product-level distinction. ## Common mistakes 1. Using `Authorization: Bearer` instead of `x-api-key` 2. Comparing your internal user IDs to Belong's Mongo-style IDs 3. Using `limit` instead of `take` for pagination 4. Sending `private=false` as a string (omit it instead) 5. Fetching too few hubs for a Discover view ## Related - [API Documentation](https://docs.belong.net/getting-started/api-docs) — full REST reference - [NFT Checkout](https://docs.belong.net/belong-checkin/developer/nft-checkout) — embed crypto payment and NFT issuance in an external store - [API Reference](https://docs.belong.net/belong-checkin/developer/api-reference) — CheckIn edge functions - [MCP Tools](https://docs.belong.net/belong-checkin/developer/mcp-tools) # API Reference ::doc-figure --- height: 450 width: 800 alt: Developer tools and digital assets beside Ship Faster with Belong. caption: Use authenticated API requests from a trusted backend and follow the documented inputs and responses. placement: lead source-url: https://t.me/belongnet/362 src: https://docs.belong.net/media/social/build-with-belong.webp --- :: ## Overview Belong CheckIn's app backend exposes serverless functions that handle AI chat, audio transcription, and MCP tool discovery. They complement the core [Belong REST API](https://docs.belong.net/getting-started/api-docs); this page documents the CheckIn-specific functions. Use this reference when extending the CheckIn app's assistant or voice experience. For example, an audio message is transcribed before its text can enter the chat workflow. These functions use an app-session bearer token; the core Belong REST API has its own API-key authentication described in the integration guide. All functions enable CORS and validate the caller's app session. ## Edge functions ### `chat-with-claude` Processes a user message through the AI assistant with MCP tool integration. **Endpoint:** `POST /functions/v1/chat-with-claude` ```ts interface ChatRequest { roomId: string message: string messageId: string model?: string useMCP?: boolean aiProvider?: string audioData?: boolean imageData?: boolean textContent?: string originalType?: string } interface ChatResponse { success: boolean message?: string tool_results?: ToolResult[] session_id?: string error?: string } ``` ```ts const response = await fetch('https:///functions/v1/chat-with-claude', { method: 'POST', headers: { 'Content-Type': 'application/json', Authorization: `Bearer ${sessionToken}`, }, body: JSON.stringify({ roomId: 'room-123', message: 'Create an NFT event for a music concert', messageId: 'msg-456', useMCP: true, }), }) ``` Responses stream via Server-Sent Events for real-time output. ### `transcribe-audio` Converts an audio message to text (used by [Voice Mode](https://docs.belong.net/belong-checkin/ai-and-voice)). **Endpoint:** `POST /functions/v1/transcribe-audio` ```ts interface TranscriptionRequest { messageId: string audioData: string // base64-encoded audio roomId: string } interface TranscriptionResponse { success: boolean transcription?: string message_id: string error?: string } ``` Supports common audio formats up to 25 MB and stores the transcription automatically. ### `discover-mcp-capabilities` Discovers and registers the available MCP tools. **Endpoint:** `POST /functions/v1/discover-mcp-capabilities` ```ts interface CapabilitiesResponse { success: boolean capabilities: MCPCapability[] total_discovered: number new_capabilities: number } ``` ### `rename-chat-for-event` Generates a meaningful chat-room name from event-creation context. **Endpoint:** `POST /functions/v1/rename-chat-for-event` ```ts interface RenameChatRequest { roomId: string eventTitle?: string context?: string } ``` ## Security - **Authentication** — each function validates the app session token from the `Authorization: Bearer ` header - **CORS** — preflight `OPTIONS` requests are handled and standard CORS headers returned - **Input validation** — requests are validated and length-limited (for example, chat messages are capped) before processing ## Error format ```ts interface ErrorResponse { error: true message: string code?: string details?: unknown timestamp: string request_id: string } ``` Functions use URL versioning (`/functions/v1/...`). Transient upstream errors are retried with exponential backoff. ## Related - [Integration Overview](https://docs.belong.net/belong-checkin/developer/integration-overview) — Belong API auth - [API Documentation](https://docs.belong.net/getting-started/api-docs) — core Belong REST API - [MCP Tools](https://docs.belong.net/belong-checkin/developer/mcp-tools) # MCP Tools ::doc-figure --- height: 450 width: 800 alt: A phone and robotic hand with the words Build Smarter Web3 Apps With MCP. caption: Connect an MCP client to structured Belong tools and use the authentication required by its endpoint. placement: lead source-url: https://t.me/belongnet/275 src: https://docs.belong.net/media/social/mcp-assistants.webp --- :: ## Overview Belong CheckIn's AI assistant acts through **MCP (Model Context Protocol)** tools to create NFT collections, manage events, and run venue operations. The public assistant connector and the backend MCP intentionally use different auth models. Choose the MCP surface before choosing a tool. Public assistants connect a user through OAuth, an authorization flow that grants scoped access; trusted backend tooling uses an API key. A tool that prepares a payment or transaction is one step in the workflow, with sensitive actions confirmed through the documented Belong flow. - **Public assistant MCP:** `https://join.belong.net/functions/v1/belong-agent-mcp/mcp` (OAuth 2.1 with email-code sign-in) - **Backend MCP:** `https://api.belong.net/mcp` (trusted integrations only, authenticate with `x-api-key`) - **Setup:** see [MCP Integration](https://docs.belong.net/getting-started/mcp) - **Backend tool reference:** the [MCP Cheat Sheet](https://docs.belong.net/mcp/overview) documents the API-key backend MCP tools The public assistant MCP is the safe external connector: it uses scoped OAuth tokens, audit logging, and Belong confirmation links for wallet or payment operations. The backend MCP exposes lower-level API and transaction primitives and should stay inside trusted server-side or first-party contexts. ::note **Blockchain priority:** EVM (BNB Smart Chain primary) → Sui. BNB Chain (chain ID `56` ) is the default network; the EVM order is BSC → Polygon → SKALE → Base → Ethereum. :: ## LONG token vs. token gating Two separate systems power the platform — don't conflate them: - **$LONG token (BEP-20 on BNB Chain)** powers CheckIn rewards: promoter rewards, venue marketing budgets, and user spend rewards. - **Token gating** uses **NFT collections** for event ticketing and access control — users must hold a specific NFT to gain entry. ## Tool categories | Category | Representative tools | Reference | | ------------------------- | -------------------------------------------------------------- | --------------------------------------------------------------------- | | **CheckIn** | Backend venue deposit and customer payment primitives | [CheckIn Tools](https://docs.belong.net/mcp/tools-check-in) | | **EVM NFT collections** | `deploy`, `complete`, `evm-mint`, `mint-complete` | [Minting Tools](https://docs.belong.net/mcp/tools-minting) | | **Sequential NFT (Sui)** | `publish-collection` → `create-collection` → `save-collection` | [Minting Tools](https://docs.belong.net/mcp/tools-minting) | | **Sponsored collections** | `create-sponsored-collection` (gasless) | [Sponsored Gas](https://docs.belong.net/belong-checkin/sponsored-gas) | | **Vesting** | `deploy-vesting-wallet` (LONG, cliff + linear) | [Vesting Tools](https://docs.belong.net/mcp/tools-vesting) | | **Events** | `create-event`, `update-event` | [Events Tools](https://docs.belong.net/mcp/tools-events) | | **Media** | `add-event-media`, `reorder-event-media` | — | | **StarkNet** | StarkNet-specific minting | [StarkNet Tools](https://docs.belong.net/mcp/tools-starknet) | ## The sequential NFT workflow Creating a collection runs a three-step workflow that the platform triggers automatically when `publish-collection` is called with collection data: ::mermaid ```text flowchart LR; A[publish-collection
prepare tx] --> B[create-collection
execute on chain] B --> C[save-collection
persist to backend] C --> D[Collection ready] ``` :: Each step streams real-time status (Step 1/3 … 3/3) over Server-Sent Events, with per-step error handling. ## Choosing EVM vs. Sui - **Use EVM (BSC)** for LONG token operations, token-gated events, and default NFT collections - **Use Sui** only when explicitly requested or when the user's blockchain preference is set to Sui ## Related - [MCP Cheat Sheet](https://docs.belong.net/mcp/overview) — backend API-key MCP tools with parameters - [MCP Integration](https://docs.belong.net/getting-started/mcp) — connect a client - [Event Creation](https://docs.belong.net/belong-checkin/event-creation) — the user-facing flow these tools drive # Networks ::doc-figure --- height: 450 width: 800 alt: The Belong and BNB Chain symbols beside Belong CheckIn is Live on BSC Mainnet. caption: BNB Chain, also called BSC, is the primary CheckIn network. Match chain ID 56 to the wallet request. placement: lead source-url: https://t.me/belongnet/327 src: https://docs.belong.net/media/social/checkin-bnb-mainnet.webp --- :: ## Overview Belong CheckIn works across multiple EVM networks through a unified wallet interface, with **BNB Chain as the primary network** for check-ins, LONG rewards, and default NFT collections. Sui is supported as a secondary chain, and NFT collection minting on Starknet is documented in the [Starknet guide](https://docs.belong.net/guides/crypto/starknet). A **chain ID** identifies the network a wallet request is targeting. For a payment, match the network, token balance, and gas handling together: a balance on one network does not by itself fund a transaction on another. Use BNB Chain for the default CheckIn payment and LONG reward flow. ## Supported networks | Network | Chain ID | Native token | Notes | | --------------- | ------------ | ------------ | ------------------------------------------------------------------------------------------------------ | | BNB Chain (BSC) | `56` | BNB | **Primary** — LONG rewards, CheckIn, default NFTs | | Polygon | `137` | POL | Low-cost EVM Layer 2 | | Base | `8453` | ETH | Coinbase-backed EVM Layer 2 | | Ethereum | `1` | ETH | Highest liquidity; DeFi and NFTs | | SKALE Nebula | `1482601649` | sFUEL | Zero gas fees; gaming and NFTs | | SKALE Europa | `2046399126` | sFUEL | Zero gas fees | | Sui | — | SUI | Secondary chain, via Enoki | | Starknet | `SN_MAIN` | STRK | NFT collection minting guide; see the [Starknet guide](https://docs.belong.net/guides/crypto/starknet) | ## Multi-chain wallets A user's account aggregates balances across networks: - Each network reports its **native balance** and **ERC-20 token balances** (such as USDC) - The wallet UI shows balances per network and lets users switch the active network - Switching a network clears the previous balances, fetches the new network's data, and refreshes transaction forms Balances are fetched in parallel and cached briefly to stay responsive and avoid rate limits. ## Network selection in practice - **CheckIn payments and rewards** default to **BNB Chain** — venues set USDC and/or LONG as accepted tokens - **Token-gated events** default to EVM (BSC) unless a Sui collection is explicitly chosen - **Block explorer links** and **gas handling** are resolved per network automatically ## Related - [Wallet & Sign-In](https://docs.belong.net/belong-checkin/wallet-and-auth) — the user-facing wallet - [Fees & Staking](https://docs.belong.net/belong-checkin/fees-and-staking) - [MCP Tools](https://docs.belong.net/belong-checkin/developer/mcp-tools) — deploying NFTs per network # Enterprise & Whitelabel Apps ::doc-figure --- height: 1013 width: 1440 alt: A branded purple and gold check-in kiosk with the words Check In Your Brand. caption: Provide a complete brand and launch brief so the arrival flow matches the rest of your app. placement: lead source-url: https://t.me/belongnet/478 src: https://docs.belong.net/media/social/check-in-your-brand.webp --- :: ## Overview Belong CheckIn supports branded deployments for organizations that need their own customer-facing experience. Belong can build and operate a branded Web, iOS, and Android app on behalf of enterprise customers. Use this page to understand who provides the launch materials and who operates the resulting app. Your organization supplies its identity and store details, while Belong handles the agreed app build and operations. Follow the launch-kit checklist to turn a branding request into a complete build brief. For enterprise app builds, email . ## Managed whitelabel For most organizations, the fastest path is a managed whitelabel app: your logo, colors, domain, app identity, and launch configuration, with payments, memberships, events, referrals, and analytics configured for your community. See the [Whitelabel Launch Kit](https://docs.belong.net/guides/whitelabel) for launch requirements such as app identity, branding assets, login providers, localization, analytics, and SEO. ## Enterprise app builds Belong can handle the app build and launch process for enterprise customers: | Area | Belong handles | | --------------------- | ----------------------------------------------------------------------------------------- | | Web app | Branded deployment, domain configuration, analytics, and production operations | | iOS app | Bundle ID setup, native configuration, App Store submission support, and release updates | | Android app | Package setup, native configuration, Play Console submission support, and release updates | | Product configuration | Payments, memberships, event flows, referrals, CheckIn modes, and notifications | | Operations | Monitoring, updates, and support for the deployed app | Enterprise customers provide brand assets, store listing details, legal/policy content, login provider requirements, and access to the relevant store accounts when needed. ## Related - [Whitelabel Launch Kit](https://docs.belong.net/guides/whitelabel) - [Integration Overview](https://docs.belong.net/belong-checkin/developer/integration-overview) - [Networks](https://docs.belong.net/belong-checkin/developer/networks) # POS & Check-In Events ::doc-figure --- height: 562 width: 800 alt: A phone at a venue counter beside Pay Your Tab With Your Phone. caption: The guest scans a payment-request QR; staff confirm the bill amount before the guest pays. placement: lead source-url: https://t.me/belongnet/415 src: https://docs.belong.net/media/social/pay-your-tab.webp --- :: ## Overview This page covers integrating a point-of-sale (POS) or back-office system with Belong CheckIn: collecting staff-confirmed payments via QR, and attributing each check-in to where it came from. Start with the staff-confirmed payment-request QR pattern below when connecting the counter workflow to CheckIn. A **POS** is the point-of-sale system that holds the bill. Check-in attribution records the request source; outbound check-in webhooks remain a roadmap item, as described at the end of this guide. ## Payment-request QR (POS pattern) The primary POS integration is the **payment-request QR**: the customer scans, staff enter the amount from your POS, and the customer pays from their wallet. This reuses the venue owner-quote payment flow — no separate access mode is needed. See the [Payments](https://docs.belong.net/belong-checkin/payments-and-onramp#payment-request-qr) guide for the operator and customer flows. A payment-request QR encodes a small payload (distinct from the standard check-in QR) and the app re-validates the venue's settings on every scan, so a stale QR can't be used to force a payment: ```ts type VenuePaymentRequestQRData = { type: 'venue_payment_request' hubId: string hubName: string venueWallet?: string locationLabel?: string source: 'venue_static_qr' | 'checkin_qr' | 'pos_receipt_qr' timestamp: number version: number } ``` ::mermaid ```text flowchart TD accTitle: Staff-confirmed venue payment accDescr: The guest scans a payment-request QR and confirms the request, staff send the bill, and the guest completes the supported payment. A[Guest scans payment-request QR] --> B[Guest confirms the request] B --> C[Staff send the bill amount] C --> D[Guest completes payment] D --> E[Record payment and request attribution] ``` :: The POS supplies the amount staff confirm. The QR source and optional label keep that payment associated with the right table, receipt, or register. This pattern does not require an outbound check-in webhook. ## Check-in attribution Each check-in records where the request originated, so you can reconcile against your POS: | Field | Values | Meaning | | ------------------------ | ------------------------------------------------- | ---------------------------------------------------------------------------------------------- | | `payment_request_source` | `checkin_qr`, `venue_static_qr`, `pos_receipt_qr` | Whether the request came from the standard check-in QR, a static venue QR, or a POS receipt QR | | `payment_request_label` | free text | Optional staff-facing label such as a table, bar, patio, or register | These are runtime attribution fields — they don't change a venue's check-in configuration, which stays in the venue's settings. ## Reading check-in activity - **Pending requests** — staff surfaces read pending owner-quote requests (with source and label) so they can send the amount - **History** — venue operators can review recent check-ins and reward activity from their venue's CheckIn area ::note For programmatic access to events and hubs, use the [Belong API](https://docs.belong.net/belong-checkin/developer/integration-overview) with your `x-api-key` . Outbound event webhooks (push notifications to your own endpoint on each check-in) are on the roadmap; today, integrate by reading check-in and venue data through the API. :: ## Related - [Payments](https://docs.belong.net/belong-checkin/payments-and-onramp) - [Venue Quick Start](https://docs.belong.net/belong-checkin/venue-quickstart) - [Integration Overview](https://docs.belong.net/belong-checkin/developer/integration-overview) # NFT Checkout ::doc-figure --- height: 450 width: 800 alt: A purple payment interface beside Branded Checkout Pages, Simplified. caption: Your server creates the NFT checkout session and verifies completion while the buyer uses the branded checkout. placement: lead source-url: https://t.me/belongnet/239 src: https://docs.belong.net/media/social/branded-checkout-pages.webp --- :: ## Overview Belong NFT Checkout lets a store accept an on-chain payment and automatically issue an NFT without moving its product catalog or order system into Belong. Think of the integration as an agreement between two systems: the store owns the order and Belong owns the hosted payment session. Keep the same order reference when retrying, and verify the signed completion webhook before marking the store order paid. A successful browser redirect alone is not that verification. The store remains responsible for products, inventory, orders, refunds, and physical fulfillment. Belong stores the checkout snapshot, payment status, NFT data, and verified on-chain result. The integration is not tied to Shopify. A Shopify app, custom storefront, or any other commerce backend can use the same API and SDK. The store's developer performs the integration; Belong does not need access to the store admin. ::note The first partner launch uses `crypto_wallet` only. Customers pay from their Belong wallet. The universal checkout also supports `thirdweb_card` for merchants and networks where Belong has enabled it. This particular hosted NFT flow uses thirdweb, not the regular Stripe Connect ticket-order API. Regular (non-NFT) event tickets and their Stripe Connect payments are described separately in [Payments](https://docs.belong.net/belong-checkin/payments-and-onramp) ; NFT checkout can accept cards without becoming a regular ticket checkout. :: ## What the store provides - A backend that validates the product, inventory, and price. - Its own pending order and a stable order reference. - An exact HTTPS storefront origin. - An HTTPS webhook endpoint. - A frontend container where the Belong checkout iframe can open. ## What Belong provides - NFT collection creation and deployment through Belong CheckIn. - A server API for creating idempotent checkout sessions. - A hosted payment page embedded through `@belongnet/sdk`. - Belong sign-in and the customer's Belong wallet. - Wallet top-up guidance when the customer needs funds for payment or network fees. - Thirdweb transaction execution. - Automatic NFT issuance after a verified payment. - Signed payment-completion webhooks. ## End-to-end flow ### One-time setup 1. The store owner creates and deploys an EVM NFT collection in Belong CheckIn. 2. The collection defines its chain, payment token, supply, metadata, and pricing strategy. 3. Use dynamic pricing if different store products have different NFT prices. A static-price collection accepts only its configured mint price. 4. Belong issues a server API key with `checkout:create` and, if webhook retries are needed, `checkout:retry` permission. 5. The store keeps the API key on its backend. It must never be added to storefront JavaScript. This is a store NFT collection, not an NFT membership. The pilot creates one NFT for one verified store order. ### Every order 1. The customer starts checkout in the store. 2. The store backend validates the product and price, then creates its own pending order. 3. The backend creates a Belong checkout session using the order reference and NFT snapshot. 4. Belong verifies that the API-key owner owns the deployed collection and returns `checkoutId`, `clientSecret`, the hosted checkout URL, and an optional webhook signing secret. 5. The storefront passes only `checkoutId` and `clientSecret` to the SDK. 6. The SDK embeds the Belong checkout page. Belong verifies the actual store origin before showing payment actions. 7. The customer signs in and continues with their Belong wallet. 8. If the wallet does not have enough USDC, the customer funds it before continuing. 9. On the BNB Chain wallet flow, the customer may also need a small amount of BNB for the USDC approval network fee. BNB top-up is available through Belong, after which the customer returns to the same checkout. 10. The customer approves USDC spending and continues payment through Thirdweb. The main payment and NFT issuance continue automatically after approval. 11. Belong verifies the on-chain result, records the NFT, and completes the checkout. 12. The iframe updates the store UI. The store marks its order as paid only after verifying the signed `checkout.completed` webhook. Unlike the previous Crossmint flow, wallet checkout is not completed in a single action when the customer still needs BNB for approval. ## Create a checkout session Create sessions from the store backend only. ```http POST https://api.belong.net/api/v3/checkout/sessions Content-Type: application/json x-api-key: YOUR_SERVER_API_KEY ``` ```json { "collectionId": "COLLECTION_ID", "externalOrderId": "store:order:89351", "items": [ { "name": "Partner Product NFT", "description": "Digital proof of purchase", "mintPrice": 49, "image": "https://shop.example/assets/product-nft.png", "externalProductRef": "store:variant:4471", "quantity": 1 } ], "paymentMethods": ["crypto_wallet"], "allowedOrigin": "https://shop.example", "webhookUrl": "https://shop.example/api/belong/webhook", "expiresInSeconds": 1800 } ``` Current checkout sessions accept exactly one item with quantity `1`. `mintPrice` uses the payment token configured on the collection. `externalOrderId` is idempotent for the API-key owner. Repeating the same request returns the same checkout. Reusing the order reference with different checkout data returns `409`. For the first partner, send only `crypto_wallet`. Add `thirdweb_card` only after Belong enables card payments for the collection and confirms support for the selected network. ### Response ```json { "checkoutId": "CHECKOUT_ID", "clientSecret": "...", "checkoutUrl": "https://checkin.belong.net/checkout/CHECKOUT_ID#clientSecret=...", "webhookSecret": "...", "status": "PENDING", "expiresAt": "2026-09-08T15:00:00.000Z" } ``` Send `checkoutId` and `clientSecret` only to the storefront that requested the order. Keep `webhookSecret` on the store backend. The hosted URL stores the client secret in the URL fragment. Browsers do not send fragments in HTTP requests or referrer headers. The hosted page uses the `X-Checkout-Client-Secret` header when it reads the public session. ## Embed the checkout Install and import `@belongnet/sdk`, then mount the checkout in a container: ```html
``` ```ts import { BELONG_CHECKOUT_ORIGIN, createPaymentFrame, isPaymentEvent, PaymentEvent, PaymentTarget, } from '@belongnet/sdk' const { checkoutId, clientSecret } = checkout const { frame } = createPaymentFrame({ el: document.getElementById('belong-checkout')!, params: { target: PaymentTarget.Checkout, checkoutId, clientSecret, }, }) function onMessage(event: MessageEvent) { if (event.source !== frame.contentWindow) return if (!isPaymentEvent(event, BELONG_CHECKOUT_ORIGIN)) return if (event.data.type === PaymentEvent.PaymentSuccess) { showPaymentPendingServerConfirmation() } if (event.data.type === PaymentEvent.PaymentError) { showPaymentError(event.data.payload.error) } } window.addEventListener('message', onMessage) ``` The SDK supplies `window.location.origin` to the hosted frame. It sends only the origin as the iframe referrer so Belong can verify the real embedding site without receiving the store page path. Browser events are for UI updates only: | Event | Meaning | | ------------------ | ---------------------------------------------------------------------------------- | | `loaded` | The hosted checkout is ready. | | `payment-success` | Belong accepted the payment result and is refreshing authoritative checkout state. | | `payment-error` | Payment could not continue. | | `payment-canceled` | The customer closed the checkout. | Always verify both the message origin and `event.source === frame.contentWindow`. ## Verify the completion webhook Belong sends `checkout.completed` after it has verified the payment and NFT mint. The request includes: ```http x-belong-event-id: checkout-completed-CHECKOUT_ID x-belong-signature: v1=HMAC_SHA256_SIGNATURE ``` Compute HMAC-SHA256 over the exact raw request body with the `webhookSecret`. Compare signatures in constant time, reject invalid requests, and process `x-belong-event-id` idempotently. The payload includes the external order ID, transaction hash, paid amount, payment token, chain, NFT collection address, minted token IDs, and owner wallet. Return a `2xx` response only after your system has durably recorded the event. If delivery failed, an authorized backend can request another attempt: ```http POST https://api.belong.net/api/v3/checkout/sessions/CHECKOUT_ID/webhook/retry x-api-key: YOUR_SERVER_API_KEY ``` ## Checkout states | State | Meaning | | ----------- | -------------------------------------------------------------- | | `PENDING` | The customer may continue payment. | | `COMPLETED` | The on-chain payment and NFT mint were verified. | | `EXPIRED` | A new payment cannot start because the session lifetime ended. | | `FAILED` | A terminal server-side failure stopped the checkout. | A transaction prepared before expiry may still complete after expiry when its successful receipt is verified. A transaction hash can complete only one checkout. ## Security checklist - Create sessions only after validating the order and price on the store backend. - Never expose the store API key or webhook secret to the browser. - Register the exact HTTPS store origin. Wildcards are not supported. - Treat the server webhook, not the browser event, as proof of payment. - Store processed webhook event IDs and handle duplicate delivery safely. - Reuse the same `externalOrderId` only when retrying the exact same order snapshot. - Do not enable `thirdweb_card` until Belong confirms it for the merchant and network. ## Related - [SDK](https://docs.belong.net/getting-started/sdk) - [API Documentation](https://docs.belong.net/getting-started/api-docs) - [EVM NFT Minting](https://docs.belong.net/guides/crypto/minting) - [Wallet & Sign-In](https://docs.belong.net/belong-checkin/wallet-and-auth) # Check-In Modes ::doc-figure --- height: 562 width: 800 alt: Three entry arches with the words Fit the Door to the Crowd. caption: Choose the access rule around what staff need to verify when guests arrive. placement: lead source-url: https://t.me/belongnet/453 src: https://docs.belong.net/media/social/choose-check-in-mode.webp --- :: ## Overview Belong CheckIn uses a single QR-scanning flow that adapts to different kinds of businesses — cafés, events, communities, and co-working spaces. The core idea is a clean split between **getting access** (buying a ticket or membership ahead of time) and **verifying on site** (scanning a QR at the door). Choose the mode around what staff need to verify at arrival. A free meetup records attendance, a café can collect a venue payment, and an NFT membership checks an existing access credential. Set up and brief the door team on the selected flow before guests arrive. ```text Buy / get access (ahead of time): Regular ticket: Event page → Stripe Connect card checkout → Ticket registration + entry QR NFT ticket: Event page / Chat / Shop → NFT checkout partner (card or crypto) → Ticket NFT Check in (on site): Regular ticket: Staff scan entry QR → Verify ticket registration → Admit NFT access: Scan venue QR → Check configured NFT → Confirm → Done ``` Regular (non-NFT) tickets and NFT tickets are both supported. **Stripe Connect** processes regular ticket payments; **NFT checkout partners** can accept cards or crypto for NFT purchases. These are different checkout routes, even when the customer pays by card. See [Payments](https://docs.belong.net/belong-checkin/payments-and-onramp). ## Access modes The following settings are the venue/hub access modes, with **one primary access mode** optionally combined with membership. Regular event ticket registrations are a separate event-ticket admission flow; they do not require an NFT ownership check. | Mode | Amount entry | NFT check | Best for | | ------------------ | ------------ | --------- | ---------------------------------------------------- | | **Free** | No | No | Meetups, free community visits, simple attendance | | **Venue payment** | Yes / No | No | Cafés, bars, restaurants, paid local experiences | | **NFT ticket** | No | Yes | Conferences, concerts, ticketed and gated entry | | **NFT membership** | No | Yes | Clubs, communities, recurring and member-only spaces | Venue payment supports three amount flows: - **Customer-entered amount** — the visitor types in their check total - **Owner-set quote** — staff send an amount after the visitor requests payment (see [Payments](https://docs.belong.net/belong-checkin/payments-and-onramp)) - **Fixed amount** — a set price configured by the venue (e.g. a day pass) ## The check-in flow ::mermaid ```text flowchart TD; A[Scan QR code] --> B[Read venue settings] B --> C{Multiple modes?} C -->|Yes| D[Visitor chooses how to check in] C -->|No| E[Use the single configured mode] D --> F{Which mode?} E --> F F -->|Free| G[Confirm attendance] F -->|Venue payment| H[Enter or receive amount, then pay] F -->|NFT ticket / membership| I[Check wallet for NFT] I -->|Found| G I -->|Not found| J[Show buy option] G --> K[Check-in complete] H --> K ``` :: ## Example scenarios | Aspect | Café / Bar | Event | Community | Co-working | | ------------ | ----------------------- | -------------------- | ------------------------------- | -------------------- | | Entity | Hub | Event | Hub | Hub | | Modes | Payment + membership | Ticket only | Free + membership | Payment + membership | | Amount entry | Yes (variable) | No | No | No (fixed) | | NFT check | Optional | Only for NFT tickets | Optional | Optional | | Daily limit | — | 1 per ticket | 1 | 1 | | Main outcome | Configured spend reward | Access | Attendance or configured reward | Access | **Café / Bar** — A visitor enters their order total, pays in USDC or LONG, and can receive the venue's configured spend reward. A membership NFT can gate member perks. **Event** — Choose regular tickets paid through Stripe Connect or NFT tickets purchased through the configured NFT checkout partner. Regular tickets use their issued registration and entry QR; NFT access checks the configured ticket NFT. Paying by card is possible on either route where enabled. **Community** — A free check-in records attendance and can apply the configured flat reward. A membership check-in verifies the configured NFT collection for member-only access. **Co-working** — A fixed-price day pass via venue payment, or a monthly membership NFT that's verified on entry. ## Edge cases the flow handles - **Multiple valid NFTs in the wallet** — the visitor picks which one to use; already-used-today tickets are marked - **NFT already used today** — a warning appears with other available modes and when it can be used again - **Amount below the minimum** — the payment is blocked with a clear minimum - **Connection lost mid-payment** — the pending state is saved so the visitor can resume, retry, or cancel ## Related - [App Features](https://docs.belong.net/belong-checkin/app-features) — product overview - [CheckIn Crypto Guide](https://docs.belong.net/guides/crypto/checkin) — the on-chain venue and payment flow - [Sponsored Gas](https://docs.belong.net/belong-checkin/sponsored-gas) — gasless check-in for eligible users # Venue Quick Start ::doc-figure --- height: 800 width: 640 alt: A host-desk scanner with the words Host Desk Ready First. caption: Prepare the scan location and brief staff on the configured flow before opening. placement: lead source-url: https://t.me/belongnet/418 src: https://docs.belong.net/media/social/venue-ready-before-doors.webp --- :: ## Overview This guide walks a venue operator through launching their first check-in campaign: configuring how customers check in, setting rewards, funding the campaign, and getting a QR code customers can scan. Prepare the flow before doors open: choose the access rule, make the reward offer clear, and put the right QR where guests can see it while waiting. For a café using staff-set bills, choose the payment-request QR; for a simple free meetup, start with attendance check-in. For the partner economics behind campaigns, see the [Venue Partner Guide](https://docs.belong.net/belong-checkin/venue-partner) and [Fees & Staking](https://docs.belong.net/belong-checkin/fees-and-staking). ## Before you start - A Belong CheckIn account (sign in with email, Google, or a Belong account) - A venue or hub to run the campaign for - USDC to fund customer rewards (you can add this later) ## 1. Choose a check-in mode In **Hub details → CheckIn → General**, set how customers will check in: | Mode | Use it for | | -------------- | ------------------------------------------ | | Free | Meetups and free community visits | | Venue payment | Cafés, bars, restaurants, paid experiences | | NFT ticket | Ticketed events and gated entry | | NFT membership | Clubs and member-only spaces | See [Check-In Modes](https://docs.belong.net/belong-checkin/check-in-modes) for full details. You can combine a payment or free mode with a membership option. ### Selling event tickets A venue hosting a ticketed event can offer regular (non-NFT) tickets with Stripe Connect card payments, or NFT tickets through the configured NFT checkout partner, including cards where available. Choose and configure that route in the event's ticket/payment settings; the hub access-mode table above does not mean that all event tickets must be NFTs. See [Event Creation](https://docs.belong.net/belong-checkin/event-creation) and [Payments](https://docs.belong.net/belong-checkin/payments-and-onramp). The venue wallet and reward-budget settings below apply to the on-chain venue campaign. They are separate from the organizer's Stripe Connect payout account. ## 2. Configure payment and rewards In **Venue** settings, configure: - **Payment network** — BNB Chain Mainnet - **Accepted tokens** — USDC, LONG, or both - **LONG handling** — auto-stake, auto-convert to USDC, or direct transfer - **Visitor rewards** — a fixed visit bounty and/or a percentage of spend - **Promoter rewards** — a fixed referral bounty and/or a percentage of spend - **Daily check-in limits** and **approval requirements** - **Verification** — location-based and/or QR-based Each venue has a **payment account** (shown as a venue wallet). From there you can add reward balance, view the network, copy the address, and see whether the venue is active. ## 3. Fund your campaign Deposit USDC into the venue account to fund customer and promoter rewards. Deposit fees apply (with discounts for staking LONG) — see [Fees & Staking](https://docs.belong.net/belong-checkin/fees-and-staking). Your first two deposits waive the platform fee. ## 4. Get your QR code From the **General → Check-in QR Code** card, print, download, copy, or share your QR. Place it where customers will scan it — a table, the bar, the register, or a receipt. For staff-confirmed amounts, switch the QR from **Check-in** to **Pay request** and add a label like `Table 12` — see [Payments](https://docs.belong.net/belong-checkin/payments-and-onramp#payment-request-qr). For ready-to-use signage copy by venue type, see [Venue QR Signage Examples](https://docs.belong.net/belong-checkin/venue-qr-signage-examples). ## 5. Go live Once funded and configured, customers can scan and check in. Review pending approvals, recent requests, and reward activity from your venue's CheckIn area. ## Related - [Venue Partner Guide](https://docs.belong.net/belong-checkin/venue-partner) - [Promoter Earnings Guide](https://docs.belong.net/belong-checkin/promoter-earnings-guide) - [Customer Rewards Guide](https://docs.belong.net/belong-checkin/customer_rewards_guide) # Customer Rewards Guide ::doc-figure --- height: 1013 width: 1440 alt: A gold reward token beside the words Check In First, Perk Unlocked. caption: The venue offer defines the bonus, perk, and spend conditions; rewards follow the required verification. placement: lead source-url: https://t.me/belongnet/480 src: https://docs.belong.net/media/social/check-in-perk-unlocked.webp --- :: # Discover Great Places. Earn Real Rewards. Welcome to **Belong CheckIn** — a wallet-optional rewards layer that connects real-world activity to verifiable on-chain rewards. :br You earn every time you show up, check in, and enjoy what venues offer — no crypto expertise needed. Start with the offer on the venue listing: it tells you which check-in bonus, perk, and spend reward are configured. A **check-in bonus** follows verified attendance; a **spend reward** also depends on the verified bill. Check those conditions before expecting a reward, especially when a promoter referred you. --- ## What Is Belong CheckIn? Belong CheckIn is a simple, transparent system that rewards real visits to real venues. :br It’s built to make the discovery experience fun, rewarding, and fair — both for you and for the venues you support. - **Wallet-optional:** You can earn and redeem rewards without needing a crypto wallet. - **Transparent:** Every reward is verifiable on-chain through our proof-of-check-in system. - **Instant:** Rewards appear right after your verified visit. - **Private:** We use minimal data, encrypt everything, and never sell your information. --- ## What You Earn When you participate, you get three types of benefits: 1. **Check-in Bonus** – a fixed LONG or credit reward for verified attendance. 2. **Venue Perk** – a benefit the venue chooses (e.g., discount, free drink, or priority access). 3. **Spend Reward** – a variable percentage based on your actual bill amount, configured by the venue. Your total reward depends on the venue’s configuration and whether a promoter referred you. ::doc-figure --- height: 450 width: 800 alt: A purple Belong token beside Visit Bounties, Spend Rewards. caption: Check the venue offer for the configured visit bounty, perk, and spend reward before taking part. placement: inline source-url: https://t.me/belongnet/401 src: https://docs.belong.net/media/social/visit-and-spend-rewards.webp --- :: --- ## How It Works ::mermaid ```text flowchart TD accTitle: From venue offer to configured reward accDescr: Read the offer, check in, verify the required visit or spend, then receive the configured reward. A[Read the venue offer] --> B[Check in at the venue] B --> C[Verify the required visit or spend] C --> D[Apply the configured reward] ``` :: Attendance and spend can unlock different benefits. A check-in bonus follows the configured attendance rules; a spend reward also needs the bill to be verified. A promoter referral can change the allocation of the same campaign budget. ### Step 1: Find a Venue Open the app or scan a promoter’s QR code to view participating venues. :br Each listing shows what you’ll earn for visiting — your check-in bonus, spend percentage, and any extra perks. ### Step 2: Check In When you arrive, tap “Check In” or scan the QR/NFC tag at the venue entrance. :br The app verifies your location and creates a temporary on-chain proof of visit. ### Step 3: Enjoy and Pay Eat, drink, or experience the venue as usual. Pay however you like — cash, card, Apple Pay, Google Pay, or LONG tokens (where available). ### Step 4: Verification and Reward The system confirms your visit through the venue’s POS data or receipt confirmation. :br Once verified, your rewards (check-in bonus + spend reward) appear instantly in your balance. --- ## Dual Path Reward Model ### Direct Discovery (Customer Found the Venue) - You receive the **full check-in bonus**, venue perk, and spend reward defined by the venue. - The venue covers 100% of the reward cost. ### Promoter-Linked Visit (Referred) - You receive the **standard customer share** (typically 70–80% of the venue’s configured reward budget). - The promoter receives a separate **commission** (typically 20–30%) from the same campaign budget. - The venue’s total marketing cost stays constant. > *Example:*:br > Venue allocates $10 reward budget per verified visit. > > - Direct customer = $10. > - Promoter referral = $8 to customer + $2 to promoter. :br > Both add up to the same cost for the venue. Visits made via community referral links may unlock exclusive perks, faster reward verification, and access to special promotions. These incentives are provided by the platform or venues as part of Belong’s engagement program — they do not affect token value or total venue costs. --- ## Paying With LONG (Optional) Some venues accept **LONG tokens** as payment — offering you extra value for doing so. **Benefits of Paying with LONG:** - **Instant settlement:** No waiting for card processors. - **Lower fees for venues:** Helps them offer better perks and higher rewards. - **3% instant discount:** Most venues offer a direct discount when you pay in LONG. - **Circular economy:** LONG can be spent, staked for access perks, or redeemed. Your transaction is processed automatically by smart contracts. These conversions are **programmatic operations**, not speculative trades or buybacks. --- ## Redeeming and Using Rewards You can redeem your LONG or credits in three simple ways: 1. **Instant USDC Conversion** – convert LONG to USDC at the current rate and withdraw to your bank or card via supported partners. 2. **Spend LONG** – use LONG directly at participating venues for future check-ins and perks. 3. **Stake LONG** – unlock additional benefits such as loyalty multipliers, faster verification, and premium event access. All conversions are operational processes managed by smart contracts for transparency and fairness. --- ## Loyalty Tiers (Activity-Based) The more you participate, the more you earn through tier-based multipliers. :br These tiers are based on **verified visits per month**, not token holdings. | Tier | Verified Visits per Month | Bonus Multiplier | Extra Perks | | -------- | ------------------------- | ---------------- | ----------------------------------------- | | Bronze | 5+ | 1.05× | Standard perks | | Silver | 10+ | 1.10× | Early access to new venues | | Gold | 20+ | 1.20× | Priority invites & enhanced spend rewards | | Platinum | 50+ | 1.30× | Concierge support, VIP events | Rewards update automatically at the start of each new month. --- ## Data Privacy & Verification Your privacy is critical. - GPS and NFC are used **only at check-in** to verify location. - Personal data is encrypted; only anonymous proofs are stored on-chain. - Venues see visit metrics, not your identity. - You can request data deletion at any time. Verification uses a **multi-layer check**: device signals, location hashes, and transaction confirmations. :br This ensures authenticity and prevents fraud while keeping the system trustless and privacy-safe. --- ## Frequently Asked Questions **Do I need crypto knowledge?**:br No. Everything works automatically, and you can always choose USDC payouts. **What if I don’t have a wallet?**:br You can earn rewards to your in-app balance and withdraw through normal payment partners. **Can I pay in fiat and still get rewards?**:br Yes — you earn based on verified visits and spend, no matter your payment method. **How long until I get my reward?**:br Instantly after verification (usually within seconds). **Are my rewards investments?**:br No. Rewards are a form of platform credit earned from activity — not financial instruments or yield products. **What happens to LONG tokens when I redeem or spend them?**:br All conversions and transfers are handled by smart contracts in a **programmatic, non-discretionary** way. They’re purely operational processes, not profit-linked or speculative. --- ## Transparency and Compliance All LONG-related actions (such as conversions or token sinks) are automated, activity-based operational processes. :br They do **not** represent market interventions, buybacks, or promises of profit. :br Your rewards are earned solely from verified activity, not investment. **Belong CheckIn** is designed for sustainable real-world engagement — turning every visit into proof of participation, not speculation. --- *End of Document – Customer Rewards Guide (Final, Compliance-Optimized)* # Promoter Earnings Guide ::doc-figure --- height: 562 width: 800 alt: A purple link terminal with the words One Promoter, One Link. caption: Share your own campaign link before the event so eligible visits can be attributed to your referral. placement: lead source-url: https://t.me/belongnet/460 src: https://docs.belong.net/media/social/one-promoter-one-link.webp --- :: # Turn Your Influence Into Income ## Overview Belong CheckIn pays you for **real-world outcomes**, verified transparently. :br You share venues and events; when your audience **visits, checks in, and spends**, you earn a **check-in bonus plus a percentage of verified spend** — both configured by the venue within their campaign budget. :br Attribution is on-chain, wallet-optional, and payouts are automatic after verification. :br Every payout originates from **venue marketing budgets**, not token issuance or speculative activity. Set up attribution before you share a campaign: use your own trackable link or QR, and check the venue's reward terms. A click shows interest; the verified visit or spend described below is what makes the referral eligible for its configured payout. Customer rewards and promoter earnings come from the venue's campaign budget. --- ## Core Principles - **Performance-based:** You earn only when a verified visit or spend occurs. - **Wallet-optional:** Users and promoters can participate with or without crypto wallets. - **Transparent:** Every check-in and payout is verifiable on-chain. - **User-first:** Visitors always receive their check-in bonus and venue perks. - **Configurable rewards:** Venues set spend percentages and decide whether to share the check-in bounty with visitors/promoters/both. - **Fraud-resistant:** Multi-layer verification ensures rewards trigger only on genuine activity. - **Regionally compliant:** Each campaign’s configuration adapts to local regulations regarding reward distribution. --- ## How You Earn — Dual Path Simplicity ### A) Promoter-Linked (You Earn) 1. You share a trackable link or QR code. 2. A user taps your link, arrives, and **checks in** via QR, NFC, or in-app flow. 3. The user receives their **check-in bonus** and any **venue perk**. 4. After **verified spend**, you earn your **promoter share** — a portion of the campaign bounty and/or a percentage of verified spend. 5. Campaigns may optionally split the check-in bonus (for example, 70 % visitor / 30 % promoter). 6. Settlement occurs automatically once verification completes, with funding drawn from the venue’s prepaid campaign deposit. ### B) Direct Discovery (User Only) - The user finds the venue directly in-app and checks in. - They receive their **check-in bonus** and any applicable perk. - **No promoter payout** is triggered in this case — all rewards go to the customer. - Venues may choose to add exclusive bonuses for referral-linked visits (faster verification, limited-time promotions, etc.). --- ::mermaid ```text flowchart TD accTitle: A promoter referral through verification accDescr: A trackable link leads to a guest visit; the configured eligible action is verified before the campaign reward is allocated. A[Share your campaign link or QR] --> B[Guest arrives and checks in] B --> C[Verify the eligible visit or spend] C --> D[Apply the campaign allocation] D --> E[Settle the configured promoter reward] ``` :: The link establishes attribution, while verification establishes reward eligibility. The venue sets the allocation and funds the campaign; direct discovery has no promoter payout. ## Visit Lifecycle 1. **View:** User clicks your link or scans your QR. 2. **Arrival:** GPS and device signals confirm presence. 3. **CheckIn:** QR/NFC/App binds the visit. 4. **Spend:** Payment or receipt data confirms a purchase, independent of payment method. 5. **Verification:** The system authenticates the match between check-in and spend. 6. **Payout:** Your reward (check-in bounty and/or spend percentage) is released automatically. --- ## Reward Allocation Models (Regional Flexibility) Belong supports multiple models to stay compliant with regional regulations: | Mode | Customer Reward | Promoter Reward | Notes | | ------------- | ----------------------------------------------- | ---------------------------- | ------------------------------------------ | | Promoter-Only | Venue perks only | Check-in bounty + % of spend | Used where customer incentives face limits | | Customer-Only | Check-in bounty + LONG rebate | None | Common in rebate-permitted regions | | Split Mode | Shared bounty according to ratio (e.g. 80 / 20) | Shared percentage | Default flexible configuration | No matter which mode a venue selects, the **total budget per verified visit** remains constant. :br Belong simply reallocates the same reward pool according to campaign design. --- ## CheckIn Bonus Split Campaigns can configure how the base LONG reward divides between visitor and promoter. - Example: 5 LONG bonus split 70 % visitor / 30 % promoter. - Spend percentage is independent and configured by each venue. - Ratios display in your dashboard before sharing. - Higher staking tiers may unlock improved splits or larger pools. - All payments originate from venue-deposited budgets — no dilution or treasury subsidies. --- ## Two-Part Reward Structure Each venue defines its campaign rewards using two components: 1. **Visit Bounty (CheckIn Bonus):** A fixed amount for bringing a customer (for example, $2–$20 or equivalent LONG). 2. **Spend Bonus:** A configurable percentage of verified spend (for example, 5–25 %). **Your Total Earnings = Visit Bounty + Spend Bonus (venue-defined)** --- ### Real Earning Examples **Coffee Shop Visit:** - Customer spends: $20 - Venue offers: $2 bounty + 8 % of bill - You earn: $2 + $1.60 = **$3.60** **Restaurant Visit:** - Customer spends: $100 - Venue offers: $10 bounty + 15 % of bill - You earn: $10 + $15 = **$25** **Bar Visit:** - Customer spends: $75 - Venue offers: $8 bounty + 12 % of bill - You earn: $8 + $9 = **$17** All values are examples; actual payouts depend on the venue’s active campaign. --- ## Choose Your Payout Method ### Option 1 — USDC (Instant Cash) - Receive **90 %** of your earnings. - Immediate liquidity and bank withdrawal. - Example: Earn $20 → Get $18 USDC → Cash out directly. ### Option 2 — LONG Tokens (Max Efficiency) - Receive **95–99 %** of your earnings (based on staking tier). - Same nominal payout value, lower fee structure. - Example: Earn $20 → Get $19–$19.80 in LONG. - Can stake for higher tiers, hold, or spend at participating venues. --- ## Staking Benefits Stake LONG to access higher payout tiers and exclusive analytics. | Staking Tier | LONG Required | Payout Share | | ------------ | ------------- | ------------ | | None | 0 | 95 % in LONG | | Bronze | 50,000 | 96 % in LONG | | Silver | 250,000 | 97 % in LONG | | Gold | 500,000 | 98 % in LONG | | Platinum | 1,000,000 | 99 % in LONG | **Example (Platinum Tier):** - Earn $100 in rewards. - USDC choice → $90. - LONG choice → $99 (10 % more). Staking is optional and non-custodial; your tokens remain in your wallet while locked for campaign participation. ::doc-figure --- height: 450 width: 800 alt: Purple tokens and gift boxes beside Unlock Bigger Rewards with LONG. caption: The selected payout method and LONG staking tier determine the documented promoter payout share. placement: inline source-url: https://t.me/belongnet/201 src: https://docs.belong.net/media/social/long-staking-rewards.webp --- :: --- ## How to Maximize Earnings ### 1 – Target High-Value Venues - Fine dining and nightlife typically offer larger bounties. - Focus on categories with recurring visits (fitness, wellness, entertainment). ### 2 – Build Your Network - Cultivate genuine customer relationships. - Refer new promoters: Earn $250 once your referral hits $5,000 in verified earnings. - Strong networks compound campaign results. ### 3 – Timing Strategies - Watch for time-bound boosts (double bounties during off-peak hours). - Prioritize venues with active seasonal promotions. ### 4 – Diversify Venues - Don’t rely on one campaign. - Mix cafés, restaurants, and experiences. - Example: 10 venues × 4 new customers/month × $20 avg = $800/month. --- ## Getting Started ### Step 1 – Sign Up - No wallet needed — email or phone sign-up. - Instant approval and dashboard access. ### Step 2 – Find Venues - Browse the in-app map. - Filter by reward rate and category. ### Step 3 – Share Your Code - Each venue generates a unique QR and Smart Link. - Share via social platforms or direct messages. ### Step 4 – Get Paid - Customer visits and scans your code. - Verification completes; payout releases automatically. - Choose your payout method at any time. --- ## Cashing Out Your Earnings ### USDC to Cash (through partners) - **Bank Transfer:** Direct withdrawal. - **Card Load:** Instant. ### LONG Token Options - **Hold:** Participate in Belong’s ecosystem. - **Stake:** Unlock tier benefits. - **Convert:** Exchange to USDC or use for in-app payments. --- ## Pro Promoter Strategies ### The Coffee Shop Regular - Target busy commuter cafés. - 20 visits/day × $3 avg = $60/day. ### The Dinner Party Organizer - Host weekly dinners at venues with 20 % reward rate. - 8 guests × $50 × 20 % = $80 per dinner. ### The Nightlife Connector - Partner with high-spend venues (tables, bottle service). - One group spends $500 × 15 % = $75 earned. ### The Corporate Lunch Hero - Focus on weekday lunch spots. - 50 lunches/week × $5 avg = $250 weekly. --- ## Referral Program Expand your network and income by bringing other promoters: - Earn **$250 USDC** when your referral hits $5,000 in verified earnings. - Unlimited referrals allowed. - Rewards funded entirely by Belong’s referral campaign budget. --- ## Track Your Success ::doc-figure --- height: 450 width: 800 alt: Campaign charts and a trophy beside Every Check-In Tells a Story. caption: Compare attributed visits and campaign results in your promoter dashboard. placement: inline source-url: https://t.me/belongnet/389 src: https://docs.belong.net/media/social/promoter-performance.webp --- :: ### Real-Time Dashboard - Monitor earnings instantly. - Identify top-performing venues. - Adjust your promotion strategy. ### Weekly Analytics - Review venue performance. - Spot growth trends and timing patterns. --- ## Payment Details ### Instant Payments - Verified visits settle immediately. - No minimum payout thresholds. - ZERO manual review delays. ### Payouts & Fees - **Assets:** LONG or USDC. - **Settlement:** Automatic after verification. - **Fee Reduction:** LONG payouts have lower platform fees. - **Thresholds:** Micro-earnings auto-aggregate until release. --- ## FAQs **Q: Do I need a large audience?**:br A: No. Ten active friends beat ten thousand idle followers. **Q: How fast do I get paid?**:br A: Instantly after verified visit and spend. **Q: Can venues change their rewards?**:br A: Yes. You always see current rates before sharing. **Q: What counts as a verified visit?**:br A: A customer physically checks in and makes a purchase. **Q: Do I need to understand crypto?**:br A: No. Select USDC and cash out to your bank; crypto is optional. **Q: Is there a limit to earnings?**:br A: None. You’re limited only by how many verified visits you generate. --- ## Ready to Start Earning? 1. Register and set payout preference (USDC or LONG). 2. Choose venues with strong reward percentages. 3. Share Smart Links or QRs. 4. Track your verified spend and bonuses in your dashboard. 5. Stake LONG to increase payout rates. Belong CheckIn turns community engagement into verified, measurable income. :br Promoters earn a check-in bonus plus a venue-defined percentage of verified spend, with instant settlement and full on-chain proof. :br Your audience gets perks, your venues gain customers, and you earn for impact — sustainably and compliantly. ### **Belong CheckIn — Real Engagement. Real Earnings.** # Venue Partner Guide ::doc-figure --- height: 450 width: 800 alt: Campaign dashboard cards beside Run Referral Campaigns With Precision. caption: Set campaign rules and budgets, then review performance in the venue dashboard. placement: lead source-url: https://t.me/belongnet/323 src: https://docs.belong.net/media/social/campaign-management.webp --- :: # Grow With Verified Visits Belong CheckIn connects venues with real visitors, not impressions. :br It transforms promotions into measurable outcomes: **visits, check-ins, and verified spend** — all tracked transparently on-chain. Use this guide to plan the campaign economics before launching. Choose which verified action you want to reward, set the customer and promoter allocations, and fund the campaign balance. The [Venue Quick Start](https://docs.belong.net/belong-checkin/venue-quickstart) turns those decisions into dashboard setup steps. --- ## Overview Belong allows your venue to: - Bring in new customers through community-driven referrals. - Reward real visits and verified transactions. - Control campaign budgets precisely — pay only for verified engagement. - Adapt reward structures to regional compliance requirements. All activity is verified automatically using GPS, device signals, and check-in logic. :br No guesswork, no fake traffic — just measurable, funded engagement. --- ## Tickets and customer payments Venues hosting events can choose regular (non-NFT) ticket payments through Stripe Connect or NFT tickets purchased through the configured NFT checkout partner. NFT checkout can accept cards as well as crypto where enabled; accepting a card does not mean a ticket is regular or that its processor is Stripe Connect. Direct venue QR payments, ticket payments, bracelet top-ups, and reward budgets are separate flows. See [Payments](https://docs.belong.net/belong-checkin/payments-and-onramp) for the supported routes and availability before describing a particular setup to customers. ## How It Works 1. **Set Your Campaign Budget:** Define a total spend **denominated in USDC or LONG**. 2. **Choose Reward Mode:** Select between Customer, Promoter, or Split model. 3. **Define Rewards:** Set your check-in bounty and/or percentage of spend. 4. **Launch:** Campaign goes live on the Belong CheckIn app for discovery and sharing. 5. **Pay for Verified Results Only:** Payouts occur only after confirmed visits or purchases. Venues maintain full control — you can pause, adjust, or top up campaigns anytime. --- ## Marketing Your QR Code Once your campaign is live, display your CheckIn QR code with clear, benefit-led messaging at reception desks, table cards, and entrances. :br Belong provides ready-to-use copy examples organised by venue type — nightclubs, hotels, restaurants, gyms, and more. See **[QR Signage Examples](https://docs.belong.net/belong-checkin/venue-qr-signage-examples)** for headlines, sublines, short-form stickers, and messaging guidelines you can copy and customise. --- ## Reward Modes (Regional Flexibility) Belong supports three reward configurations to comply with local laws: | Mode | Customer Reward | Promoter Reward | Description | | ------------- | ---------------------------------------- | ---------------------------- | ------------------------------------------------- | | Promoter-Only | Venue perks only | Check-in bounty + % of spend | Used where direct consumer incentives are limited | | Customer-Only | Check-in bounty + rebate in LONG | None | Used where referral commissions are restricted | | Split Mode | Shared check-in bonus + optional spend % | Shared proportionally | Default flexible setup | Each campaign’s total reward cost per visit is fixed — Belong simply allocates that pool differently according to mode. This flexibility ensures Belong campaigns can operate in any region without changing the underlying economics. --- ## Key Features ### Pay for Verified Results You pay only when users actually check in and/or spend at your venue. :br Verification uses a layered system combining: - GPS and device confirmation - QR/NFC check-in - Payment or receipt validation Fraud prevention ensures only genuine transactions trigger payouts. ### Prepaid Campaigns You **pre-fund** a campaign balance in **USDC or LONG**. :br Rewards and platform fees are deducted automatically. :br No overspending — campaigns end when funds deplete. ::doc-figure --- height: 450 width: 800 alt: A transparent campaign-budget vessel with the words Marketing With No Surprises. caption: Campaigns spend from the funded budget using the configured reward rules. placement: inline source-url: https://t.me/belongnet/223 src: https://docs.belong.net/media/social/funded-campaign-budget.webp --- :: ### Transparent Accounting All campaign activity, payouts, and fees are visible through your venue dashboard and mirrored on-chain for full transparency. --- ## Example Campaigns ### Coffee Shop Example - Budget: $1,000 - Reward: $2 per visit + 5 % of spend - Expected visits: \~400 verified customers - Promoter mode: Split (70 % customer / 30 % promoter) - Automatic settlement, no manual reviews. ### Restaurant Example - Budget: $5,000 - Reward: $10 bounty + 10 % spend - Goal: 300 new diners - Campaign duration: 30 days - Payouts occur instantly after verification. ### Nightlife Venue Example - Budget: $2,000 - Reward: 12 % of spend only (no fixed bounty) - Perfect for bottle service and large tabs. - Real-time analytics show engagement by promoter and customer. --- ## Funding Options You can fund campaigns using: - **USDC:** deposit directly to your venue wallet. - **LONG:** deposit LONG; it’s credited to your campaign balance automatically. - **Fiat via partners:** pay with card/bank through **licensed payment partners**; funds are **converted to USDC** and then credited to your campaign. - **Hybrid:** any mix of the above. Conversion to USDC is real-time and transparent. :br Belong does **not** directly custody or transmit fiat; partners handle regulated fiat operations. --- ### Accept LONG Tokens for Additional Benefits Venues may optionally **accept LONG tokens for on-premise payments** to attract more customers and reduce payment friction. :br Belong does not process these transactions — they are handled directly between the customer and venue or through **licensed payment partners**. **Benefits for venues:** - **Instant settlement:** no waiting for bank transfers. - **Lower processing costs:** typically 2.5 % vs. 4–5 % for card payments. - **Customer incentive:** venues can offer up to a 3 % discount on LONG payments to encourage usage. - **Flexibility:** venues can hold LONG, stake it for fee reductions, or convert it to USDC/USD via licensed exchanges or partners. --- ## Regional Adaptation Belong’s framework complies with jurisdictional differences: - Rewards may function as **bounties, rebates, or discounts**, depending on local classification. - LONG serves purely as **a settlement and utility token**, not an investment asset. - Venues can restrict payout mode (USDC only, LONG only, or mixed) to meet local compliance needs. - Belong dynamically adjusts disclosures and user flows by region. --- ## Deposit Fees Belong CheckIn uses a transparent, performance-based fee model. :br You can reduce your deposit fees by staking LONG tokens or by maintaining campaign history on the platform. | Your Status | Deposit Fee | Example: Deposit $500 | | ---------------- | ----------- | --------------------: | | First 2 deposits | 0% + $5 | Pay $505 total | | Standard | 10% + $5 | Pay $555 total | | With Staking | 5–9% + $5 | Pay $530–$550 total | Deposit fees are automatically applied at the time of campaign funding. :br All deposits are denominated in **USDC or LONG**, and if you pay via fiat, the licensed partner converts it to USDC before deposit. --- ## Venue Staking Benefits Stake LONG tokens to **reduce your deposit fees** and unlock **advanced visibility tools**. :br Staking is *non-custodial* — your tokens remain in your wallet and are locked for the campaign duration only. | Tier | LONG Required | Deposit Fee | | -------- | ------------- | ----------- | | Bronze | 50,000 | 9% | | Silver | 250,000 | 8% | | Gold | 500,000 | 7% | | Platinum | 1,000,000 | 5% | **Additional Benefits:** - Boosted discovery placement in the Belong CheckIn app - Access to premium analytics and optimization tools - Priority support and optional whitelabel customization credits - Transparent, on-chain staking logic - Tokens unlock automatically when campaigns end --- ## Incentive Transparency Each user sees their available rewards before visiting. :br Promoters see campaign details, bounty amounts, and current splits. :br You can update campaigns anytime, but changes apply only to future check-ins. Staking affects only **venue-side fees and exposure**, never user or promoter rewards. :br It ensures that highly engaged venues receive lower deposit costs and stronger visibility — creating a fair and scalable marketplace. --- ## Payment and Settlement Flow 1. **Pre-Fund Campaign:** **Deposit USDC or LONG** into your venue wallet. (If paying in fiat, a licensed partner converts it to USDC before deposit.) 2. **Engagement:** Customers discover your venue and check in. 3. **Verification:** Device + spend confirmed. 4. **Reward Distribution:** LONG and/or USDC payouts sent to users and promoters. 5. **Reporting:** Full transaction record available in your dashboard. All fiat top-ups and settlements are handled exclusively through **regulated financial partners** that hold the required payment or money-transmission licenses in each jurisdiction. :br Belong coordinates campaign logic and verification but does **not** directly custody or transmit fiat. No reward leaves your budget until Belong confirms verified activity. :br Funds cannot be redirected or withdrawn mid-verification to prevent manipulation. --- ## Example of Reward Allocation Let’s look at two customers visiting the same venue: | Visit Type | Who Earns | Where Reward Comes From | | ------------------------ | ------------------- | ----------------------------- | | Direct (in-app) | Customer only | Venue’s fixed campaign budget | | Referral (promoter link) | Customer + promoter | Shared from same venue budget | No “extra” tokens are created — Belong simply splits your pre-funded pool according to campaign logic. :br The budget and payout math always balance. --- ## Campaign Management Tools - **Dashboard Control:** Start, pause, or adjust campaigns anytime. - **Budget Alerts:** Notifications when funds drop below threshold. - **Analytics:** Track ROI by category, promoter, and time period. - **Smart Splits:** Automatically rebalance customer/promoter shares based on performance. - **Regional Compliance Engine:** Automatically aligns disclosures with local requirements. --- ## Reporting and Analytics Access detailed metrics: - Verified visits and total spend per campaign - Average reward per visit - ROI and repeat-visit rate - Leaderboards by promoter and region - Conversion funnel from link click to verified spend A link click measures interest; a verified visit or purchase is the funded outcome. Compare those stages before judging which promoter or campaign brought useful results. Exportable in CSV or directly to your accounting system. ::doc-figure --- height: 450 width: 800 alt: A purple reporting console with the words Your Campaign Data, Decoded. caption: Compare the funnel from link click to verified spend when reviewing campaign performance. placement: inline source-url: https://t.me/belongnet/338 src: https://docs.belong.net/media/social/campaign-data-decoded.webp --- :: --- ## Why Venues Choose Belong ### Verified Results Every dollar from your campaign ties to a real visitor and transaction. ### Budget Control Fixed spend, capped exposure — no runaway costs. ### Transparency Real-time dashboards show every check-in, spend, and payout. ### Regional Compliance Automatic alignment with local incentive laws and tax reporting. ### Integrated Token Utility LONG powers campaigns as a utility and settlement layer — not an investment instrument. :br Venues use it to fund campaigns, access analytics, or stake for enhanced exposure. --- ## FAQ **Q: Do I need to handle crypto wallets?**:br A: No. You can fund and track everything in **USDC or LONG**. If you prefer fiat, licensed partners convert it to USDC for you. **Q: Can I control how rewards split?**:br A: Yes. Choose between customer, promoter, or shared modes. **Q: Can I refund or stop a campaign?**:br A: You can pause anytime. Unused budget remains in your venue wallet. **Q: Is LONG a security or revenue share?**:br A: No. LONG is purely a utility and settlement token used for campaign activation and rewards. **Q: How are payments verified?**:br A: Belong combines device signals, POS data, and payment confirmations to authenticate every visit. --- ## Compliance and Integrity Belong operates under a clear rule: **all rewards must originate from venue-funded budgets**. :br No speculative token mechanisms, no discretionary treasury actions. :br This ensures: - Predictable accounting for venues. - Full auditability of reward flows. - Stable token utility independent of market fluctuations. All fiat inflows and payouts occur through **licensed financial intermediaries**; Belong does not custody or transmit fiat. :br Belong orchestrates logic and reporting only, ensuring compliance with financial and money-transmission regulations in every region where it operates. Venues can confidently participate knowing every payout corresponds directly to verified, audited activity. --- ## Summary Belong CheckIn converts marketing spend into verified visits and measurable ROI. :br You control your budget, reward mode, and payout mix — Belong automates everything else. :br All rewards are drawn from your pre-funded campaign and processed through compliant partners, ensuring transparency, security, and regulatory alignment. Belong brings real people through your door and verifies every one of them — safely, transparently, and globally. --- ### **Belong CheckIn — Verified Engagement, Proven Growth.** # Event Creation ::doc-figure --- height: 900 width: 1280 alt: A card organizer with the words Describe It, Review Tiers. caption: Review dates, prices, and supplies before publishing; regular tickets and NFT tickets use different payment routes. placement: lead source-url: https://t.me/belongnet/490 src: https://docs.belong.net/media/social/describe-review-ticket-tiers.webp --- :: ## Overview Belong CheckIn lets organizers create events, ticket tiers, and check-in campaigns from natural language. The chat assistant turns a description into a configured event; you confirm the details and choose regular tickets or NFT tickets. Regular tickets use Stripe Connect card checkout without deploying an NFT collection. NFT tickets use the configured NFT checkout partner and can accept cards or crypto where enabled. Give the assistant the event name, venue, date with time zone, and the price and quantity of each ticket tier. Review the draft before publishing. For example, General and VIP tiers need their own supplies and prices; the payment route determines whether buyers receive regular tickets or NFTs. ## Ways to create an event | Method | How | | ----------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | **Chat** | Describe your event to the assistant ("Create a paid workshop on Friday, 50 tickets at $20"). It drafts the event and ticket tiers for you. | | **Voice** | Use [Voice Mode](https://docs.belong.net/belong-checkin/ai-and-voice) to speak your event into existence; it transcribes and creates the event with a visual summary card. | | **Guided wizard** | Step through free or paid event setup with prompts. | | **Telegram** | Use the public bot's `/createevent`, `/wizard free`, or `/wizard paid` commands — see [Telegram Bot](https://docs.belong.net/belong-checkin/telegram-bot). | ## From description to live tickets ::mermaid ```text flowchart LR; A[Describe your event] --> B[Assistant drafts event + tiers] B --> C[Review the event card] C --> D{Ticket format} D -->|Regular| S[Connect Stripe and enable card payments] D -->|NFT| N[Deploy ticket NFT collection] S --> E[Tickets on sale] N --> E E --> F[Verify ticket registration or configured NFT at entry] ``` :: 1. **Describe the event** — title, date, location, ticket tiers, and pricing in plain language. 2. **Review** — the assistant shows an event summary card with the key details and a direct link. 3. **Choose the checkout** — for regular tickets, connect the organizer's Stripe account and enable the event's card payment option. For NFT tickets, configure and deploy the ticket collection; the app shows signing when required. 4. **Sell tickets** — regular tickets use Stripe Connect card checkout and produce a ticket registration and entry QR. NFT tickets use the configured NFT checkout partner, which can offer card or crypto payment and deliver the ticket NFT. 5. **Check in** — verify the regular ticket registration/QR or the configured NFT access at the event (see [Check-In Modes](https://docs.belong.net/belong-checkin/check-in-modes)). ## Ticket tiers and pricing You can configure multiple ticket tiers (for example General, VIP, Student), each with its own price and supply. NFT ticket mode connects hub access to these paid tiers. If a hub has no ticketed event attached, the app can guide you into chat-assisted paid event setup. NFT mint fees apply to NFT ticket sales, not to regular tickets that do not mint an NFT. NFT issuers can set an optional secondary-sale royalty — see [Fees & Staking](https://docs.belong.net/belong-checkin/fees-and-staking). ::doc-figure --- height: 562 width: 800 alt: A gold clock beside Set the Zone Then Publish. caption: Confirm the event time zone along with dates, prices, and ticket quantities before publishing. placement: inline source-url: https://t.me/belongnet/471 src: https://docs.belong.net/media/social/event-time-zone.webp --- :: ## Events, maps, and discovery Belong supports event pages, event-week pages, and public event maps that can be shared and prioritize active location context. Attendees can discover events in the app or through the Telegram bot. ## Related - [AI & Voice](https://docs.belong.net/belong-checkin/ai-and-voice) — the assistant and voice mode - [Minting Guide](https://docs.belong.net/guides/crypto/minting) — the developer view of NFT deployment and checkout - [Apple Wallet](https://docs.belong.net/belong-checkin/apple-wallet) — add tickets to Apple Wallet # Wallet & Sign-In ::doc-figure --- height: 450 width: 800 alt: Purple text capsules reading No seed phrases needed. caption: The app creates a guest wallet without a seed phrase; signing in later preserves its original EVM address. placement: lead source-url: https://t.me/belongnet/122 src: https://docs.belong.net/media/social/built-in-wallet-sign-in.webp --- :: ## Overview Belong CheckIn is **wallet-optional for visitors**. A wallet is created for you automatically on your first visit, so you can check in and earn rewards without any setup. You can sign in later to secure your account and unlock more features. For a guest, the first decision is simply how to enter or buy the ticket offered by the venue. Sign-in secures your account; a wallet handles supported on-chain actions when needed. An **NFT ticket** is a blockchain asset, while a regular ticket can use its issued registration and QR without an NFT purchase. ## Tickets do not all require an NFT Regular (non-NFT) ticket purchases use Stripe Connect card checkout and issue a ticket registration and entry QR. The buyer does not need to fund a crypto wallet or mint an NFT for that purchase. NFT tickets use the configured NFT checkout partner; cards may be accepted there too, with the ticket NFT delivered to a wallet. See [Payments](https://docs.belong.net/belong-checkin/payments-and-onramp). ## Guest wallets On your first visit, the app creates an **EVM wallet** for you as a guest — no signup, no seed phrase. This wallet is the persistent identifier for your activity (check-ins, rewards, tickets) and is **preserved** when you later sign in. ## Signing in The app supports several sign-in options: | Method | What it does | | ------------------ | ---------------------------------------------------------------- | | **Guest** | Start instantly with an auto-created wallet | | **Email** | Secure your account with an email one-time code | | **Google** | Sign in with Google; adds a Sui wallet alongside your EVM wallet | | **Belong account** | Link your Belong identity for cross-product features | When you upgrade from guest to a signed-in account, your **EVM address stays the same** — signing in only enriches your account with your identity (and, for Google, a Sui address). Nothing changes your original wallet. ## Passkeys You can link a **passkey** to a signed-in account for faster future sign-in with Face ID, Touch ID, or device biometrics. Linked passkeys can be viewed and removed from **Profile → Integrations**. ## Multi-chain wallets Your account can hold wallets across multiple chains: - **EVM** (created for every user) — used for check-ins, payments, and rewards - **Sui** — added when you sign in with Google Wallet screens show your balances, transactions, tickets, rewards, vesting, and venue payment accounts. They also show native gas-token balances for EVM networks; when a sponsored action needs gas attention, the app guides you to the right funding or recovery surface. ## What you can manage From the wallet area you can: - View balances and transaction history - See and use your tickets and memberships - Track rewards and vesting - Manage venue payment accounts (for operators) ## Related - [Customer Rewards Guide](https://docs.belong.net/belong-checkin/customer_rewards_guide) — earning and redeeming rewards - [Sponsored Gas](https://docs.belong.net/belong-checkin/sponsored-gas) — completing actions without holding gas tokens - [Developer: Integration Overview](https://docs.belong.net/belong-checkin/developer/integration-overview) — the account model for developers # AI & Voice ::doc-figure --- height: 1013 width: 1440 alt: A microphone and phone with the words Hands Full? Speak the Setup. caption: Describe the setup by voice, then review the proposed event or campaign details. placement: lead source-url: https://t.me/belongnet/479 src: https://docs.belong.net/media/social/speak-the-setup.webp --- :: ## Overview Belong CheckIn includes an AI chat assistant that helps you create and edit events, hubs, check-in campaigns, regular or NFT tickets, and related flows from natural language. **Voice Mode** turns that chat into a hands-free conversation: you speak, it transcribes, the assistant responds out loud. Use voice when typing is inconvenient, such as during a venue walk-through. Say what you want to create and include the date, place, and ticket details, then review the assistant's proposed changes. Speaking the request makes input easier; the draft review is still where you catch an incorrect time or price. ## The chat assistant Ask the assistant to do things in plain language and it drafts them for you: - Create or edit an event, hub, or check-in campaign - Set up ticket tiers and pricing, choosing regular Stripe Connect card payments or NFT ticket checkout where configured - Answer questions about your events and venues When a workflow needs a wallet signature, the app shows an **inline signing surface** instead of asking you to copy contract details manually. ## Voice Mode Voice Mode provides an immersive, hands-free experience — useful on mobile or when you're setting things up on the go. ### Turning it on 1. Click the phone icon in the chat header to enter Voice Mode 2. The interface switches to a full-screen voice overlay 3. Status indicators show when it's listening, processing, or speaking ### How a turn works ::mermaid ```text flowchart LR; A[Press & hold to talk] --> B[Recording] B --> C[Release] C --> D[Transcription] D --> E[AI processing] E --> F[Spoken response] F --> A ``` :: - **Push-to-talk** — hold the large microphone button to record, with a live timer - **Transcription cards** — your words appear as "You said: …" - **Spoken responses** — replies are read aloud; a mute toggle disables automatic speech - **Event cards** — when you create an event by voice, a visual summary card appears with a direct link ### Tips - Speak naturally — full sentences work best for event details - Use the mute toggle if you only want text - Voice messages appear in your regular chat history and sync across devices ## Privacy - Your microphone is only active while you're recording, with a clear visual indicator - Audio is transmitted securely, processed for transcription, and discarded appropriately - Voice features require your explicit microphone permission, which you can revoke at any time ## Browser support Voice Mode works in modern Chrome/Chromium, Firefox, Safari (iOS and macOS), and Edge. If the microphone or recording APIs aren't available, the app falls back gracefully to text chat. ## Related - [Event Creation](https://docs.belong.net/belong-checkin/event-creation) — creating events with the assistant - [Telegram Bot](https://docs.belong.net/belong-checkin/telegram-bot) — create events from chat on Telegram # Belong CheckIn ::doc-figure --- height: 450 width: 800 alt: "A phone with the words Belong CheckIn: the first on-chain affiliate network for real venues." caption: Discover a venue, verify your visit, and receive the benefit configured for that offer. placement: lead source-url: https://t.me/belongnet/162 src: https://docs.belong.net/media/social/checkin-for-real-venues.webp --- :: ## Overview Belong CheckIn turns a visit to a venue into a recorded, rewardable action. A visitor scans a QR code at the venue, the venue confirms the visit under whichever access mode it has configured, and any rewards the venue funded are distributed on-chain. Open the product at [checkin.belong.net](https://checkin.belong.net), then use the guides below for your role. For a first visit, think of the flow as **arrive → verify → receive the configured benefit**. Venue operators choose the access rules and fund any campaign rewards; visitors follow the flow shown by that venue. The guides below separate guest instructions, venue setup, and developer integration. Visitors do not need a wallet or an app to start. Wallets, tickets, and payments come into play only when a venue's mode requires them. ## Regular and NFT ticketing Events and venues can sell **regular (non-NFT) tickets with Stripe Connect card payments**, or choose **NFT tickets with card or crypto checkout through the configured NFT checkout partner**. A card payment does not necessarily create an NFT. [Payments](https://docs.belong.net/belong-checkin/payments-and-onramp) explains these routes and how they differ from venue QR payments and bracelet top-ups. ## Start here | You are | Read this | | -------------------------------------- | --------------------------------------------------------------------------------------------- | | A venue setting up your first campaign | [Venue Quick Start](https://docs.belong.net/belong-checkin/venue-quickstart) | | A venue deciding whether this fits | [Venue Partner Guide](https://docs.belong.net/belong-checkin/venue-partner) | | A customer earning rewards | [Customer Rewards Guide](https://docs.belong.net/belong-checkin/customer_rewards_guide) | | A promoter sharing venues | [Promoter Earnings Guide](https://docs.belong.net/belong-checkin/promoter-earnings-guide) | | A developer integrating | [Integration Overview](https://docs.belong.net/belong-checkin/developer/integration-overview) | | Looking for the whole product surface | [App Features](https://docs.belong.net/belong-checkin/app-features) | ## How a check-in works A venue runs one access mode at a time. The mode decides what a visitor has to do before the check-in counts. | Mode | What the visitor does | | -------------- | --------------------------------------------------------------------------------------------- | | Free check-in | Scans the QR and confirms attendance. No payment. | | Venue payment | Completes the offered wallet or enabled thirdweb card flow, then receives configured rewards. | | NFT ticket | Holds or buys the event ticket NFT first. | | NFT membership | Holds a membership NFT first. | [Check-In Modes](https://docs.belong.net/belong-checkin/check-in-modes) covers the amount flows for venue payment, and which mode suits which kind of venue. ## Money - [Payments](https://docs.belong.net/belong-checkin/payments-and-onramp) — card checkout and staff-confirmed payment requests. - [Fees & Staking](https://docs.belong.net/belong-checkin/fees-and-staking) — mint, deposit, and withdrawal fees, and how staking reduces them. - [Sponsored Gas](https://docs.belong.net/belong-checkin/sponsored-gas) — let visitors mint or pay without holding the native gas token. ## Getting in - [Wallet & Sign-In](https://docs.belong.net/belong-checkin/wallet-and-auth) — guest wallets, email and Belong sign-in, passkeys, and multi-chain support. - [Apple Wallet Passes](https://docs.belong.net/belong-checkin/apple-wallet) — tickets that work offline at the door. - [Telegram Bot & Mini App](https://docs.belong.net/belong-checkin/telegram-bot) — run events from Telegram. ## Creating and running events - [Event Creation](https://docs.belong.net/belong-checkin/event-creation) — events with regular or NFT tickets from plain language. - [AI & Voice](https://docs.belong.net/belong-checkin/ai-and-voice) — the assistant that creates and edits events, hubs, and campaigns. - [Connect Belong AI Deploy](https://docs.belong.net/belong-checkin/connect-ai-deploy) — launch your own agent from an existing account. - [Venue QR Signage Examples](https://docs.belong.net/belong-checkin/venue-qr-signage-examples) — copy to put next to the QR code. ## Build on it The [developer section](https://docs.belong.net/belong-checkin/developer/integration-overview) covers the [API](https://docs.belong.net/belong-checkin/developer/api-reference), [MCP tools](https://docs.belong.net/belong-checkin/developer/mcp-tools), [supported networks](https://docs.belong.net/belong-checkin/developer/networks), [POS and check-in webhooks](https://docs.belong.net/belong-checkin/developer/webhooks-and-pos), [NFT checkout for external stores](https://docs.belong.net/belong-checkin/developer/nft-checkout), and [enterprise whitelabel apps](https://docs.belong.net/belong-checkin/developer/enterprise-whitelabel). For contract-level detail, see the [Belong CheckIn Crypto Guide](https://docs.belong.net/guides/crypto/checkin) and [CheckIn MCP Tools](https://docs.belong.net/mcp/tools-check-in). ## Reference [Comprehensive Documentation](https://docs.belong.net/belong-checkin/whitepaper) is the whitepaper covering the platform, its economics, and the architecture behind it. # MCP Cheat Sheet ::doc-figure --- height: 450 width: 800 alt: A phone and robotic hand with the words Build Smarter Web3 Apps With MCP. caption: Use the backend MCP reference to find tool inputs, outputs, and signing requirements. placement: lead source-url: https://t.me/belongnet/275 src: https://docs.belong.net/media/social/mcp-assistants.webp --- :: Concise reference for the Belong API backend MCP resources and tools, including inputs and outputs. Use this as the backend reference after [connecting your MCP client](https://docs.belong.net/getting-started/mcp). The **auth resource** tells the client about its session, while tools accept structured inputs for a specific operation. Read the returned JSON inside the MCP response envelope rather than treating the envelope itself as the business result. ::note For external assistants and public AI connectors, use the CheckIn public assistant MCP at `https://join.belong.net/functions/v1/belong-agent-mcp/mcp` . It uses OAuth 2.1 with email-code sign-in, scoped permissions, audit logging, and Belong confirmation links for sensitive wallet or payment actions. :: ## Connection - Backend MCP server URL: `https://api.belong.net/mcp` - LLM manifest: `https://api.belong.net/api/v3/llms.txt` - Setup examples and endpoint selection guidance: see [MCP Integration](https://docs.belong.net/getting-started/mcp) ## Auth - Uses an API key sent with the `x-api-key` header — generate one via [Getting an API Key](https://docs.belong.net/getting-started/api-docs#getting-an-api-key) - Keep this endpoint in trusted developer tooling, backend services, or first-party integrations. Do not publish it as the OAuth assistant connector. ## Response Format - Tool success: `{ content: [{ type: "text", text: }] }` - Tool error: `{ isError: true, content: [{ type: "text", text: "" }] }` - Resource success: `{ contents: [{ uri, text: , mimeType: "application/json" }] }` ## Resources - get-auth-session - URI: `auth://session` - Input: none - Output: Better Auth session and user info (as JSON text) # MCP Tools — Addresses ::doc-figure --- height: 562 width: 800 alt: A gold location pin beside Check Address Before Launch. caption: Confirm the returned address and location before using them in event setup. The tool must first be registered on the MCP server. placement: lead source-url: https://t.me/belongnet/451 src: https://docs.belong.net/media/social/confirm-venue-address.webp --- :: Use address autocomplete to turn a typed location into candidate addresses before saving a venue or event. Start with at least two characters, then use the returned address details to confirm the intended location. This tool is not registered by default; see [Registration](https://docs.belong.net/mcp/tools-registration) before expecting a client to discover it. ## get-addresses-autocomplete - Input: `q` (min 2 chars) - Output: `{ data: Address[] }` with `id`, `title`, `formatted_address`, `description`, `location` # MCP Tools — CheckIn ::doc-figure --- height: 450 width: 800 alt: A glowing on-chain reward engine with the words App-Integrated On-Chain Rewards. caption: Prepare venue funding, payments, and reward operations through the documented CheckIn tools. placement: lead source-url: https://t.me/belongnet/250 src: https://docs.belong.net/media/social/contracts-on-chain-rewards.webp --- :: These backend tools support the venue funding and payment workflow. Use the [CheckIn crypto guide](https://docs.belong.net/guides/crypto/checkin) to follow the operation order, and this page to check individual inputs and outputs. A venue payment account is distinct from the owner's address, and prepared transactions still follow the documented signing flow. ## venue-deposit - Input: `{ chainId, ownerAddress, venueAddress, amount, rules: { paymentType, bountyType, bountyAllocationType, longPaymentType }, referralAddress?, toCustomerBounty: { visitBountyAmount, spendBountyPercentage }, toPromoterBounty: { visitBountyAmount, spendBountyPercentage }, dailyLimits?, hubId?, activityId?, gasless? }` - Note: `ownerAddress` must belong to the authenticated user. Ownership checks use `ownerAddress`, while transactions are prepared for `venueAddress`. - Note: If an existing venue record is already owned by another user, request is rejected with ownership error. - Note: `gasless` enables sponsorship eligibility checks for this venue. - Output: `{ address_token, address, venueAddress, params: [venueInfo, protection], method: { name: "venueDeposit", ... }, totalAmountToApprove }` - `venueInfo`: `{ rules, venue, amount, affiliateReferralCode, uri }` - `protection`: `{ nonce, deadline, signature }` - Note: `venue-deposit` is crypto-only and always returns signable transaction params for the venue deposit call. ## pay-to-venue - Input: `{ chainId, customer, venueToPayFor, promoter?, amount, paymentIn }` - Note: Requires authentication - customer address must be owned by authenticated user - Output: `{ address_token, address, params: [customerInfo, protection], method: { name: "payToVenue", ... } }` - `customerInfo`: `{ paymentInUSDtoken: boolean, toCustomer: { visitBountyAmount: string, spendBountyPercentage: string }, toPromoter: { visitBountyAmount: string, spendBountyPercentage: string }, customer: address, venueToPayFor: address, promoterReferralCode: bytes32, amount: string }` - `protection`: `{ nonce, deadline, signature }` ## distribute-promoter-payments - Input: `{ chainId, promoter, venue, paymentInUSDC }` - Output when the backend submits the sponsored transaction: `{ address, submitted: true, txHash, transactionStatus, signatureExpiresAt? }` - Output when the request falls back to client submission: `{ address, params: [promoterInfo, protection], method: { name: "distributePromoterPayments", ... } }` - `promoterInfo`: `{ paymentInUSDtoken: boolean, promoterReferralCode: bytes32, venue: address, amountInUSD: string }` - `protection`: `{ nonce, deadline, signature }` - Note: backend submission is used only when signer policy allows it and the venue sponsor has `gasless` enabled, `distribute_promoter_payments` allowed, and enough gas-bank balance. Otherwise the response remains client-submitted transaction params. - Note: clients must branch on `submitted: true`; do not assume `params` is always present. ## venue - Input: `{ address, chainId }` - Output: `{ venue, hubId?, activityId?, gasless, rules, remainingCredits, toCustomerBounty: { visitBountyAmount: number, spendBountyPercentage: number }, toPromoterBounty: { visitBountyAmount: number, spendBountyPercentage: number }, venueId, venueTokenBalance, usdTokenDeposits, longDeposits }` - Note: `venueTokenBalance` is the ERC-1155 venue credit balance. - Note: `usdTokenDeposits` and `longDeposits` are the current venue balances remaining in escrow. ## emergency-cancel-payment - Input: `{ chainId, venue, promoter }` - Output: currently returns a backend-disabled error - Note: The route is kept for compatibility, but server-side on-chain execution is temporarily disabled. ## update-venue-rules - Input: `{ chainId, venue, rules: { paymentType, bountyType, bountyAllocationType, longPaymentType }, toCustomerBounty: { visitBountyAmount, spendBountyPercentage }, toPromoterBounty: { visitBountyAmount, spendBountyPercentage } }` - Output: `{ address, params: [rules], method: { name: "updateVenueRules", ... }, venueId, toCustomerBounty: { visitBountyAmount, spendBountyPercentage }, toPromoterBounty: { visitBountyAmount, spendBountyPercentage } }` - Note: Updates database with validated bounty allocations and returns transaction parameters for blockchain update ## deploy-promoter - Input: `{ chainId, promoter }` - Output: `{ address, method: { name: "createReferralCode", ... } }` ## find-promoter - Input: `{ chainId, promoter }` - Output: `"success" | "failed"` ## update-venue-settings - Input: `{ ownerAddress, venueAddress, chainId, paymentType?, longPaymentType?, toCustomerBounty?: { visitBountyAmount, spendBountyPercentage }, toPromoterBounty?: { visitBountyAmount, spendBountyPercentage }, dailyLimits?, hubId?, activityId?, gasless? }` - Note: `ownerAddress` must belong to the authenticated user. Ownership checks use `ownerAddress`, while on-chain venue rules apply to `venueAddress`. - Note: If an existing venue record is already owned by another user, request is rejected with ownership error. - Note: All fields are optional, but at least one must be provided: paymentType, longPaymentType, toCustomerBounty, toPromoterBounty, dailyLimits, hubId, activityId, or gasless. - Note: `toCustomerBounty` / `toPromoterBounty` are optional and used when reward config needs to be changed. - Output (if rules changed): `{ venueAddress, chainId, venueId, gasless, rules: { paymentType, bountyType, bountyAllocationType, longPaymentType }, dailyLimits?, hubId?, activityId?, toCustomerBounty?: { visitBountyAmount, spendBountyPercentage }, toPromoterBounty?: { visitBountyAmount, spendBountyPercentage }, address, params: [rules], method: { name: "updateVenueRules", ... } }` - Output (if rules unchanged): `{ venueAddress, chainId, venueId, gasless, rules: { paymentType, bountyType, bountyAllocationType, longPaymentType }, dailyLimits?, hubId?, activityId?, toCustomerBounty?: { visitBountyAmount, spendBountyPercentage }, toPromoterBounty?: { visitBountyAmount, spendBountyPercentage } }` - Note: Replaces update-accepted-payments and update-rewards. Updates payments, rewards, and additional settings in a single call. Automatically determines bountyType and bountyAllocationType from bounty values. Updates database and on-chain rules (if changed). Returns transaction parameters only if rules changed. - Note: For `bountyType = Both (3)`, bounty values must be non-negative; active allocation can use visit, spend, or both. ## get-belong-check-in-storage - Input: `{ chainId }` - Output: `{ contracts: { factory, escrow, staking, venueToken, promoterToken, longPF }, paymentsInfo: { dexType, slippageBps, router, usdToken, long, maxPriceFeedDelay, poolKey, hookData }, fees: { referralCreditsAmount, affiliatePercentage, longCustomerDiscountPercentage, platformSubsidyPercentage, processingFeePercentage, buybackBurnPercentage }, helperContract, checkInContract }` # MCP Tools — Events ::doc-figure --- height: 562 width: 800 alt: An event tool illustration with the words Create Events Through MCP. caption: Structured event tools let a connected client work with event records without navigating the dashboard. placement: lead source-url: https://t.me/belongnet/459 src: https://docs.belong.net/media/social/create-events-through-mcp.webp --- :: Use these tools when an assistant or backend integration needs structured event operations. For example, retrieve an event by its slug or ID before updating its allowed fields. The tools manage event records and media; the [Event Creation guide](https://docs.belong.net/belong-checkin/event-creation) explains the organizer-facing ticket setup. ## get-event - Input: `id` (slug or MongoId) - Output: event object (JSON text) ## list-events - Input: `category?`, `online?`, `private?`, `sort?`, `order?`, `search?`, `fields?`, `cursor?`, `take?`, `skip?` - Output: array of events (JSON text) ## create-event - Input: CreateEventsBody (no `id`, `media`; `owner` optional) - Output: created event (JSON text) ## update-event - Input: `id`, `data` (UpdateEventsBody; partial, critical fields excluded) - Output: updated event (JSON text) ## delete-event - Input: `id` - Output: deleted event (JSON text) ## add-event-media - Input: `id`, `files[]` of `{ base64, filename? }` - Output: array of media assets (JSON text) ## update-event-media - Input: `id`, `media` (array of media IDs in desired order) - Output: reordered media array (JSON text) ## delete-event-media - Input: `id`, `mediaId` - Output: updated media array (JSON text) # MCP Tools — Hubs ::doc-figure --- height: 562 width: 800 alt: An event organizer with the words Create the Hub, Place the Event. caption: Create the hub that groups your venue or community information before adding its events. placement: lead source-url: https://t.me/belongnet/446 src: https://docs.belong.net/media/social/create-hub-place-event.webp --- :: A **hub** groups a venue or community's information in Belong. Use these tools to retrieve the right hub or create its record before adding related content. For connecting an existing event to a hub, follow the additive update pattern in [Integration Overview](https://docs.belong.net/belong-checkin/developer/integration-overview#connecting-events-to-a-hub). ## get-hub - Input: `id` (slug or MongoId) - Output: hub object (JSON text) ## list-hubs - Input: `hubType?`, `status?`, `source?`, `private?`, `ownerId?`, `memberId?`, `search?`, `sort?`, `order?`, `fields?` (string [] ), `limit?`, `page?`, `cursor?` - Output: `{ data: Hub[], meta: { pagination } }` (JSON text) ## related-hubs - Input: `id`, `withMarkers?`, `limit?`, `page?`, `cursor?` - Output: `{ data: RelatedHub[], meta: { pagination } }` (JSON text) ## create-hub - Input: CreateHubBody (requires `name` + unique `slug`; `slug` maps to DB `hubname`; owner inferred from auth; `source` forced to MCP) - Output: created hub (JSON text) ## update-hub - Input: `id`, `data` (UpdateHubBody; partial) - Output: updated hub (JSON text) ## delete-hub - Input: `id` - Output: `{ message }` (JSON text) # MCP Tools — EVM Minting ::doc-figure --- height: 450 width: 800 alt: A purple minting machine beside the words Just Mint It. caption: Create a collection, prepare the mint, and sign the transaction using the selected chain's workflow. placement: lead source-url: https://t.me/belongnet/67 src: https://docs.belong.net/media/social/mint-digital-assets.webp --- :: Use this reference for the EVM collection and NFT minting tools. **Deploy** creates the collection contract; **mint** issues NFTs from a collection. Follow the [EVM minting guide](https://docs.belong.net/guides/crypto/minting) for the preparation, wallet-signing, and completion sequence around these calls. ## deploy-collection **Description:** Prepares a new ERC-721/1155 NFT collection deployment. Returns unsigned `produce()` calldata. No database collection is created until `complete-collection` confirms the deployment transaction. - **Input:** ```ts { name: string, // Collection name symbol: string, // Collection symbol (no spaces allowed) description?: string, // Description feeNumerator: number, // Royalty % (max 6) mintPrice: number, // Mint price in human-readable format (e.g., 1 for $1, 0.5 for $0.50) whitelistMintPrice: number, // Whitelist mint price in human-readable format (e.g., 0.3 for $0.30) transferable: boolean, // NFT transferability maxTotalSupply: number, // Max NFT count paymentToken: 'NATIVE' | 'USDC' | 'BUSD', // Payment token ('NATIVE' for chain native token, 'USDC' or 'BUSD' for stablecoin) creator: string, // Creator wallet address chainId: number, // EVM chain ID externalUrl: string | null, // External link attributes?: Array<{ trait_type: string, display_type?: string, value: string }>, referralCode?: string // Optional referral code } ``` - **Output:** ```ts { params: [{ creator: string, // Creator wallet address paymentToken: string, // Resolved token address (0xEee... for NATIVE or USDC/BUSD contract) feeNumerator: number, transferable: boolean, maxTotalSupply: number, mintPrice: string, // Price in wei/token units whitelistMintPrice: string, // Whitelist price in wei/token units metadata: { name: string, symbol: string }, contractURI: string }, "0x0...", { nonce: number, deadline: number, signature: string }], verifyingContract: string, // Address of the verifying contract method: object, // ABI-encoded method details for the transaction } ``` ## complete-collection **Description:** Finalizes collection deployment after broadcast and creates or updates the database collection from the confirmed transaction. `gasless: true` marks the collection as eligible for sponsorship checks, but the sponsorship balance itself is managed separately through `/api/v3/sponsorship/*`. See [Sponsored Gas Ledger Guide](https://docs.belong.net/guides/crypto/sponsorship). - **Input:** ```ts { chainId: number, hash: string, // Deployment transaction hash hubId?: string, activityId?: string, gasless?: boolean, whitelist_hubIDs?: string[], whitelist_userIDs?: string[] } ``` - **Output:** Created or updated collection object. Use the returned `id` as `collectionId` for minting, media uploads, and checkout flows. The backend reconstructs the collection from the deployment transaction calldata and receipt. It verifies the configured NFT factory and the authenticated creator wallet before saving. ## evm-mint **Description:** Prepares batched NFT mint with dynamic pricing and metadata. Crypto mint only. - **Input:** ```ts { collectionId: string, chainId: number, walletAddress: string, // Minter's wallet address nfts: Array<{ receiver: string, // Receiver address for this NFT (where the NFT will be sent) name: string, description: string, mintPrice: number, // Price in human-readable format (e.g., 1 for $1, 0.5 for $0.50) quantity: number, image?: string, attributes?: Array<{ trait_type: string, display_type?: string, value: string }>, external_url?: string, animation_url?: string, youtube_url?: string }> } ``` - **Output:** ```ts { chainId: number, verifyingContract: string, // Collection contract address method: object, // ABI-encoded method details for the transaction params: [ string, // Payment token address (0xEee... for NATIVE or USDC/BUSD contract address) Array, // Receivers array - one address per NFT Array<{ // DynamicPriceParameters array - one per NFT tokenId: bigint, // Token ID (bigint format) price: bigint, // Price in wei/token units (bigint format) tokenUri: string // Metadata URI }>, Array<{ // SignatureProtection array - one per NFT nonce: bigint, // Nonce for replay protection deadline: bigint, // Expiration timestamp signature: string // ECDSA signature (hex format, 0x...) }> ], tokens: Array<{ token_id: string, token_uri: string, minted_price: number, name: string, image?: string, attributes?: Array<{...}>, description?: string, external_url?: string, animation_url?: string, youtube_url?: string }> } ``` :br**Important:** All arrays (`receivers`, `dynamicPriceParameters`, `protections`) must have the same length and be synchronized by index. Element at index `i` in each array corresponds to the same mint operation. The signature in `protections[i]` is generated for the parameters in `dynamicPriceParameters[i]` and `receivers[i]`. :br Use `mintDynamicPrice` function to execute the mint: ```solidity mintDynamicPrice( address expectedPayingToken, address[] calldata receivers, DynamicPriceParameters[] calldata dynamicPriceParameters, SignatureProtection[] calldata protections ) external payable ``` :brWhere `DynamicPriceParameters` is `(uint256 tokenId, uint256 price, string tokenUri)` and `SignatureProtection` is `(uint256 nonce, uint256 deadline, bytes signature)`. ## mint-complete **Description:** Finalizes mint, saves tokens to user inventory. - **Input:** ```ts { chainId: number, hash: string // Mint transaction hash } ``` - **Output:** Array of saved NFTs The backend reconstructs `collectionId`, `walletAddress`, and token data from the mint transaction calldata, receipt logs, and token metadata URI. All minted receivers must belong to the authenticated user on the same chain. ## create-referral-code **Description:** Returns transaction data to create a referral code for a promoter. Auth required. - **Input:** ```ts { chainId: number; // EVM chain ID } ``` - **Output:** `{ address: string, method: { name: "createReferralCode", ... } }` ## get-referral-code-by-creator **Description:** Retrieves the referral code for a given wallet address. Returns `zeroHash` if no valid code exists. No auth required. - **Input:** ```ts { chainId: number, // EVM chain ID walletAddress: string // Creator wallet address } ``` - **Output:** `{ referralCode: string }` — bytes32 hash > **Note:** Auth required for `complete`, `checkout`, `create-referral-code`. Gasless on SKALE. # MCP Tools — Notes ::doc-figure --- height: 562 width: 800 alt: An open field-note case with the words Log It On Site. caption: Record a changed entrance or vendor arrival time as a note associated with the relevant hub. placement: lead source-url: https://t.me/belongnet/473 src: https://docs.belong.net/media/social/shared-venue-notes.webp --- :: Use notes to keep operational details with the relevant hub, such as a changed entrance or vendor arrival time. A connected client can create a note during a walk-through, then retrieve or search it when planning resumes. Use the existing note ID to update that record instead of creating another copy. ## Tools — Notes ## get-note - Input: `id` - Output: note (JSON text) ## list-notes - Input: `hubId?`, `userId?`, `search?`, `take?`, `skip?`, `cursor?`, `sort?`, `order?` - Output: array of notes (JSON text) ## create-note - Input: CreateNotesBody (no `id`, timestamps; `userId` optional) - Output: created note (JSON text) ## update-note - Input: `id`, `data` (UpdateNotesBody; partial, cannot change `hubId`/`createdAt`) - Output: updated note (JSON text) ## delete-note - Input: `id` - Output: deleted note (JSON text) # MCP Tools Registration ::doc-figure --- height: 450 width: 800 alt: A phone labeled MCP Integration beside Your Community, Run by AI. caption: Register tool definitions and handlers on the backend MCP server before exposing them to clients. placement: lead source-url: https://t.me/belongnet/241 src: https://docs.belong.net/media/social/community-ai-operations.webp --- :: This page is for developers configuring the backend MCP server. **Registration** means making a tool available for clients to discover and call; it does not mean adding an attendee to an event. A tool can exist in the codebase without being exposed by the running server. ::mermaid ```text flowchart TD accTitle: Registering backend MCP tools accDescr: The server registers tool families, then clients discover and call only the exposed tools. A[Start the backend MCP server] --> B[Register the selected tool families] B --> C[Client discovers exposed tools] C --> D[Client calls a registered tool] ``` :: An unregistered tool will not appear just because its implementation exists. Addresses require the explicit registration call shown below; attendee enrollment is a separate product operation. ## Registration - Registered in MCP server: Auth resource, Events, Notes, Hubs, Sui, Starknet - Not registered (available to add): Addresses — register via `registerAddressesTools(server)` # MCP Tools — Starknet (Crypto) ::doc-figure --- height: 450 width: 800 alt: Starknet and Belong logos with the words Grant Recipient. caption: Starknet collection deployment and minting use their own chain-specific tooling, separate from EVM operations. placement: lead source-url: https://t.me/belongnet/58 src: https://docs.belong.net/media/social/starknet-ecosystem.webp --- :: Use these tools for Starknet NFT collection deployment and minting. Keep the returned collection and transaction identifiers through the completion calls, and follow the [Starknet guide](https://docs.belong.net/guides/crypto/starknet) for account and signing requirements. These calls are separate from the EVM minting tool family. All Starknet tools are **network-aware**. Pass the same `data.network` value through the full lifecycle (`starknet-deploy-collection -> starknet-complete-deploy -> starknet-mint-nft -> starknet-complete-mint`). Supported values are `"SN_MAIN"` and `"SN_SEPOLIA"`, and the connected wallet must be on the same network. ## starknet-deploy-collection **Description:** Deploy a collection. As a result of executing this command, you will receive a transaction that needs to be signed and sent to the blockchain. **Input:** `data` (ProduceInfo) ```typescript { name: string, // Collection name (required, min 1 char, cannot be empty/whitespace) symbol: string, // Collection symbol (required, min 1 char, cannot contain spaces) description?: string, // Optional description feeNumerator: number, // Royalty numerator in percentage (0-8, e.g., 8 = 8%) transferable: boolean, // Whether NFT can be transferred maxTotalSupply: number, // Maximum NFT count mintPrice: number, // Base price per mint (human amount, e.g., 2, 0.5) whitelistMintPrice: number, // Discounted price for whitelisted minters (human amount) paymentToken: "STRK"|"ETH"|"USDC", // Payment token creator: string, // Creator wallet address (Starknet address format) externalUrl?: string | null, // Optional external website/app link referralCode?: string, // Optional referral code network: "SN_MAIN"|"SN_SEPOLIA" // Target Starknet network } ``` **Output:** Transaction calls to sign (JSON text) ```typescript { calls: [ { contractAddress: string, // Factory contract address entrypoint: "produce", // Entrypoint name calldata: any[] // Compiled calldata } ] } ``` **Note:** Returns an object `{ calls: [...] }` (usually with one call). After executing the transaction, use the transaction hash with `starknet-complete-deploy` MCP tool to finalize collection creation in the database. ## starknet-complete-deploy **Description:** Finalizes collection deployment after broadcast. Validates the deployment transaction receipt and creates or refreshes the collection record in the database. When `activityId` or `hubId` is provided, the linked entity is published with `passStrategy: STATIC` to enable QR pass flow. **Input:** ```typescript { hash: string, // Transaction hash from deploy step (required, non-zero) gasless?: boolean, // Enable gasless transactions (optional) hubId?: string | null, // Optional hub ID for whitelisting activityId?: string | null, // Optional activity ID whitelist_hubIDs?: string[], // Array of hub IDs for whitelist (optional) whitelist_userIDs?: string[], // Array of user IDs for whitelist (optional) attributes?: [ // Default attributes for NFTs (optional) { trait_type: string, display_type?: "string" | "number" | "date" | "boost_number" | "boost_percentage", // Optional, defaults to "string" value: string } ], network: "SN_MAIN"|"SN_SEPOLIA" // Same network used during deploy } ``` **Output:** Updated collection object (JSON text) ```typescript { // NftCollection object with all collection data id: string, contractAddress: string, // ... other collection fields } ``` ## starknet-mint-nft **Description:** Mint an NFT. As a result of executing this command, you will receive a transaction that needs to be signed and sent to the blockchain. **Input:** `data` (MintInfo) ```typescript { collection_address: string, // Created collection address items: [ { receiver: string, // NFT receiver address name: string, // NFT name description: string, // NFT description price: string, // Human amount string (e.g. "0.2") - backend converts to u256 base-units by token decimals quantity: number, // Number of copies image?: string, // NFT image URL externalUrl?: string, // External link animation_url?: string, // Animation URL attributes?: [ // NFT attributes { trait_type: string, value: string } ] } ], network: "SN_MAIN"|"SN_SEPOLIA" // Same network used during deploy } ``` **Output:** Transaction calls to sign (JSON text) ```typescript { calls: [ { contractAddress: string, entrypoint: string, calldata: any[] } ] } ``` **Note:** - Before minting NFTs, you must approve the collection contract to spend the required amount of payment tokens on your behalf. Token contract addresses depend on the selected `network`. See the [Starknet NFT Minting Guide](https://docs.belong.net/guides/crypto/starknet) for details. - Returns an object `{ calls: [...] }`. After executing the transaction, use the transaction hash with `starknet-complete-mint` MCP tool to parse the receipt and create NFT records in the database. ## starknet-complete-mint **Description:** Parses the mint transaction receipt, extracts minted NFT information (token IDs, receivers), fetches metadata from `tokenUri`, calculates `minted_price`, and creates NFT records in the database. It also returns the minter Starknet wallet in `cryptoAddress` response field without persisting Starknet wallet addresses in `crypto_addresses`. **Input:** `data` ```typescript { hash: string, // Transaction hash from mint step (required) network: "SN_MAIN"|"SN_SEPOLIA" // Same network used during mint } ``` **Output:** Array of NFT records (JSON text) ```typescript [ { id: string, name: string, hash: string, address: string, block_number: string | null, token_id: string, token_uri: string | null, image: string | null, userId: string, minted_price: number | null, attributes: [ { trait_type: string, display_type?: "string" | "number" | "date" | "boost_number" | "boost_percentage", value: string } ] | null, cryptoAddress: { address: string }, receiver: string | null, serialNumber?: string } ] ``` **Note:** - Automatically parses `Transfer` events from the transaction receipt to identify minted NFTs and the actual NFT contract - Fetches and parses metadata from `tokenUri` (supports JSON strings, HTTP/HTTPS URLs, and Data URIs) - Creates NFT records in DB during `starknet-complete-mint`; repeat calls for the same transaction are not intended as the primary flow - `starknet-complete-deploy` and `starknet-complete-mint` must be called with the same `network` value that was used for the original transaction - Extracts metadata fields: `name`, `image`, `description`, `external_url`, `animation_url`, and `attributes` - If the collection is linked to an `activityId` or `hubId`, QR passes are created during NFT persistence and QR emails use Voyager links for Starknet # MCP Tools — Vesting ::doc-figure --- height: 450 width: 800 alt: LONG tokens beside the words Why the LONG token matters. caption: LONG vesting schedules define when an allocation becomes available to its beneficiary. placement: lead source-url: https://t.me/belongnet/164 src: https://docs.belong.net/media/social/long-token-utility.webp --- :: Use this reference to prepare a LONG vesting-wallet deployment with a beneficiary and release schedule. The tool returns transaction data for signing; it does not broadcast the deployment. See the [Vesting guide](https://docs.belong.net/guides/crypto/vesting) for the sequence from deployment through token release. ## deploy-vesting-wallet **Description:** Returns transaction parameters for deploying a time-locked vesting contract for LONG tokens. The transaction must be executed on the frontend by the user's wallet. The user must have sufficient LONG tokens and approve the factory contract before calling this tool. **Important Requirements:** - User's wallet (`walletAddress`) must have at least `totalAllocation` LONG tokens - User's wallet must approve the factory contract for `totalAllocation` amount - The transaction is executed on the frontend, not by the backend - Backend only provides the signature and transaction parameters - **Input:** ```ts { vestingWalletInfo: { startTimestamp: number, // Start time of vesting (Unix timestamp) cliffDurationSeconds: number, // Cliff period duration in seconds durationSeconds: number, // Total vesting duration in seconds beneficiary: string, // Address receiving vested tokens totalAllocation: number, // Total tokens to vest (human-readable format, e.g., 2 for 2 tokens) tgeAmount: number, // Tokens released at TGE (human-readable format, e.g., 0.5) linearAllocation: number, // Tokens released linearly (human-readable format, e.g., 1.5) description: string, // Description of vesting contract // Note: token address is automatically resolved from LONG token on the specified chain }, chainId: number, // EVM chain ID walletAddress: string, // User's wallet address (will be owner and msg.sender) } ``` - **Output:** ```ts { address: string, // Factory contract address address_token: string, // LONG token address method: object, // ABI method details for deployVestingWallet params: [ // Transaction parameters string, // walletAddress (owner) { startTimestamp: string, // Start timestamp (BigInt as string) cliffDurationSeconds: string, // Cliff duration (BigInt as string) durationSeconds: string, // Duration (BigInt as string) token: string, // Token address beneficiary: string, // Beneficiary address totalAllocation: string, // Total allocation (BigInt as string, in wei) tgeAmount: string, // TGE amount (BigInt as string, in wei) linearAllocation: string, // Linear allocation (BigInt as string, in wei) description: string, // Description }, { nonce: string, // Signature nonce (BigInt as string) deadline: string, // Signature deadline (BigInt as string) signature: string, // Backend signature (hex string) } ], totalAllocationApprove: string, // Total allocation in wei (for approve check) } ``` > **Note:** > > - The response contains transaction parameters that must be executed on the frontend > - All BigInt values are converted to strings for JSON compatibility > - The backend creates a signature, but the transaction is sent from the user's wallet > - The user's wallet must have tokens and approve before executing the transaction > **Important:** > > - Token amounts (`totalAllocation`, `tgeAmount`, `linearAllocation`) should be specified in human-readable format (e.g., `2` for 2 tokens). The system automatically converts them to wei (18 decimals) for LONG tokens. > - The `token` field is automatically resolved from the LONG token address on the specified chain and should not be included in the request. > - Requires admin authentication (`UserRole.admin`). > - **User Requirements:** The `walletAddress` must have at least `totalAllocation` LONG tokens and must approve the factory contract. > - **Transaction Execution:** The transaction is executed on the frontend from the user's wallet, not by the backend. > - **Allocation Balance:** `tgeAmount + linearAllocation + tranches` must equal `totalAllocation` before finalization. # Belong AI Deploy ::doc-figure --- height: 583 width: 800 alt: The AI Deploy by Belong logo on a dark violet background. caption: Deploy and operate an AI agent on your own cloud using the supported providers and channels. placement: lead source-url: https://t.me/belongnet/403 src: https://docs.belong.net/media/social/ai-deploy-by-belong.webp --- :: ## Overview **Belong AI Deploy** sets up a private AI agent that runs on **your own cloud account**. Connect it to Telegram, WhatsApp, Slack, or another supported channel, then operate it through a Tailscale-private dashboard. You keep the infrastructure, data, and AI-provider relationship under your control. Start here to understand the ownership model before choosing a setup path. Your cloud account supplies the server, your AI provider supplies the model, and your chosen messenger supplies the conversation surface. The private dashboard is where you manage the deployment after launch. Choose the path that fits how you work: - **Guided hosted setup:** [Launch at aideploy.co](https://aideploy.co) with provider sign-ins, a visual deployment flow, and managed operations. - **Open-source self-hosting:** [Explore `belongnet/aideploy` on GitHub](https://github.com/belongnet/aideploy) for the public CLI, runtime stack, OpenTofu modules, lifecycle tools, and source. ::note The hosted path is designed for setup without a terminal. The public self-host beta is a developer path and currently uses a source checkout plus four credentials. See [Open Source](https://docs.belong.net/ai-deploy/open-source) for the exact boundary and support matrix. :: ::mermaid ```text flowchart TD accTitle: The AI Deploy setup lifecycle accDescr: Choose a setup path and cloud, connect AI and messaging, launch the server, then open the private dashboard and test the agent. A[Choose hosted setup or self-hosting] --> B[Configure your cloud account] B --> C[Connect AI and messaging] C --> D[Launch on your server] D --> E[Open private dashboard and test] ``` :: The hosted wizard and the public self-host beta have different setup requirements and support matrices. On either path, the server belongs to your cloud account; a test conversation confirms that the channel and AI connection are ready. ## The guided hosted deploy 1. **Sign in with DigitalOcean** — one click, your server is ready 2. **Sign in with ChatGPT** — one click, your AI is connected 3. **Connect Telegram** — paste one token 4. **Click Launch** — your agent is live in about 60 seconds See the [Quick Start](https://docs.belong.net/ai-deploy/quickstart) for the step-by-step walkthrough. ## How it works ::mermaid ```text flowchart LR; subgraph You[Your devices] D[Phone / Laptop
Tailscale] end subgraph Cloud[Your cloud server] DASH[Dashboard] AG[AI Agent] GW[Gateway] DB[(Private memory DB)] AG --- GW AG --- DB DASH --- DB end M[Telegram / WhatsApp / Slack] D -- private network --> DASH M -- optional webhooks --> GW ``` :: - Your **dashboard and agent are private** — reachable only through your own [Tailscale](https://docs.belong.net/ai-deploy/private-access) network, not the public internet. - **Messaging webhooks are optional** and, when enabled, only open a single HTTPS route for the channel you chose. - Your agent stores **long-term memory** in its own private database, so it remembers context across conversations. ## Hosted support ### Cloud | Provider | Auth | New deployments | | ---------------------- | ---------------- | ------------------------------------- | | DigitalOcean (default) | OAuth | Active | | OVHcloud | Signed API token | Active; production control plane | | Google Cloud | OAuth | Active beta | | AWS | API key | Active beta | | Scaleway | API key | Active beta | | Microsoft Azure | — | Disabled; retained compatibility only | See [Cloud Providers](https://docs.belong.net/ai-deploy/cloud-providers) for details. ### AI | Provider | Auth | Default model | | ----------------- | ------- | -------------------- | | ChatGPT (default) | OAuth | GPT-5.5 | | Claude | OAuth | Claude Opus 4.8 (1M) | | Gemini | API key | Gemini 3 Deep Think | | Kimi | API key | Kimi K2.6 | Image generation and voice-note transcription ship preconfigured. See [AI Providers](https://docs.belong.net/ai-deploy/ai-providers). ### Agent runtimes | Runtime | Shape | Status | | ---------------------- | --------------------------------------- | ------ | | Hermes Agent (default) | Lean single-agent runtime | Beta | | OpenClaw | Multi-agent gateway and browser runtime | Beta | Both runtimes are available in the [public repository](https://github.com/belongnet/aideploy) and the hosted wizard. Their channel support differs; the wizard shows only compatible combinations. ### Messaging | Platform | Setup time | | ------------------ | ---------- | | Telegram (default) | \~30 sec | | Slack | \~3 min | | WhatsApp | \~5 min | See [Channels](https://docs.belong.net/ai-deploy/channels/telegram). ## What you can do after deploy Once your agent is live, open the management dashboard over your private network to: - **Chat & review** — read every conversation in a threaded view, search, and star important ones - **Automate with tasks** — trigger actions on keywords, schedules, or webhooks (welcome greetings, FAQ auto-replies, daily summaries, and more) - **Tune your agent** — set its personality/system prompt, switch models, and manage conversation cleanup - **Run more agents** — deploy multiple independent agents on one server, each with its own model and channels ## Server sizes & cost | Plan | Agents | Approx. cost | Specs | | ------- | ------ | ------------ | ----------------- | | Starter | 1–4 | \~$24/mo | 2 vCPU, 4 GB RAM | | Growing | 5–8 | \~$48/mo | 4 vCPU, 8 GB RAM | | Power | 9–16 | \~$96/mo | 8 vCPU, 16 GB RAM | Most people should start with **Starter** — you can resize later from your cloud provider's dashboard. Your AI usage is billed by your provider (or covered by your existing subscription when you use OAuth). ## Deploying programmatically Teams that want automation instead of the sign-in wizard can provision agents with a REST API or a local MCP server (deploy from CI, manage a fleet from your editor, or batch-launch an agent per customer). See [Enterprise & API](https://docs.belong.net/ai-deploy/enterprise-api). ## Next steps - [Quick Start](https://docs.belong.net/ai-deploy/quickstart) — deploy your first agent - [Open Source](https://docs.belong.net/ai-deploy/open-source) — self-host from the public repository - [Cloud Providers](https://docs.belong.net/ai-deploy/cloud-providers) — choose where it runs - [AI Providers](https://docs.belong.net/ai-deploy/ai-providers) — choose its brain - [Private Access](https://docs.belong.net/ai-deploy/private-access) — reach your dashboard securely - [Enterprise & API](https://docs.belong.net/ai-deploy/enterprise-api) — programmatic deployment via REST API or MCP - [Troubleshooting](https://docs.belong.net/ai-deploy/troubleshooting) — fix common issues # Open Source ::doc-figure --- height: 583 width: 800 alt: The AI Deploy by Belong logo on a dark violet background. caption: Use the public source, CLI, and infrastructure modules to operate your own deployment. placement: lead source-url: https://t.me/belongnet/403 src: https://docs.belong.net/media/social/ai-deploy-by-belong.webp --- :: ## Open Source The public aideploy source is at [`github.com/belongnet/aideploy`](https://github.com/belongnet/aideploy). Choose self-hosting when you want to work from the source and operate the deployment lifecycle yourself. Start with the documented DigitalOcean and Telegram path, then check the support matrix before substituting another provider or channel. Hosted wizard capabilities and public CLI capabilities are tracked separately. It is the deployment and operations foundation for private OpenClaw and Hermes Agent installations: lifecycle CLI, runtime assets, OpenTofu modules, readiness proof, backups, upgrades, diagnostics, teardown, and public contracts. ::u-button --- target: _blank to: https://github.com/belongnet/aideploy trailing-icon: i-lucide-external-link --- View the public repository :: ## Public self-host or hosted platform? ### Public self-host beta Choose this when source access and local lifecycle control matter most. - **Setup:** tagged source checkout and local CLI - **Cloud:** DigitalOcean golden path - **Runtime:** OpenClaw or Hermes Agent - **AI:** OpenAI, Anthropic, or Kimi API key - **Messaging:** Telegram - **Scale:** one deployment at a time - **Operations:** local status, VM backup, blue/green upgrade, and teardown - **Network:** Tailscale-private browser and runtime ### Hosted + managed platform Choose this for guided setup, teams, agencies, fleets, and managed operations. - **Setup:** guided web wizard and API - **Cloud:** DigitalOcean, OVHcloud, Google Cloud, AWS, and Scaleway - **Runtime:** OpenClaw or Hermes Agent - **AI:** ChatGPT and Claude connection flows plus OpenAI, Anthropic, Gemini, Kimi, and DeepSeek keys - **Messaging:** eight OpenClaw channels; Telegram and WhatsApp beta bridge for Hermes - **Scale:** 1–16 agents, isolated workspaces, and virtual-office presets - **Operations:** Command Center, monitoring, offsite backup, managed updates, REST API, and MCP - **Network:** the same private data plane, plus signed webhook ingress only when required Microsoft Azure is not a new-deployment path in either column. Public Azure files are retained as validation/reference contracts, and hosted Azure code is retained only for compatibility with existing resources. ## What the public beta proves The public golden path is **DigitalOcean + Telegram**, using either OpenClaw or Hermes Agent and an OpenAI, Anthropic, or Kimi API key. A successful `up` does more than create a VM. It waits for the selected runtime, AI path, Telegram path, and private HTTPS browser surface to become usable. It also: - keeps runtime ports on loopback and exposes them through Tailscale HTTPS - limits Telegram access to the numeric owner ID you provide - pins runtime inputs and verifies downloaded OpenTofu checksums - tags resources so `doctor` can find orphans even when local state is damaged - stores local access material with mode `0600` - performs deterministic teardown and scrubs secrets after success Follow the repository's [self-host guide](https://github.com/belongnet/aideploy#self-host-in-your-own-cloud) for the current release command and prerequisites. ## Releases and supply-chain verification Public releases include deterministic source archives, manifests, SHA-256 values, and keyless Sigstore bundles. Runtime images are published by digest and signed from the repository's release workflow. - [Latest releases](https://github.com/belongnet/aideploy/releases) - [Security policy and private reporting](https://github.com/belongnet/aideploy/security/policy) - [Project history and provenance](https://github.com/belongnet/aideploy/blob/main/docs/project-history.md) Always use the verification command shipped with the release you deploy; do not copy a digest from an older guide. ## Licensing The deployed stack, OpenTofu modules, and contracts are Apache-2.0. The `cli/` directory uses FSL-1.1-ALv2: it is free to use, modify, and self-host, while competing managed-service use is restricted for two years per release before that release converts to Apache-2.0. Read the repository's [licensing section](https://github.com/belongnet/aideploy#licensing) and [`cli/LICENSE.md`](https://github.com/belongnet/aideploy/blob/main/cli/LICENSE.md) before redistribution. ## Build with us Contributions that shorten the path from clone to a real agent reply, strengthen safety, or graduate another provider into the live CLI are welcome. - [Contribution guide](https://github.com/belongnet/aideploy/blob/main/CONTRIBUTING.md) - [Issue tracker](https://github.com/belongnet/aideploy/issues) - [Public roadmap and support matrix](https://github.com/belongnet/aideploy#full-platform-support-matrix) For the fastest managed path, return to the [Quick Start](https://docs.belong.net/ai-deploy/quickstart). For the hosted cloud matrix, see [Cloud Providers](https://docs.belong.net/ai-deploy/cloud-providers). # Quick Start ::doc-figure --- height: 583 width: 800 alt: The AI Deploy by Belong logo on a dark violet background. caption: Connect your cloud, AI provider, and messenger, then launch and test your first conversation. placement: lead source-url: https://t.me/belongnet/403 src: https://docs.belong.net/media/social/ai-deploy-by-belong.webp --- :: ## Quick Start Pick one setup path. Both run the agent in your cloud account; the difference is who operates the deployment layer. The goal is a working conversation with an agent on your own server. Choose the hosted wizard or the public self-host beta first, then gather the credentials required by that path. After launch, send a test message and use the private dashboard to finish any remaining provider or channel setup. | Path | Best for | Start here | | --------------------- | ------------------------------------------------------------------------ | ------------------------------------------------------------- | | Guided hosted setup | Fast launch, more providers and channels, managed operations | [aideploy.co](https://aideploy.co) | | Public self-host beta | Source control, local lifecycle CLI, DigitalOcean + Telegram golden path | [`belongnet/aideploy`](https://github.com/belongnet/aideploy) | ## Guided hosted setup 1. **Go to** [aideploy.co](https://aideploy.co) 2. **Sign in with DigitalOcean** — click the button, authorize, done (\~10 seconds) 3. **Sign in with ChatGPT** — click the button, authorize, done (\~10 seconds) 4. **Connect Telegram** — paste your BotFather token (\~30 seconds) 5. **Click "Launch My Agent"** — wait for the progress bar to finish (\~60–90 seconds) 6. **Done!** — your agent is live. Send it a message on Telegram. ## What you need - A [DigitalOcean](https://m.do.co/c/af624a5e3198) account (credit card required for billing; eligible new accounts can receive a $200 / 60-day referral credit) - A [ChatGPT](https://chat.openai.com/) account (Plus or Pro recommended) - A [Telegram](https://telegram.org/) account - A [Tailscale](https://tailscale.com/) account (free) for private dashboard access You can swap any of these for another [cloud provider](https://docs.belong.net/ai-deploy/cloud-providers), [AI provider](https://docs.belong.net/ai-deploy/ai-providers), or [messaging channel](https://docs.belong.net/ai-deploy/channels/telegram). ## Open-source self-host setup The public beta supports: - DigitalOcean as the live cloud path - OpenClaw or Hermes Agent - OpenAI, Anthropic, or Kimi with an API key - Telegram with outbound polling - A Tailscale-private browser surface Start with the repository's [self-host guide](https://github.com/belongnet/aideploy#self-host-in-your-own-cloud). It gives you the current tagged-source command, required credentials, checksum-pinned OpenTofu setup, readiness checks, and deterministic teardown. The short lifecycle is: ```bash node cli/dist/index.js up node cli/dist/index.js doctor node cli/dist/index.js down ``` The public CLI validates every prerequisite before creating billable resources. It records state under `~/.aideploy//`, reports when the real runtime and Telegram path are ready, and removes secrets and infrastructure during a successful teardown. See [Open Source](https://docs.belong.net/ai-deploy/open-source) for the public-versus-managed feature boundary, licensing, release verification, and contribution links. ## After deployment - **Open your dashboard** — reach the management dashboard over your [Tailscale private network](https://docs.belong.net/ai-deploy/private-access) (`:3000`), select your agent, then go to **Connect AI & Messengers**. - **Finish setup from chat** — once the bot is replying in Telegram, you can finish any remaining provider or channel setup right there. Ask it to connect ChatGPT or Claude, open the sign-in link it sends, then paste the code back to the bot. It deletes that sensitive message when possible. - **Add more agents** — go to **Agents** and click **New Agent** to deploy additional agents. - **Install Tailscale** — add the Tailscale app to your phone or laptop to reach the dashboard from anywhere. - **Test it** — confirm Telegram is connected in the setup checklist, then send a message to your bot. ## Estimated costs - DigitalOcean server: \~$24–30/month (Starter plan, 2 vCPU / 4 GB RAM) - ChatGPT: included in your existing subscription when you sign in with OAuth - Tailscale: free for personal use ## Security note ::warning Never paste API keys or OAuth bearer tokens directly into chat. :: When you finish ChatGPT or Claude sign-in from a messenger, the bot sends a browser sign-in link. **Copy that link into Safari, Chrome, or your normal desktop browser** — messenger in-app browsers cannot finish the login reliably. Paste back the ChatGPT sign-in code (or the Claude redirect URL / one-time code) the browser shows you. For raw provider API keys, use the dashboard's secure setup forms instead of pasting keys into chat. ## Need help? - Check the [Troubleshooting guide](https://docs.belong.net/ai-deploy/troubleshooting) - Review the deployment logs in the **Technical details** section of the wizard - For source installs, run `node cli/dist/index.js doctor` and use the repository's [issue tracker](https://github.com/belongnet/aideploy/issues) # Cloud Providers ::doc-figure --- height: 583 width: 800 alt: The AI Deploy by Belong logo on a dark violet background. caption: Choose the account that owns the server and bills you for its compute resources. placement: lead source-url: https://t.me/belongnet/403 src: https://docs.belong.net/media/social/ai-deploy-by-belong.webp --- :: ## Cloud Providers Your agent runs on **your own** cloud account. Belong AI Deploy provisions the server for you — you keep ownership, billing, and control. Your **cloud provider** supplies the virtual server and bills you for its resources. Choose it separately from the AI provider that answers messages. If you need inbound Slack or WhatsApp webhooks, check the provider's HTTPS support as well as its region and server size. | Provider | Auth | Speed | New deployments | | ---------------------- | ---------------- | -------- | ---------------------------------------------------------- | | DigitalOcean (default) | OAuth | \~10 sec | Active; fastest setup for most users. | | OVHcloud | Signed API token | 2–5 min | Active; live regions and sizes are verified before launch. | | Google Cloud | OAuth | \~15 sec | Active beta. | | AWS | API key | 2–5 min | Active beta. | | Scaleway | API key | 2–5 min | Active beta; Apple Mac Mini servers in Europe. | ::warning Microsoft Azure is retained only for compatibility with existing resources. It is not shown in the wizard and new Azure deployments are rejected. Choose OVHcloud or another active provider. :: ::note DigitalOcean, Google Cloud, and OVHcloud can open a single public HTTPS route when a selected channel requires inbound webhook delivery. Telegram stays private and uses outbound polling. Other providers need a separate HTTPS entrypoint for inbound webhooks. :: The [public self-host repository](https://github.com/belongnet/aideploy) currently has one live CLI cloud path: DigitalOcean. Its Google Cloud, AWS, and Azure OpenTofu modules are reference/validation contracts, not promises that `aideploy up` will create those resources. ## DigitalOcean (recommended) DigitalOcean is the fastest path — one-click OAuth and no keys to copy. ### Create a DigitalOcean account 1. In the wizard, use **Need an account? Create one**, or go directly to [DigitalOcean](https://m.do.co/c/af624a5e3198) 2. Click **Sign Up** — you can use Google, GitHub, or email 3. Add a payment method (credit card or PayPal) 4. Eligible new accounts can receive a **$200, 60-day referral credit** after adding a valid payment method 5. Return to the wizard and click **Sign in with DigitalOcean** ::note If you're creating a new DigitalOcean account, start from the wizard's **Need an account? Create one** link. The DigitalOcean sign-in page has its own signup links, but those may not preserve the referral credit. :: ### Connect in the wizard 1. Click **Sign in with DigitalOcean** 2. A popup opens — log into your DigitalOcean account if needed 3. Authorize the Belong AI Deploy app 4. The popup closes and you'll see a green checkmark ### Choose a region Pick the location closest to your users: | Region | Best for | | ------------- | ---------------------------- | | New York | US East Coast, South America | | San Francisco | US West Coast | | Amsterdam | Europe | | London | UK, Western Europe | | Frankfurt | Central Europe | | Singapore | Southeast Asia | | Bangalore | India | | Sydney | Australia, New Zealand | ### Server sizes | Plan | Agents | Cost | Specs | | ------- | ------ | -------- | ----------------- | | Starter | 1–4 | \~$24/mo | 2 vCPU, 4 GB RAM | | Growing | 5–8 | \~$48/mo | 4 vCPU, 8 GB RAM | | Power | 9–16 | \~$96/mo | 8 vCPU, 16 GB RAM | Most users should start with **Starter**. You can resize later from the DigitalOcean dashboard. ## OVHcloud OVHcloud requires an application key, application secret, consumer key, and Public Cloud service name. The account endpoint selected in the wizard must match the endpoint where the token was created. Follow [Deploy with OVHcloud](https://docs.belong.net/ai-deploy/ovhcloud) for the exact restricted permissions, service-name lookup, connection steps, and error recovery. ## Managing your server After deployment, manage your server from two places: - **Your cloud provider's dashboard** (e.g. [cloud.digitalocean.com](https://cloud.digitalocean.com/)) — resize, view metrics, manage billing - **The Belong AI Deploy dashboard** — reachable over your [Tailscale private network](https://docs.belong.net/ai-deploy/private-access) — manage agents, conversations, and tasks ## Next steps - [AI Providers](https://docs.belong.net/ai-deploy/ai-providers) — connect your agent's brain - [Private Access](https://docs.belong.net/ai-deploy/private-access) — reach your dashboard securely - [Open Source](https://docs.belong.net/ai-deploy/open-source) — compare public self-host and hosted support # AI Providers ::doc-figure --- height: 450 width: 800 alt: A violet search bar asking What are AI agents? caption: Your AI provider supplies the model; your cloud account runs the agent. placement: lead source-url: https://t.me/belongnet/94 src: https://docs.belong.net/media/social/understand-ai-agents.webp --- :: ## AI Providers Your agent needs an AI brain. Choose one (or more) of these providers. When you sign in with OAuth, your existing subscription covers usage — no extra per-message billing. The AI provider supplies the model your deployed agent talks to. Choose the provider and authentication method together: a subscription sign-in and an API key are different ways to authorize usage. Keep this choice separate from the cloud account that pays for the server. ## ChatGPT (recommended) **Default model:** GPT-5.5 ### OAuth (recommended) 1. Click **Sign in with ChatGPT** in the wizard 2. Log into your OpenAI account 3. Authorize the app 4. Your existing ChatGPT subscription covers usage — no extra API billing ### API key (fallback) 1. Go to [platform.openai.com/api-keys](https://platform.openai.com/api-keys) 2. Click **Create new secret key** 3. Copy the key and paste it in the wizard API key usage is billed per message, separate from your subscription. ## Claude **Default model:** Claude Opus 4.8 (1M) ### OAuth (recommended) 1. Click **Sign in with Claude** in the wizard 2. Log into your Anthropic account 3. Authorize the app 4. A local billing proxy on your deployed gateway keeps usage on your Claude Pro/Max plan ::note If you finish Claude setup from Telegram or WhatsApp after deploy, the bot sends a browser sign-in link. **Copy it into Safari, Chrome, or your normal desktop browser** instead of opening it inside the messenger — messenger browsers cannot finish this login reliably. Paste the final redirect URL or one-time code back to the bot. Never paste an Anthropic API key or OAuth bearer token into chat. :: ### API key (fallback) 1. Go to [console.anthropic.com/settings/keys](https://console.anthropic.com/settings/keys) 2. Click **Create Key** 3. Copy and paste it in the wizard ## Gemini **Default model:** Gemini 3 Deep Think Gemini uses API keys only (no OAuth). 1. Go to [aistudio.google.com/apikey](https://aistudio.google.com/apikey) 2. Click **Create API Key** 3. Select or create a Google Cloud project 4. Copy the key and paste it in the wizard Built-in media defaults after deploy: image generation uses `google/gemini-3-pro-image-preview` (with `google/gemini-2.5-flash-image` as a fallback), and voice-note transcription is handled natively. ## Kimi **Default model:** Kimi K2.6 Kimi uses API keys only. 1. Go to [platform.moonshot.cn/console/api-keys](https://platform.moonshot.cn/console/api-keys) 2. Create a new API key 3. Copy and paste it in the wizard ## Subscription vs. API-key billing | Method | How it works | | -------------------- | ---------------------------------------------------------------------------------------------------------------------------------- | | OAuth (subscription) | ChatGPT uses native subscription auth. Claude uses a built-in billing proxy on your deployed gateway, so usage stays on your plan. | | API key | You pay per message based on the provider's pricing. | If you have a ChatGPT Plus/Pro or Claude Pro/Max subscription, **OAuth is the better option**. # Telegram Setup ::doc-figure --- height: 583 width: 800 alt: The AI Deploy by Belong logo on a dark violet background. caption: Create a Telegram bot, connect its token, and test a message to your deployed agent. placement: lead source-url: https://t.me/belongnet/403 src: https://docs.belong.net/media/social/ai-deploy-by-belong.webp --- :: ## Telegram Setup Telegram is the fastest messaging integration — about 30 seconds to set up. Use this guide to connect your own deployed agent to a Telegram bot created through BotFather. The **bot token** identifies that bot; connecting the AI provider is a separate setup step. After deployment, send a private test message before inviting the bot into a group. ## Create a Telegram bot 1. Open Telegram on your phone or desktop 2. Search for **@BotFather** (the official bot-creation tool) 3. Send `/newbot` 4. BotFather asks for a **name** — the display name (e.g. "My AI Assistant") 5. BotFather asks for a **username** — must end in "bot" (e.g. `myai_assistant_bot`) 6. BotFather gives you a **token** like `123456789:ABCdefGHIjklMNOpqrsTUVwxyz` 7. Copy this token ## Connect in the wizard 1. On the wizard's **Connect your messaging apps** screen, select Telegram 2. Paste the bot token from BotFather 3. The wizard verifies it works ## Test your bot After deployment: 1. Open Telegram and search for your bot by its username 2. Click **Start** or send any message 3. If ChatGPT or Claude still needs sign-in, follow the secure sign-in link the bot sends first 4. Once AI setup finishes, send a message and your agent responds ## Finish AI setup from Telegram If Telegram is connected before ChatGPT or Claude sign-in finishes, the bot shows a command menu and inline buttons after deploy. Open the bot, then tap **Connect ChatGPT** or **Connect Claude** — or use the `/connectchatgpt` / `/connectclaude` commands. The bot replies even before AI is connected, so you can start right away. For ChatGPT, the bot sends a browser sign-in link. ::warning Copy the sign-in link into Safari, Chrome, or your normal desktop browser instead of opening it inside Telegram — messenger browsers cannot finish the login reliably. After sign-in, paste the ChatGPT sign-in code back to the bot. Never paste API keys or OAuth bearer tokens into chat. :: ## Customize your bot Use BotFather to customize: - `/setdescription` — what users see before they start chatting - `/setabouttext` — the bot's profile bio - `/setuserpic` — upload a profile picture - `/setcommands` — add custom command buttons ## Group chats Your bot can work in Telegram groups too: 1. Add the bot to a group 2. Make it an admin so it can read messages 3. The bot responds when mentioned or when specific keywords are used ### Privacy mode By default, Telegram bots in groups only see messages that mention them. To let your bot see all messages: 1. Send `/setprivacy` to BotFather 2. Choose your bot 3. Select **Disable** Only do this if your bot needs to respond to every message in a group. # WhatsApp Setup ::doc-figure --- height: 562 width: 800 alt: A purple conversation bubble with the words Guest Help in WhatsApp. caption: Connect the Business Platform and verify incoming messages before using the agent for guest support. placement: lead source-url: https://t.me/belongnet/444 src: https://docs.belong.net/media/social/guest-help-in-whatsapp.webp --- :: ## WhatsApp Setup Connect your agent to WhatsApp Business for customer-facing conversations. Use WhatsApp when you want people to reach the agent in a messenger they already use, such as asking where an event entrance is. This setup uses the WhatsApp Business Platform rather than a personal WhatsApp login. A **webhook** is the HTTPS callback through which Meta delivers incoming messages to the deployment. ## Prerequisites - A Meta (Facebook) developer account - A WhatsApp Business account - A phone number to register with WhatsApp Business ## Setup steps ### 1. Create a Meta developer app 1. Go to [developers.facebook.com](https://developers.facebook.com/) 2. Click **My Apps** → **Create App** 3. Choose **Business** as the app type 4. Give it a name (e.g. "My AI Agent") and complete the setup ### 2. Add WhatsApp to your app 1. In your app dashboard, find **Add Products** 2. Click **Set Up** next to WhatsApp 3. Follow the setup wizard ### 3. Get your Meta values 1. Go to **WhatsApp → API Setup** in your app dashboard 2. Copy the **Phone Number ID** (this is not the display phone number) 3. Copy the temporary access token for a quick test, or generate a permanent **System User token** for production 4. Go to **App settings → Basic** and copy the **App Secret** — it's used to verify signed webhook requests 5. Note the **Verify Token** shown in your Belong AI Deploy dashboard — you'll enter this same value in Meta's webhook form ### 4. Connect in the wizard 1. On the wizard's messaging screen, select WhatsApp 2. Continue the deployment 3. After deploy, finish WhatsApp setup from the management dashboard by adding your access token, phone number ID, verify token, and Meta app secret ### 5. Register your webhook Deployments stay private by default. If you selected WhatsApp on DigitalOcean or Google Cloud, the deployment opens public `443` for webhook routes only. Other providers need a separate public HTTPS entrypoint in front of the deployment. 1. Go to **WhatsApp → Configuration** 2. Copy the **Callback URL** shown in **Dashboard → Connect AI & Messengers → WhatsApp** (it's generated from your gateway URL and deploy ID) 3. Set the **Verify Token** to the value shown in that WhatsApp card 4. Make sure the **App Secret** in your dashboard matches the Meta app secret used for signed webhook requests 5. Subscribe to **messages** events ## Testing 1. From the API Setup page, send a test message to your personal WhatsApp 2. Reply to the message 3. Your agent should respond — high-risk actions come back as review-only drafts for you to confirm ## Production notes - Temporary tokens expire after 24 hours — use a **System User token** for production - WhatsApp requires a verified business to message users who haven't messaged you first - Message templates need approval for outbound notifications # Slack Setup ::doc-figure --- height: 1013 width: 1440 alt: A purple conversation terminal with the words Your Agent in Slack. caption: Once connected, test a direct message or mention in the workspace where your team works. placement: lead source-url: https://t.me/belongnet/486 src: https://docs.belong.net/media/social/your-agent-in-slack.webp --- :: ## Slack Setup Add your AI agent to Slack workspaces for team-based conversations. Use Slack when the agent should answer in the same workspace as your team. Create and install the Slack app, connect its credentials, then test a direct message or mention. Bot permissions control what it can read or send, and event subscriptions determine which incoming messages reach the agent. ## Setup steps ### 1. Create a Slack app 1. Go to [api.slack.com/apps](https://api.slack.com/apps) 2. Click **Create New App** → **From scratch** 3. Give it a name and select your workspace ### 2. Configure bot permissions 1. Go to **OAuth & Permissions** in the sidebar 2. Under **Bot Token Scopes**, add: - `chat:write` — send messages - `app_mentions:read` — respond when mentioned - `channels:history` — read channel messages (optional) - `im:history` — read direct messages - `im:write` — send direct messages ### 3. Install to workspace 1. Go to **Install App** in the sidebar 2. Click **Install to Workspace** and authorize the permissions 3. Copy the **Bot User OAuth Token** (starts with `xoxb-`) ### 4. Enable events Deployments stay private by default. If you selected Slack on DigitalOcean or Google Cloud, the deployment opens public `443` for webhook routes only. Other providers need a separate public HTTPS entrypoint in front of the deployment. 1. Go to **Event Subscriptions** and toggle **Enable Events** on 2. Set the **Request URL** to: `https://YOUR_WEBHOOK_DOMAIN/webhook/slack/YOUR_DEPLOY_ID` 3. Under **Subscribe to bot events**, add: - `message.im` — direct messages - `app_mention` — when someone mentions your bot ### 5. Connect in the wizard 1. On the wizard's messaging screen, select Slack 2. Paste your **Bot User OAuth Token** 3. After deploy, finish the channel checks from the management dashboard ## Using the bot - **Direct messages** — just message the bot directly - **Channels** — invite the bot to a channel and mention it with `@botname` - **Threads** — the bot can reply in threads for organized conversations ## Tips - In **App Home** settings, enable the **Messages Tab** so users can DM your bot - Add a bot description and profile picture under **Basic Information** - Use **Slash Commands** if you want to add custom `/commands` # Private Access ::doc-figure --- height: 583 width: 800 alt: The AI Deploy by Belong logo on a dark violet background. caption: Reach the management dashboard through your own private Tailscale network. placement: lead source-url: https://t.me/belongnet/403 src: https://docs.belong.net/media/social/ai-deploy-by-belong.webp --- :: ## Private Access Belong AI Deploy puts your dashboard and agent on a **private network** using [Tailscale](https://tailscale.com/). Only your own devices can reach them — no one else on the internet can. Use this guide after launch to reach the management dashboard from your own phone or laptop. Both your device and the server need to join the same Tailscale network. Messenger delivery is a separate route: an optional public webhook endpoint does not make the dashboard public. ## What is Tailscale? Tailscale is a modern VPN that connects your devices in a private network. It's free for personal use and takes about a minute to set up. ## Setup steps ### 1. Create a Tailscale account 1. Go to [login.tailscale.com/start](https://login.tailscale.com/start) 2. Sign up with Google, Microsoft, GitHub, or email 3. It's free for personal use (up to 100 devices) ### 2. Generate an auth key The wizard needs an auth key to connect your agent's server to your Tailscale network. 1. Go to [login.tailscale.com/admin/settings/keys](https://login.tailscale.com/admin/settings/keys) 2. Click **Generate auth key** 3. Settings: - **Reusable:** Yes - **Ephemeral:** No - **Expiration:** the default is fine 4. Copy the key (starts with `tskey-auth-`) ### 3. Paste in the wizard 1. Paste the auth key in the wizard's private-network screen 2. Click **Verify** 3. You'll see **Private network ready** ### 4. Install Tailscale on your devices After deployment, install Tailscale on any device where you want to access your dashboard: - **iPhone / iPad** — [App Store](https://apps.apple.com/app/tailscale/id1470499037) - **Android** — [Google Play](https://play.google.com/store/apps/details?id=com.tailscale.ipn) - **Mac** — [Mac App Store](https://apps.apple.com/app/tailscale/id1475387142) - **Windows** — [tailscale.com/download](https://tailscale.com/download) - **Linux** — `curl -fsSL https://tailscale.com/install.sh | sh` ### 5. Access your dashboard 1. Open Tailscale on your device and sign in with the same account 2. In your browser, go to `http://YOUR_TAILSCALE_IP:3000` 3. That's your management dashboard. ## How it works - Your agent's server gets a Tailscale IP (like `100.64.x.x`); your devices get one too - They communicate directly, as if on the same local network - No ports need to be opened to the public internet for the dashboard, SSH, or agent traffic - The agent's gateway ports stay private unless you intentionally add a separate HTTPS entrypoint - If you use Telegram, WhatsApp, or Slack webhooks, those route through one shared HTTPS entrypoint — never your app ports directly ::mermaid ```text flowchart TD accTitle: Reaching the private dashboard accDescr: An authorized device uses the same Tailscale network as the server to reach its management dashboard. A[Your phone or laptop] --> B[Join the same Tailscale network] B --> C[Open the server Tailscale address] C --> D[Management dashboard on port 3000] ``` :: The private route is for managing the server. Incoming messenger webhooks, when needed, use a separate HTTPS entrypoint; Telegram can use outbound polling without opening the dashboard to the internet. ## Security - Dashboard access is limited to devices on your Tailscale network - Gateway and agent ports stay private on the server - Any public webhook ingress is optional and should be a single HTTPS entrypoint you control - All Tailscale traffic is encrypted end-to-end # Troubleshooting ::doc-figure --- height: 583 width: 800 alt: The AI Deploy by Belong logo on a dark violet background. caption: "Locate the failing stage: cloud provisioning, private access, messaging, or the AI connection." placement: lead source-url: https://t.me/belongnet/403 src: https://docs.belong.net/media/social/ai-deploy-by-belong.webp --- :: ## Troubleshooting Common issues and how to fix them. Find the failing stage first: server creation, private dashboard access, messenger delivery, or the AI provider connection. Check the deployment progress log and the affected agent's dashboard status before changing credentials. This helps distinguish an unreachable dashboard from a bot that is reachable but still needs its AI connection. ## Deployment issues ### "Server creation timed out" - Check your cloud provider's dashboard to see whether the server was created - Your account may have hit a resource limit — check your provider's limits - Try a different region ### "Cloud-init took too long" - The server is still installing its runtime - Wait a few more minutes and check the **Technical details** in the progress screen - The deployment streams logs there throughout setup ### "Stack deployment failed" - Open the **Technical details** log in the wizard to see which step failed - A redeploy from a clean state is usually the fastest fix — see [Full redeployment](https://docs.belong.net/#full-redeployment) below ### "OVHcloud rejected these credentials" 1. Confirm the wizard account endpoint matches the site where the API token was created 2. Use the Public Cloud API service name, not the editable project display name 3. Confirm the consumer key includes the required project and instance rules 4. Follow [Deploy with OVHcloud](https://docs.belong.net/ai-deploy/ovhcloud#troubleshooting) to create a replacement restricted token ## Connection issues Private-by-default deployments do **not** expose internal app ports to the internet. DigitalOcean, Google Cloud, and OVHcloud deployments open public `443` only when a selected channel requires inbound webhook delivery. Telegram stays private and uses outbound polling. Other providers need a separate HTTPS entrypoint. ### "Can't access the dashboard" 1. Make sure [Tailscale](https://docs.belong.net/ai-deploy/private-access) is running on your device 2. Check that both your device and the server are on the same Tailscale network 3. Try the Tailscale IP directly: `http://100.x.x.x:3000` ### "Telegram bot not responding" 1. Open the **management dashboard** first (`http://:3000`) and go to **Connect AI & Messengers** 2. Use the **Agent** selector to choose the right agent 3. Confirm Telegram shows as configured there 4. If the bot is already replying in chat, ask it to connect the missing provider there instead of pasting secrets 5. Verify the bot token works: visit `https://api.telegram.org/botYOUR_TOKEN/getMe` ### "Pairing required" in the agent UI 1. Return to the **management dashboard** (`:3000`) and run setup from **Connect AI & Messengers** 2. Use the **Agent** selector to choose the affected agent 3. If shown, click **Fix Pairing Automatically** in the setup checklist 4. If pairing still fails, restart the agent from the **Agents** page ### "WhatsApp webhook verification failed" 1. Double-check the callback URL in Meta's developer console 2. Verify the verify token matches the value shown in **Dashboard → Connect AI & Messengers → WhatsApp** 3. Make sure your HTTPS entrypoint forwards to `/webhook/whatsapp/YOUR_DEPLOY_ID` ## AI provider issues ### "OAuth token expired" - Your agent automatically refreshes OAuth tokens - If refresh fails, reconnect from chat by asking the bot to connect ChatGPT or Claude again, or use **Connect AI & Messengers** in the dashboard ### "API key invalid" - Verify the key at the provider's dashboard - Check whether the key was revoked or expired - Update the key from chat (if the bot is live) or in your agent's dashboard settings ::note For ChatGPT or Claude browser sign-in, don't paste OAuth bearer tokens as API keys. Reconnect by asking the bot to connect the provider, copy the sign-in link into Safari, Chrome, or your normal desktop browser, and paste the code it shows back to the bot. :: ### "Model not available" - Your subscription plan may not include the default model - The agent automatically falls back to the next best model - You can manually select a different model in dashboard settings ## Performance issues ### "Agent responding slowly" - Consider upgrading to a larger [server size](https://docs.belong.net/ai-deploy/cloud-providers#server-sizes) - Reduce the number of agents if you're running several - Check your AI provider's status page for outages ### "Database running out of space" - Enable conversation pruning in **Dashboard → Settings** - Run a manual cleanup with **Settings → Clean up now** - Resize the server's disk via your cloud provider ## Recovering from errors ### Restart a single agent From the master dashboard, find the agent card and click **Restart**. ### Full redeployment If things are severely broken, tear down and redeploy: 1. Go to the wizard 2. Click **Destroy** on your existing deployment 3. Re-run the wizard # Enterprise & API ::doc-figure --- height: 583 width: 800 alt: The AI Deploy by Belong logo on a dark violet background. caption: Use the documented REST API or local MCP server to provision and manage your own deployments. placement: lead source-url: https://t.me/belongnet/403 src: https://docs.belong.net/media/social/ai-deploy-by-belong.webp --- :: ## Overview Beyond the sign-in wizard, Belong AI Deploy offers a **REST API** and a **local MCP server** for teams that want to provision agents programmatically instead of clicking through the wizard — for example, deploying from CI, managing a fleet from your editor, or batch-launching an agent per customer. Use programmatic deployment when your own system needs to create or manage agents repeatedly. Keep a stable `externalId` for each deployment so retries refer to the same intended resource, then monitor status before directing customers to it. The local MCP server provides the same deployment capability through assistant tool calls. ## Deployment API Create, monitor, and tear down agent deployments with a single request: ```bash curl -X POST https://aideploy.co/api/enterprise/v1/deployments \ -H "Authorization: Bearer $AIDEPLOY_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "externalId": "acme-prod", "cloudProvider": "digitalocean", "cloudToken": "dop_v1_...", "region": "nyc3", "serverSize": "starter", "agentCount": 1, "tailscaleAuthKey": "tskey-auth-...", "selectedAIProviders": ["openai"], "agents": [{ "name": "Acme assistant", "modelProvider": "openai", "authMethod": "consumer", "model": "gpt-5.5", "template": "general" }], "billingAcknowledged": true }' ``` Capabilities: - Create single or batch deployments - Real-time status polling and refresh - Idempotent deployments via your own `externalId` - Scoped API keys, stored as SHA-256 hashes - Cloud tokens and other secrets are stripped before storage — never persisted in plaintext ## MCP server A local MCP server wraps the deployment API so AI coding assistants (Claude Code, Cursor, and other MCP-capable clients) can provision infrastructure through tool calls instead of raw HTTP. - **Transport:** stdio — works with any MCP client - **Tools:** `capabilities`, `list`, `get`, `create`, `batch`, `destroy` (6 total) - Pre-flight capability validation before a deployment is submitted - Same authentication and access control as the REST API ## Batch and fleet deployment Batch requests can deploy up to 25 agents in a single call, with per-deployment status tracking. Batch deployment, white-label, and SLA options are available on higher-volume plans — see [aideploy.co/enterprise](https://aideploy.co/enterprise) or talk to sales for access and pricing. ## Security - API keys are stored as SHA-256 hashes, not plaintext - Cloud provider tokens are stripped from stored configuration after use - Row-level security is enforced on enterprise data - Keys are revocable and scope-enforced ## Getting access Programmatic/enterprise access is separate from the self-serve wizard. See [aideploy.co/enterprise](https://aideploy.co/enterprise) for current plans, or contact . ## Related - [Quick Start](https://docs.belong.net/ai-deploy/quickstart) — the self-serve wizard flow - [Cloud Providers](https://docs.belong.net/ai-deploy/cloud-providers) # Deploy with OVHcloud ::doc-figure --- height: 583 width: 800 alt: The AI Deploy by Belong logo on a dark violet background. caption: Connect an OVHcloud project and its credentials before provisioning the agent server. placement: lead source-url: https://t.me/belongnet/403 src: https://docs.belong.net/media/social/ai-deploy-by-belong.webp --- :: ## Deploy with OVHcloud AI Deploy can create a Hermes or OpenClaw server in your OVHcloud Public Cloud project. You keep ownership of the project, server, and billing. Use the steps below to connect the project before creating compute resources. The **account endpoint** selects which OVHcloud account API validates the credentials; the **compute region** selects where the server runs. Confirm both choices during setup so a valid token is not sent to the wrong account API. OVHcloud uses four values instead of one cloud token: - an **application key**; - an **application secret**; - a **consumer key**; - the Public Cloud **service name** used by the API. ::warning The account endpoint must match the site where you create the token. A US token will be rejected by the Europe endpoint even when all four values are correct. The account endpoint is separate from the compute region where the server runs. :: ## What you need - An OVHcloud account with an active Public Cloud project. - A payment method and enough quota for at least 2 vCPU and 4 GB RAM. - Permission to create API credentials for that account. - An enabled compute region in the project. ## 1. Choose your OVHcloud account endpoint Use the account site where you normally sign in, not the physical location where you want the server: | Wizard choice | Token creator | | --------------------------------- | ---------------------------------------------------------------------------- | | Europe and international accounts | [Create a Europe API token](https://eu.api.ovh.com/createToken/) | | Canada accounts | [Create a Canada API token](https://ca.api.ovh.com/createToken/) | | United States accounts | [Create a United States API token](https://api.us.ovhcloud.com/createToken/) | Select the same choice in the AI Deploy wizard before pasting the credentials. ## 2. Copy the Public Cloud service name 1. Open [OVHcloud Manager](https://www.ovh.com/manager/#/public-cloud). 2. Select the Public Cloud project that should own the server. 3. Copy its API **service name**. It is normally a 32-character identifier. Do not paste the editable project display name. The service name is the value OVHcloud uses in API paths such as `/cloud/project/`. ## 3. Create a restricted API token Open the token creator from step 1 and add these access rules, replacing `` with the value you copied: ```text GET /cloud/project/ GET /cloud/project//* POST /cloud/project//instance DELETE /cloud/project//instance/* ``` These rules let AI Deploy read the live region, flavor, image, and instance catalog; create one server; monitor it; and delete the matching server during cleanup. They do not grant access to domains, account settings, or billing profiles. Set an expiration date that covers the deployment. The token creator returns the application key, application secret, and consumer key. Save all three in a password manager before leaving the page. ## 4. Connect OVHcloud in AI Deploy 1. Choose **OVHcloud** on the Cloud step. 2. Select the same account endpoint used to create the token. 3. Paste the application key, application secret, consumer key, and Public Cloud service name. 4. Select **Connect**. 5. Choose one of the verified regions and an available server size. 6. Confirm that billing and quota are active, then continue through the wizard. Connecting is read-only. AI Deploy checks the project and its live catalog but does not create a server until you select **Launch** on the Review step. ## What AI Deploy creates AI Deploy selects the smallest available Linux flavor that meets the chosen size instead of relying on a project-specific flavor ID: | Size | Minimum resources | Estimated monthly cost | | ------- | ----------------- | ---------------------- | | Starter | 2 vCPU, 4 GB RAM | about €20–€35 | | Growing | 4 vCPU, 8 GB RAM | about €40–€70 | | Power | 8 vCPU, 16 GB RAM | about €80–€140 | The estimate is not a quote. OVHcloud pricing and available flavors vary by project and region. The server name starts with `aideploy-`. Its host firewall denies inbound traffic by default, allows your Tailscale private network, and opens public HTTPS only when a selected messaging channel needs webhook delivery. ## Verification After you select **Connect**, the wizard should: - show only regions enabled in your project; - show the live OVHcloud flavor selected for each available size; - ask you to confirm billing and quota before launch. After launch, open OVHcloud Manager and confirm that one `aideploy-...` instance appears in the selected project and region. The wizard's progress screen then shows the runtime installation and private-access details. ## Troubleshooting ### OVHcloud rejected the credentials Check these items in order: 1. The wizard account endpoint matches the token creator. 2. All three keys came from the same token creation result. 3. The service name is the API identifier, not the project display name. 4. The token includes every `GET` rule above. 5. The token has not expired or been revoked. Create a new restricted token if any value is uncertain. Rotating all three credential values together is safer than mixing values from different tokens. ### The project has no enabled regions Enable a compute region in OVHcloud Manager, wait for the project update to finish, and select **Connect** again. ### No server size is available Choose another verified region. If every region is unavailable, free project capacity or ask OVHcloud to raise the instance quota. ### Verification succeeds but launch is denied The token can read the project but cannot create a server. Add the `POST` instance rule shown above, create a replacement token, and reconnect it in the wizard. Cleanup also needs the `DELETE` instance rule. ### A failed launch left a server behind AI Deploy reconciles servers by their deterministic `aideploy-` name and attempts automatic cleanup. If cleanup cannot use an expired or revoked token, delete only the matching instance in OVHcloud Manager. ## Keep the credentials safe - Paste the keys only into the AI Deploy wizard, never into chat or a support message. - The wizard keeps cloud credentials in the current browser session, not in long-lived local storage. - Revoke or rotate the consumer key after deployment if you do not need AI Deploy to perform later cleanup. - OVHcloud Object Storage uses separate S3 credentials; the compute token does not configure backups. ## Related guides - [Cloud Providers](https://docs.belong.net/ai-deploy/cloud-providers) - [Private Access](https://docs.belong.net/ai-deploy/private-access) - [Troubleshooting](https://docs.belong.net/ai-deploy/troubleshooting) # Belong Platform ::doc-figure --- height: 450 width: 800 alt: A violet globe beside The Operating System for Real-World Communities. caption: Use hubs to connect a community, its events, membership, and content. placement: lead source-url: https://t.me/belongnet/276 src: https://docs.belong.net/media/social/real-world-communities.webp --- :: ## Overview [Belong Platform](https://belong.net) connects communities, event access, membership passes, and paid or gated content. Use it when you want a shared home for a community and the experiences its members can access. A **hub** groups a venue or community's information. A membership pass can represent access to that community. **Token gating** checks whether someone holds the digital asset required to open a particular experience or piece of content. ## Choose what to build | Your goal | Start with | | -------------------------------------------------- | ----------------------------------------------------------------------- | | Create a community hub and manage its information | [Hubs and community operations](https://docs.belong.net/mcp/tools-hubs) | | Run events with regular or NFT tickets | [Event creation](https://docs.belong.net/belong-checkin/event-creation) | | Publish and organize media with access rules | [Media collections](https://docs.belong.net/guides/media/collection) | | Prepare an app under your own brand | [Whitelabel launch kit](https://docs.belong.net/guides/whitelabel) | | Integrate the experience into your own application | [Belong API & Docs](https://docs.belong.net/developer-platform) | For example, a community can keep its public information in a hub, create an event for members, and publish related media in a collection. Choose the ticket format and access rules for each experience before sharing it. ## Get started 1. Open [belong.net](https://belong.net) and enter the web app, or use its App Store or Google Play links. 2. Identify the hub or community you want to manage and prepare its name, description, and branding. 3. Follow the relevant guide above to create an event, organize media, or prepare a branded launch. 4. Review the resulting public page and its configured access flow before sharing it with your community. The guide for each feature contains its setup requirements. An integration that prepares blockchain transactions must still follow its documented signing and confirmation flow. ## Venue operations [Belong CheckIn](https://docs.belong.net/belong-checkin) provides the venue-focused guides for check-ins, customer rewards, promoter attribution, payments, and campaign funding. Start with its [Venue Quick Start](https://docs.belong.net/belong-checkin/venue-quickstart) when your goal is to bring guests through a physical venue. ## Build on the platform Developers can use the [REST API](https://docs.belong.net/getting-started/api-docs), [JavaScript SDK](https://docs.belong.net/getting-started/sdk), and [MCP connections](https://docs.belong.net/getting-started/mcp). The [developer overview](https://docs.belong.net/developer-platform) explains which interface to choose and links to the contract guides. Public product information: [belong.net](https://belong.net). # Belong Events ::doc-figure --- height: 630 width: 1200 alt: "Belong Events: Discover events worldwide, beside a traveler on a glowing platform." caption: Find a city or event week, then follow the listing to its schedule and ticket destination. placement: lead source-label: Product website source-url: https://belong.events src: https://docs.belong.net/media/products/belong-events.webp --- :: ## Overview [Belong Events](https://belong.events) is the public event catalogue for people. Browse music, crypto, technology, and other events by city or event week, then open a listing to plan your visit. An **event week** groups a conference or festival with its surrounding programme and side events. Artist and venue pages help you follow the people and places behind the listings. ## Find an event 1. Open [belong.events](https://belong.events) and choose a city, event week, or artist. 2. Open a listing that matches your interests and dates. 3. Review its venue, local date and time, organizer information, and available ticket or registration link. 4. Follow the ticket destination to complete the organizer's entry or registration process. For a conference trip, start with the event week and compare the surrounding side events. For a night out, start with your city or an artist you want to see. ## Plan from the listing | Information | How to use it | | ---------------------------------- | --------------------------------------------------------------------------- | | Venue and city | Check where you need to travel and whether two events fit the same evening. | | Local date and time | Compare the venue's local schedule when planning across time zones. | | Artist or lineup | Follow the acts you want to see and open their other dates. | | Ticket or registration destination | Complete the entry process with the destination shown on the listing. | A catalogue listing helps you discover an event; admission follows the organizer's ticketing and registration requirements. Recheck the linked event information before travelling. ## Related products - [Crypto Events](https://docs.belong.net/crypto-events) focuses on crypto conferences, hackathons, protocol meetups, and side events. - [LONG Events](https://docs.belong.net/long-events) provides the event catalogue through REST and MCP for applications and AI agents. - [Belong CheckIn](https://docs.belong.net/belong-checkin/event-creation) covers creating and operating your own events with Belong. Public catalogue: [belong.events](https://belong.events). Developer catalogue guidance: [LONG Events agent guide](https://long.events/docs/agents). # LONG Events ::doc-figure --- height: 630 width: 1200 alt: "LONG Events: Real-world events, ready for agents. Search events, schedules, artists, venues, and organizers through MCP or REST." caption: Use the event-data API or MCP server to retrieve catalogue context for an application or agent. placement: lead source-label: Product website source-url: https://long.events src: https://docs.belong.net/media/products/long-events.webp --- :: ## Overview [LONG Events](https://long.events) gives applications and AI agents access to a catalogue of real-world events. Query events, event weeks, artists, venues, schedules, set times, and ticket destinations through REST or MCP. Use this product when a travel assistant needs events in a city, a festival assistant needs a stage schedule, or an application needs structured event listings. The public [LONG Events documentation](https://long.events/docs) and [OpenAPI contract](https://long.events/openapi.json) define its current request and response formats. ## Choose an interface | Interface | Use it for | Public endpoint or reference | | ------------------------------ | ------------------------------------------------------ | -------------------------------------------------- | | REST events API | Application queries for events, artists, and schedules | `https://long.events/functions/v1/api-events` | | REST event weeks API | Conferences, festivals, and their side events | `https://long.events/functions/v1/api-event-weeks` | | MCP server | Tool-using assistants and agents | `https://long.events/functions/v1/mcp-server/mcp` | | OpenAPI | Parameter details, schemas, and generated clients | [openapi.json](https://long.events/openapi.json) | | Machine-readable documentation | Documentation discovery by AI clients | [llms.txt](https://long.events/llms.txt) | ## Connect an agent Add the MCP endpoint as a **streamable HTTP** server in your client's MCP settings. For example, the public guide gives this Claude Code command: ```bash claude mcp add long-events -t http https://long.events/functions/v1/mcp-server/mcp ``` Initialize the connection and list its tools before making a data request. MCP `initialize`, `ping`, `tools/list`, and notifications are free. Data-returning `tools/call` requests use the applicable API allowance or advertised payment requirements. | Request | First tool to inspect | | ----------------------------------- | --------------------------------------------------- | | Events in a city over a date window | `search_events` | | Side events around a conference | `search_event_weeks`, then `get_event_week_details` | | An artist's upcoming dates | `get_artist_events` | | A stage-by-stage programme | `get_event_schedule` | | The act playing now | `get_now_playing` | Use the live tool schemas for exact input fields. See the [MCP reference](https://long.events/docs/mcp) and [agent integration guide](https://long.events/docs/agents) for client setup and task examples. ## Use REST The two REST endpoints dispatch on an `action` parameter. An application can search the catalogue with an API key: ```bash curl 'https://long.events/functions/v1/api-events?action=discover&city=Lisbon&limit=20' \ -H 'X-API-Key: YOUR_API_KEY' ``` Use the [REST reference](https://long.events/docs/api) and [OpenAPI contract](https://long.events/openapi.json) for date filters, pagination, actions, and response schemas. ## Access and payment - **API key:** send a supported LONG or Belong key in `X-API-Key` to use its allowance. - **Per-call payment:** a metered request without a key returns HTTP `402` payment requirements. Read the quoted amount, asset, network, and payment destination before signing and retrying the same request. - **Current prices and lanes:** use the [live pricing endpoint](https://long.events/functions/v1/api-pricing). The standard x402 lane uses USDC on Base; use the requirements returned by the API for the request you are making. **x402** is the payment protocol used to return a quote with a request and verify a paid retry. The [payment guide](https://long.events/x402-events-api) describes the flow, including settlement metadata. Event-data payment is separate from buying an event ticket. ## Present results to people Use [Belong Events](https://docs.belong.net/belong-events) links for general event, week, city, artist, venue, and organizer pages, and [Crypto Events](https://docs.belong.net/crypto-events) for crypto event detail pages. Follow the returned ticket destination when someone wants to register or buy entry. For creating events, managing hubs, or operating venue campaigns in Belong, use the [Belong developer platform](https://docs.belong.net/developer-platform) and its [application MCP connections](https://docs.belong.net/getting-started/mcp). # Crypto Events ::doc-figure --- height: 630 width: 1200 alt: "Crypto Events: Side events are the calendar, beside a green globe." caption: Explore a conference week and its surrounding meetups, hackathons, and side events. placement: lead source-label: Product website source-url: https://cryptoevents.ai src: https://docs.belong.net/media/products/crypto-events.webp --- :: ## Overview [Crypto Events](https://cryptoevents.ai) is the crypto-focused event discovery site. Use its global calendar to find conferences, protocol meetups, hackathons, and the side events happening around them. A conference ticket covers the programme sold by its organizer. Side events can have their own locations, times, registration pages, and approval requirements, so open each listing you plan to attend. ## Plan a conference week 1. Open [cryptoevents.ai](https://cryptoevents.ai) and select a city or crypto event week. 2. Explore the surrounding conferences, meetups, hackathons, and side events. 3. Open each relevant event and check its local time, venue, and registration destination. 4. Complete each event's registration process and use its latest organizer information when planning travel between venues. For example, start from a conference week in a city you will visit, then compare its side events by location and time. This gives you a practical itinerary instead of a list of unrelated links. ## Choose the discovery surface | What you need | Product | | -------------------------------------------------------------- | ------------------------------------------------------ | | Crypto conferences and side events | [Crypto Events](https://cryptoevents.ai) | | A broader catalogue including music and other event categories | [Belong Events](https://docs.belong.net/belong-events) | | Structured event queries inside an application or AI assistant | [LONG Events](https://docs.belong.net/long-events) | ## For developers The [LONG Events API and MCP server](https://docs.belong.net/long-events) expose event and event-week data. Its [agent guide](https://long.events/docs/agents) explains which human-facing URLs to use when citing general listings and crypto event pages. ## For organizers Use [Belong CheckIn](https://docs.belong.net/belong-checkin/event-creation) for Belong event creation, ticketing, and venue operations. Use the discovery sites to explore the public programme and the entry information linked from each listing. Public catalogue: [cryptoevents.ai](https://cryptoevents.ai). # Belong.net — Documentation ::u-page-hero #title Belong.net [Documentation]{style="color:#7540ee"} #description Find events, run venues and communities, deploy private AI agents, or manage token liquidity. Choose a public product and start with its practical guide. #links :::u-button --- color: neutral size: xl to: https://docs.belong.net/getting-started/introduction trailing-icon: i-lucide-arrow-right --- Explore the products ::: :: ::doc-figure --- height: 450 width: 800 alt: A violet globe and platform beside The Operating System for Real-World Communities. caption: Explore the public products for events, communities, private agents, liquidity, and integrations. placement: lead source-url: https://t.me/belongnet/276 src: https://docs.belong.net/media/social/real-world-communities.webp --- :: ::u-page-section :::u-page-grid{.lg:grid-cols-2} ::::u-page-card --- description: Run venue check-ins, ticketing, customer rewards, and promoter campaigns. icon: i-lucide-qr-code title: Belong CheckIn to: https://docs.belong.net/belong-checkin --- :::: ::::u-page-card --- description: Create communities, membership passes, gated content, and branded experiences. icon: i-lucide-panels-top-left title: Belong Platform to: https://docs.belong.net/belong-platform --- :::: ::::u-page-card --- description: Find events, event weeks, artists, and venues around the world. icon: i-lucide-calendar-days title: Belong Events to: https://docs.belong.net/belong-events --- :::: ::::u-page-card --- description: Query event data from an application or AI agent through REST and MCP. icon: i-lucide-bot title: LONG Events to: https://docs.belong.net/long-events --- :::: ::::u-page-card --- description: Explore crypto conferences, protocol meetups, hackathons, and side events. icon: i-lucide-globe title: Crypto Events to: https://docs.belong.net/crypto-events --- :::: ::::u-page-card --- description: Launch a private AI agent on your own infrastructure and connect its messaging channels. icon: i-lucide-rocket title: AI Deploy to: https://docs.belong.net/ai-deploy/overview --- :::: ::::u-page-card --- description: Monitor liquidity and manage market-making execution within your desk's limits. icon: i-lucide-chart-no-axes-combined title: Hexagon MM to: https://docs.belong.net/hexagon-mm --- :::: ::::u-page-card --- description: Build integrations with the REST API, SDK, MCP tools, and smart contracts. icon: i-lucide-code-xml title: Belong API & Docs to: https://docs.belong.net/developer-platform --- :::: ::: #title Documentation by product #description Each product has its own purpose and starting point. Open a guide below, or use the sidebar to reach its operating instructions and technical reference. ::