syncUser(walletAddress)
Allows you to clone ChainvineClient instance scoped to a single wallet address without having to fetch your ClientConfig.
In addition to creating a ChaivineUser instance from your ChainvineClient, this method will sync the wallet to the database and return the wallet's ChainVine User Id.
EVM Wallet Addresses
import { ChainvineClient } from '@chainvine/sdk';
const client = new ChainvineClient({
apiKey: '9dj022didj', //your api key
});
//Get a user's wallet address by id
const userClient = await client.syncUser(
'0x0384093304u83', // your user's wallet address
);
Params
Param
Required
Description
walletAddress
required
the wallet of the user to general a referral link for
Response
A ChainvineUser client instance
Last updated