diff --git a/docs/docs/api.md b/docs/docs/api.md index e7e6a341..a25d245c 100644 --- a/docs/docs/api.md +++ b/docs/docs/api.md @@ -115,10 +115,10 @@ Requires no authorization. outcomeType: string // BINARY, FREE_RESPONSE, or NUMERIC mechanism: string // dpm-2 or cpmm-1 - pool: number // sum of YES and NO shares in liquidity pool for CPMM, null for DPM probability: number - p?: number // probability constant in y^p * n^(1-p) = k - totalLiquidity?: number + pool: { outcome: number } // For CPMM markets, the number of shares in the liquidity pool. For DPM markets, the amount of mana invested in each answer. + p?: number // CPMM markets only, probability constant in y^p * n^(1-p) = k + totalLiquidity?: number // CPMM markets only, the amount of mana deposited into the liquidity pool volume: number volume7Days: number diff --git a/web/pages/api/v0/_types.ts b/web/pages/api/v0/_types.ts index 4909efc9..d3a74053 100644 --- a/web/pages/api/v0/_types.ts +++ b/web/pages/api/v0/_types.ts @@ -24,7 +24,7 @@ export type LiteMarket = { outcomeType: string mechanism: string - pool: number + pool: { [outcome: string]: number } probability?: number p?: number totalLiquidity?: number @@ -96,7 +96,7 @@ export function toLiteMarket(contract: Contract): LiteMarket { description, tags, url: `https://manifold.markets/${creatorUsername}/${slug}`, - pool: pool.YES + pool.NO, + pool, probability, p, totalLiquidity,