Socios.com Connect
Chiliz ChainChiliz Labs
  • Socios.com Connect
  • INTERACT WITH CHILIZ CHAIN
    • Overview
    • Prerequisites
    • Working with Tokens
    • Working with NFTs
    • Working with Transactions
    • Working with Polls
    • Working with Staking
  • Partner API
    • Overview
    • 2025 API Update Overview
    • Prerequisites
    • Quick start
    • Authentication
    • API Reference
      • Data API
        • Data API endpoints
      • NFT API
        • NFT API endpoints
      • Ping API
      • Polls API
        • Polls API endpoints
      • Rewards API
        • Rewards API endpoints
      • User API
        • User API endpoints
      • Wallet API
        • Wallet API endpoints
  • Partner web app
    • Overview
    • Integration
    • URL parameters
    • On-Ramp Fan Tokens
Powered by GitBook
On this page
  • Setting up your environment
  • Instantiating the RPC client
  • Implementing a "Connect Wallet" button to your dApp
  • Displaying the "Socios.com Wallet" option in the WalletConnect modal
  1. INTERACT WITH CHILIZ CHAIN

Prerequisites

PreviousOverviewNextWorking with Tokens

Last updated 21 days ago

To access CHZ, fan tokens, and other Chiliz Chain content on your users' wallet, you need to configure your dApp to access Chiliz Chain et allow users to connect their wallet to it.

Setting up your environment

To achieve that, you can set your environment up with and the (you can use npm install viem once Node.js is installed).

Instantiating the RPC client

Before starting a blockchain request, you MUST add this piece of code in order to initiate Viem and connect to Chiliz Chain via the RPC endpoint of your choice.

You only need this code once in your codebase.

import { createPublicClient, http } from 'viem'; // Initiate Viem

const client = createPublicClient({
  transport: http('https://YOUR-CHOSEN-RPC-ENDPOINT.com'), // Connect to Chiliz chain
});

There are several that you can choose from.

Implementing a "Connect Wallet" button to your dApp

Before interacting with Chiliz Chain, you must implement in order for users to log in to you dApp.

Once their wallet is connected, your dApp will be able to retrieve the user's wallet information, and possibly send data such as NFTs, tokens, etc.

Displaying the "Socios.com Wallet" option in the WalletConnect modal

WalletConnect is one of the most common wallet-connection toolkit out there.

When building a dApp, there's a good chance you will rely on it to connect with user wallets.

If you want to allow your users to easily select the Socios.com Wallet, you can display it as an option in the WalletConnect pop-up. This pop-up appears in most "Connect Wallet" buttons online.

To display the Socios.com Wallet option, add the following line to the featuredWalletsIds option in your WalletConnect initialization code:

const SOCIOS_WALLET_ID = '56843177b5e89d4bcb19a27dab7c49e0f33d8d3a6c8c4c7e5274f605e92befd6'

createAppKit({
	[...],
	featuredWalletIds: [
		SOCIOS_WALLET_ID
	],
	[...],
})

If your "Connect Wallet" code does not use WalletConnect/Reown, contact us so that we can help you out!

If you have any question or a specific configuration need, : we will be happy to help you!

NOTE: WalletConnect is now know as .

The featureWalletIds option is part of the createAppKit function. Learn more about it .

Node.js
Viem library
Chiliz Chain RPC endpoint
a "Connect Wallet" button on you website or mobile app
please let us know
Reown WalletKit
in the WalletConnect/Reown documentation
Socios.com Wallet displayed as a featured wallet