Follow the Step-By-Step Tutorial on how to cover basic operations such as granting and revoking roles, handling funding currencies, and managing fractions.

The CTS SDK is a package designed to facilitate interaction with blockchain contracts and querying of the subgraph for the CTS. This SDK leverages TypeChain and ethers.js libraries to provide seamless access to contract instances, utility functions, and a GraphQL API.

Functions

These methods facilitate interaction with different contract instances, generating FacetCut objects, and handling subgraph queries:

  1. getSubgraphSDK
  2. getDiamondFactoryOnChain
  3. getImplementationContractsOnChain
  4. getDiamondAsFacets
  5. getSelectors
  6. getFacetCutsAdd

Objects

These constants provide crucial information about contract addresses, asset types, roles, states, and GraphQL API endpoints:

  1. InitSelectors
  2. CONTRACT_ADDRESSES_NEXERA
  3. CONTRACT_ADDRESSES_TOKENIZER
  4. ASSET_TYPE_CODES_WRAPPER
  5. ROLES
  6. STATES
  7. GRAPHQL_APIS

Queries

The CTS Tokenizer SDK includes GraphQL queries that allow users to interact with the subgraph, enabling efficient data retrieval and filtering from the blockchain. Below is a detailed explanation of the available client-side query for the CTS Diamond Factory:

  1. DeployedAndInitialized

Key Features

  1. Contract Instances: Easily retrieve instances of deployed contracts, including DiamondFactory and various facets used in the CTS Tokenizer Diamond instances.
  2. Utility Functions: Useful functions for interacting with contracts, such as retrieving function selectors and generating FacetCut objects.
  3. GraphQL API: Simplified querying of the subgraph using a GraphQL client, providing access to blockchain data with filtering and pagination capabilities.