Skip to main content
This page maps the SDK. How prices, Invalid, liquidity, and settlement work is in How VOIZ works. You never construct a market by hand. You build one client, then ask it for markets that already exist, for one market, for one answer, or for one wallet. A catalog card for “Will ETH be above $5,000 at year end?” shows the name and Yes / No from the list. Pictures and copy are metadata. They are not on that list. The indexer is for catalogs, charts, and portfolios. The chain is for a size you can trade.

Pool is one answer, not a second market

A pool handle is one named answer on the same market maker. It is not a second pool. Trades go through that handle, not the market address. Buying Yes on the ETH question moves No as well. In code:

Invalid

Invalid is the outcome for “this question does not count.” It is minted whenever a complete set is split, so split and merge always close. It is not a tradable named answer. Display prices list Yes and No only. Buy and sell of Invalid revert. If the question is ruled not to count, Invalid pays 1. Resolve with the index after the last named answer. On an admin resolver the SDK calls reportInvalid. The indexer catalog omits Invalid from the token list. A chain snapshot includes it. Use the chain snapshot when you need the Invalid token for merge.

Market vs metadata

The protocol summary and the catalog list give you the on-chain facts: name, answers, tokens, and whether the market is resolved. Pictures and copy are not on that object. Ask the market:
Want a thumbnail on a catalog card? Call client.market(row.address).metadata(). Do not wait for the list to include images. When you create a market, pass metadata in that call. The client deploys, then uploads files and sets the metadata URI. Use market.setMetadata only if you need a retry.

Collateral and outcomes

Each market has one collateral token (USDC on Base and Polygon), a token per named answer, and Invalid on chain. First liquidity and later liquidity both add funding on that single market maker.

Indexer vs chain

Do not treat an empty catalog as “indexer down”. That is the portfolio/history path. Display prices can lag a bit. Never size a swap from them. user.sharePositions() is the indexer share list only. It does not overlay live ERC-20 balances.

Quotes vs writes

Seed: the first deposit opens trading. It is not a bet. Invalid has no opening weight. In code, quoteSeed restates the deposit amount and market.seed is that first liquidity add. Later addLiquidity joins the mix the pool already has. Trade: quote a size, then swap that size. A quote may cap you. Buy is collateral to an answer; sell is the reverse. You apply slippage to the minimum you will accept. LP: later liquidity is more inventory, not a bet on Yes. Mechanics and risk: How liquidity provision works.

How writes go out

Pass sendCalls when you use Privy or account abstraction (many inner calls, one UserOp), or a walletClient (each inner call is its own transaction). requiredSigner is a hint for an account-abstraction sender that has more than one key. A normal wallet ignores it and signs with the connected account.

Next

If you came here to publish a market: create, then seed unless the first deposit already rode along.