DocsReference

For developers

Everything you need to read Dibs state on-chain, build on it, or verify what the site tells you.

Network#

Value
ChainRobinhood Chain (Arbitrum Orbit L2)
Chain id4663
Public RPChttps://rpc.mainnet.chain.robinhood.com
Explorerrobinhoodchain.blockscout.com

Contracts#

Handle keys and vaults#

A handle key is the keccak-256 hash of the ABI-encoded provider name and permanent account id, both as strings:

castbash
# GitHub user octocat has id 583231
KEY=$(cast keccak $(cast abi-encode "f(string,string)" github 583231))

# the vault address for that key, deployed or not
cast call 0x2bA61A9340Dad6cfF946C547648aB3c4658BfCaE "predict(bytes32)(address)" $KEY --rpc-url https://rpc.mainnet.chain.robinhood.com

# is it bound, and to whom
cast call 0x2bA61A9340Dad6cfF946C547648aB3c4658BfCaE "bindings(bytes32)(address)" $KEY --rpc-url https://rpc.mainnet.chain.robinhood.com

Provider names are github and x. GitHub organisations use the same scheme as users.

Reading what a vault is owed#

bash
VAULT=$(cast call 0x2bA61A9340Dad6cfF946C547648aB3c4658BfCaE "predict(bytes32)(address)" $KEY --rpc-url https://rpc.mainnet.chain.robinhood.com)
# ETH waiting in the Pons escrow
cast call 0xd3AFEB2a57f70eF218Aa82451c51B2fb0416Ac9e "balanceOf(address)(uint256)" $VAULT --rpc-url https://rpc.mainnet.chain.robinhood.com
# a stock pair's fees, e.g. NVDA
cast call 0xd3AFEB2a57f70eF218Aa82451c51B2fb0416Ac9e "balanceOfToken(address,address)(uint256)" $VAULT 0xd0601CE157Db5bdC3162BbaC2a2C8aF5320D9EEC --rpc-url https://rpc.mainnet.chain.robinhood.com

On-chain conventions#

  • A Dibs coin is a Pons coin whose creatorFeeRecipient equals factory.predict(handleKey) for some handle key. That's the whole definition; anything launched that way, from any frontend, shows up on Dibs.
  • Logos are stored as ipfs://<cid>, the same convention Pons uses.
  • The description ends with Creator fees go to <profile url> via Dibs.

Public API#

EndpointReturns
POST /api/resolveBody { provider: "x" | "github", username }. The account id, handle key, key scheme and vault address.
GET /api/handle/<handleKey>/statsLive claimable balance and indexed totals for a handle.
GET /t/<token>Coin page, with Open Graph card at /t/<token>/opengraph-image.
GET /h/<provider>/<username>Handle page, with Open Graph card.
GET /sitemap.xmlEvery coin and handle page.
bash
curl -s https://www.dibs.family/api/resolve -H 'content-type: application/json' \
  -d '{"provider":"github","username":"octocat"}'

Write endpoints (launch registration, claims) are same-origin and session-bound; they are not a public API.