GET /settings
The live network, contracts, fees, pair currencies and limits. Read this first.
GET https://marketmayhem.co/api/v1/settingsResponse
Section titled “Response”| Field | Type | Required | Meaning |
|---|---|---|---|
apiVersion | 1 | yes | The API version; /v1 is frozen |
chainId | integer | yes | 56 BSC mainnet, 97 BSC testnet |
network | string | yes | The network’s name |
contracts | object | yes | Every contract the API builds for |
contracts.factory | string | yes | A 0x address |
contracts.router | string | yes | A 0x address |
contracts.permit2 | string | yes | A 0x address |
contracts.quoter | string | yes | A 0x address |
contracts.wbnb | string | yes | A 0x address |
contracts.siteFeeRecipient | string | yes | A 0x address |
contracts.referrals | string or null | A 0x address | |
fees | object | yes | |
fees.siteFeeBps | integer | yes | The site fee on every trade, in basis points (100 = 1%) |
fees.referrerBps | integer | yes | The referrer’s part of it, in basis points of the trade (20 = 0.2%) |
fees.lifetimeReferralBps | integer | yes | A referrer’s lifetime share of our income from wallets bound to them (1500 = 15%) |
launch | object | yes | |
launch.paused | boolean | yes | True while launches are paused |
launch.launchFeeWei | string | yes | The launch fee in wei (0: launching is free) |
launch.feeTiers | object[] | yes | |
launch.feeTiers[].bps | integer | yes | |
launch.feeTiers[].label | string | yes | |
launch.feeTiers[].default | boolean | ||
launch.defaultFeeTier | integer | yes | The pool fee tier used when none is sent |
launch.defaultSupply | string | yes | The supply used when none is sent, in whole tokens |
pairs | object[] | yes | The listed pair currencies. Any BEP20 can also be a pair. |
pairs[].address | string | yes | The pair currency’s contract (WBNB for BNB) |
pairs[].decimals | integer | yes | Its decimals |
pairs[].symbol | string | yes | Its symbol, e.g. BNB |
pairs[].native | boolean | True for BNB, paid natively | |
limits | object | yes | |
limits.tradeDeadlineSeconds | integer | yes | How long a built trade stays valid |
limits.permitDays | integer | yes | How long the Permit2 approval to our router lasts |
limits.maxSlippageBps | integer | yes | The largest slippage a build accepts |
limits.defaultSlippageBps | integer | yes | The slippage used when none is sent |
A real response
Section titled “A real response”Captured from BSC testnet, exactly as the API sent it (long calldata shortened).
{ "apiVersion": 1, "chainId": 97, "network": "BSC Testnet", "contracts": { "factory": "0x5d96cbf410468950F92A1f544Ef924B24a23fe66", "router": "0xF265f08Ac720B4dCD6BA1928C5F13b0ff0bE207d", "permit2": "0x000000000022D473030F116dDEE9F6B43aC78BA3", "quoter": "0xbC203d7f83677c7ed3F7acEc959963E7F4ECC5C2", "wbnb": "0xae13d989daC2f0dEbFf460aC112a837C89BAa7cd", "siteFeeRecipient": "0xB583d753190a6b89db8158e82Ed04381471881DE", "referrals": "0xf462833D8e2cB5C59787552F7197152E5Af2b1D7" }, "fees": { "siteFeeBps": 100, "referrerBps": 20, "lifetimeReferralBps": 1500 }, "launch": { "paused": false, "launchFeeWei": "0", "feeTiers": [ { "bps": 100, "label": "0.01%" }, { "bps": 500, "label": "0.05%" }, { "bps": 2500, "label": "0.25%" }, { "bps": 10000, "label": "1%", "default": true } ], "defaultFeeTier": 10000, "defaultSupply": "1000000000" }, "pairs": [ { "symbol": "BNB", "address": "0xae13d989dac2f0debff460ac112a837c89baa7cd", "decimals": 18, "native": true }, { "symbol": "USDT", "address": "0x337610d27c682e347c9cd60bd4b3b107c9d34ddd", "decimals": 18 } ], "limits": { "tradeDeadlineSeconds": 1200, "permitDays": 30, "maxSlippageBps": 5000, "defaultSlippageBps": 50 }}