3.0 Data API

V2 Revenue Paths require an API Key provided by the R3VL team. This enables the SDK to authorize and communicate with the R3VL API which is responsible for storing Revenue Path configurations.

We store wallet and distribution share data in databases, reducing costs and gas consumption. Firebase is currently supported, with plans to add Polybase and other options. Actual data is stored externally, with a hash reference saved in the contract.

import { useR3vlClient } from "@r3vl/sdk/hooks";

useR3vlClient({
  chainId: chain?.id
  provider,
  signer,
  initV2Final: true, // In case you want to create a "complex" Revenue Path with tiers
  initSimple: true, // For revenue paths with no additional tiers configuration
  apiKey: 'xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxx',
  // Api key is required so SDK can store and access data related to Revenue Path configuration 
});

Request API Key here.

Last updated