From fa4dba4da3d3c7002fdb7227376c4cc493d51f34 Mon Sep 17 00:00:00 2001 From: Austin Chen Date: Wed, 12 Oct 2022 17:26:00 -0700 Subject: [PATCH] Document the new /comment endpoint --- docs/docs/api.md | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/docs/docs/api.md b/docs/docs/api.md index d25a18be..5caf9f86 100644 --- a/docs/docs/api.md +++ b/docs/docs/api.md @@ -680,6 +680,17 @@ $ curl https://manifold.markets/api/v0/market/{marketId}/sell -X POST \ --data-raw '{"outcome": "YES", "shares": 10}' ``` +### `POST /v0/comment` + +Creates a comment in the specified market. Only supports top-level comments for now. + +Parameters: + +- `contractId`: Required. The ID of the market to comment on. +- `content`: The comment to post, formatted as [TipTap json](https://tiptap.dev/guide/output#option-1-json), OR +- `html`: The comment to post, formatted as an HTML string, OR +- `markdown`: The comment to post, formatted as a markdown string. + ### `GET /v0/bets` Gets a list of bets, ordered by creation date descending.