Skip to main content
POST
/
router
/
createMarket
Create market through router
curl --request POST \
  --url https://mainnet.base.org/router/createMarket \
  --header 'Content-Type: application/json' \
  --data '{
  "creator": "<string>"
}'
{
  "marketAddress": "<string>",
  "marketCounter": 123,
  "transactionHash": "<string>"
}
This is a smart contract write function. The curl example shown is for illustration. To call this function, use web3 libraries (ethers.js, viem, web3.py) or JSON-RPC directly.

Body

application/json
creator
string
required

Address of the market creator

Response

200 - application/json

Market created successfully through router

marketAddress
string

Address of the newly created market

marketCounter
integer

Counter/ID of the created market

transactionHash
string

Transaction hash of the market creation

I