Skip to main content
createMarket deploys the market. Pass a metadata bag with copy or images and the client uploads files, then sets metadataURI. Empty metadata is skipped. Pass seedWei and oddsBps to call create-and-seed on the factory (approve the factory). Omit seedWei for create-only. You need a client that can send (walletClient or sendCalls) and a wallet with gas. Admin markets need marketAdmin. Committee markets need voters and threshold. image / outcomeImages can be a File, a Blob, or a public URL.
If metadata is present but the new address cannot be parsed from the receipt, it throws instead of leaving a silent unpublished market. Skip metadata if you have nothing to publish. After the market is live, treat the document as frozen in the product UI. market.setMetadata still exists for a retry if the upload failed after create. This is the one write that must live on the client — there is no market yet.

Next

List markets