DaVinciGraph Default User Avatar

Davincigraph Pics API: V2

Introducing our specialized API designed to provide visual assets for Hedera-based entities such as Tokens, Contracts, Accounts, and Nodes. Token owners and account holders can upload custom images for their respective entities through our user interface. Our API is versatile, accommodating not just standalone tokens but also LP tokens and wrapped tokens by dynamically pointing to the relevant original or pair token images. Additionally, for wrapped tokens originating from networks other than Hedera, our administrators manually add these foreign token images to ensure a comprehensive visual dataset.
Base URL (Main Server)https://s1.pics.davincigraph.io
Base URL (Mirror Server)https://s2.pics.davincigraph.io
Read only
Key Enhancements in Version 2
  • Query performance has tripled in speed compared to Version 1.
  • Enhanced bulk retrieval options now include increased limits and the ability to fetch items from specific networks or retrieve multiple specified items simultaneously.
  • Version 2 now supports the handling of contract images.
  • The structure of Wrapped tokens has been updated to mimic that of simple tokens, where the picture URL, title, and sensitivity now automatically reference the original token.
  • Introducing a dark theme: Resources can now feature two distinct sets of pictures, one for light themes and another for dark themes.
  • All responses, including error messages, are uniformly formatted in JSON with the structure {message: string}

DaVinciPics Packages

To make working with the DavinciPics API easier, we offer specialized packages for different needs:

davinci-pic Web Component (custom element): This web component helps you effortlessly fetch the appropriate image from our API by using its identifier. It's compatible with pure HTML, Angular, and Vue.js. Get the package from our GitHub repository.

DavinciPic React Component: This React component also lets you conveniently retrieve the relevant image from our API using its identifier. Download the package from our GitHub repository.

DavinciPicSignal: This package allows your dapp to easily communicate information about wrapped or LP tokens, as well as suggest foreign tokens that should be added. Download this package from our GitHub repository.

Using these packages, you can mostly avoid interacting with the API directly. However, you're free to do so if you wish to implement your own custom logic.

Guidelines for Using Version 2
  • To display images of entities without requiring an API key, integrate the API directly within your front-end.
  • For faster data retrieval, use the supplementary scope, as resources within this scope are cached.
  • The API configures your front-end to cache responses for 6 hours. Adhering to this caching period is recommended to optimize performance.
  • Employ HTML Intersection Observer for sending requests; setting an appropriate margin ensures seamless operation and reduces unnecessary requests.

Resources

The API provides access to six resources: Tokens, Contracts, Accounts, Nodes, Networks, and Apps. See the corresponding endpoints listed below:

Tokens

GET
/api/v2/tokens/{network}/{address}
Get a resource by its network & address, PUBLIC Route
GET
/api/v2/tokens
Get a list of tokens, PRIVATE Route
PUT
/api/v2/tokens/{network}/{address}
Create a refrense token (Dex & Bridge apps only)

Contracts

GET
/api/v2/contracts/{network}/{address}
Get a Contract by its network & address, PUBLIC Route
GET
/api/v2/contracts
Get a list of contracts, PRIVATE Route
PUT
/api/v2/contracts/{network}/{address}
Create a refrense contract (Dexes only)

Accounts

GET
/api/v2/accounts/{network}/{address}
Get an account by its network & address
GET
/api/v2/accounts
Get a list of accounts, PRIVATE Route

Nodes

GET
/api/v2/nodes/{network}/{address}
Get a node by its network & address
GET
/api/v2/nodes
Get a list of nodes, PRIVATE Route

Networks

GET
/api/v2/networks/{network}
Get a network by its ID
GET
/api/v2/networks
Get a list of networks, PRIVATE Route

Apps

GET
/api/v2/apps/{name}
Get an App by its Name
GET
/api/v2/apps
Get a list of apps, PRIVATE Route

Cache

Resources retrieved from single retrieval routes with "supplementary" are stored temporarily to speed up future access. These cached data last for 6 hours both on server and client side. The cache always contains the most recent version of the resources. If any updates occur to the resources, the cache will be cleared and replaced with the new information (This doesn't apply to complex tokens).

Rate Limit

Each user has a limit of 250 API requests per minute. However, applications that send signals to the API are granted a higher request rate. If you find that you need an even higher rate, it can be further increased upon request.