v1

latestOpenAPI 3.0.02026-07-17823107.7 KB
Comments

Retrieve comments

Fetch comments with filters for author and pagination. If API access is restricted, you must include at least one of: author=<your own user ID> and/or author_is_staff=true - requests without one of these filters will be rejected.

get/api/comments/

Query parameters

postinteger

ID of the post to filter comments by.

authorinteger

Filter comments by author user ID. Use your own user ID to retrieve your comments.

author_is_staffboolean

When set to true, returns root-level comments authored by Metaculus staff (staff replies to other comments are not included). Treated as an 'OR' filter with author.

limitinteger

Number of comments to retrieve.

offsetinteger

Offset for pagination.

is_privateboolean

Filter between private comments (for the current user) and public comments. Defaults to false.

use_root_comments_paginationboolean

If true, pagination will only apply to root comments, and all child comments will be included for those root comments.

sort'-created_at' | 'created_at'

Sort comments by creation date. Use -created_at for descending order.

focus_comment_idinteger

The ID of a comment to place at the top of the results.

focus_thread_onlyboolean

When used alongside focus_comment_id, restricts the response to only the focused comment thread (the comment plus its root/siblings if it has a parent).

Response

List of comments

total_countinteger

Total number of root and child comments.

countinteger

Total number of root comments only.

nextstring uri nullable

URL for the next page of results, if available.

previousstring uri nullable

URL for the previous page of results, if available.