Coin Queries
The Coins SDK provides a comprehensive set of query functions to fetch information about coins, profiles, and related data.
Overview
The query functions are divided into several categories:
- Coin Queries: Retrieve information on specific coins such as metadata, market data, and comments
- Profile Queries: Retrieve information associated with users/wallets like holdings and activity
- Explore Queries: Retrieve information about all coins (new, trending, top gainers, etc.)
- Leaderboard: Featured creators and weekly trader leaderboard (defaults to current week/year if not specified)
Using the REST API
The Coins SDK can be used from any programming language via the Public REST API. This includes:
- Interactive API documentation with live testing
- Authentication with API keys
- Code examples in multiple languages (Python, Go, Ruby, etc.)
- OpenAPI specification
For JavaScript/TypeScript usage, continue reading below. For other languages, see the Public REST API documentation.
API Key Setup
Before using the API queries in a high-usage production environment, set up an API key:
import { setApiKey } from "@zoralabs/coins-sdk";
// Set up your API key
setApiKey("your-api-key-here");To obtain an API key:
- Log in or create an account on Zora
- Navigate to Developer Settings
- Create an API key
- Use the API key in the SDK
For detailed authentication instructions and REST API usage, see the Public REST API documentation.
