Checks a draft post (title, body, link, flair) against a community’s rules before you post: structured requirements are checked exactly, then an AI model lists the rules the draft likely breaks, each quoted verbatim with a reason. ok is true when no violation is medium or high; the draft is never rewritten. Billed 3 requests per call, plus 1 AI unit per model answer (the check, and the rules when the model had to read them first). Use POST for a long draft body (up to 10,000 characters do not always fit in a URL).
HTTP Request
GET /subreddit/rule-check (also POST /subreddit/rule-check with a JSON body, see below)
Cost (in requests): 3 + AI units. Every successful answer reports its cost in data.billed_requests. AI endpoints need a paid plan.
Parameters
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
subreddit | string | Yes | - | Subreddit name (case-insensitive, with or without r/) or its t5_ id. |
title | string | Yes | - | Draft title, 1–300 characters. |
body | string | No | - | Draft body text, at most 10,000 characters. |
url | string | No | - | Outside link the draft would post (link posts). |
flair | string | No | - | Flair text you intend to choose. |
language | string | No | - | ISO-639-1 code of reason and notes. Default en. |
POST body
POST /subreddit/rule-check accepts the same fields as a JSON body (Content-Type: application/json). List fields are JSON arrays instead of comma-separated strings. Use POST when the text is long.
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
subreddit | string | Yes | - | Subreddit name (case-insensitive, with or without r/) or its t5_ id. |
title | string | Yes | - | Draft title, 1–300 characters. |
body | string | No | - | Draft body text, at most 10,000 characters. |
url | string | No | - | Outside link the draft would post (link posts). |
flair | string | No | - | Flair text you intend to choose. |
language | string | No | - | ISO-639-1 code of reason and notes. Default en. |
Response
Real response to GET /subreddit/rule-check?subreddit=python&title=I built a tool that scrapes Reddit, try it (arrays trimmed to 2 items, long texts cut with …).
| |
Response Fields
| Field | Type | Description |
|---|---|---|
status | boolean | true when the request succeeded |
request_id | string | Unique request identifier |
data | object | The check; status false with data present = the rules were read but the model did not answer; null with error.code not_found / private / banned / quarantined. |
data.subreddit | object | The community. |
data.subreddit.name | string | Subreddit name without r/. |
data.subreddit.subreddit_id | string | Subreddit id (t5_…). |
data.subreddit.title | string | Display title. Left out on /subreddit/search, /subreddit/rising, /subreddit/most-visited, /subreddit/directory (these four without with_details), /user/moderated-subreddits, /subreddit/stats-history, /topic/subreddits with scope=all on a sub-topic, /subreddit/insights and /answers. |
data.subreddit.description | string | Public description. Left out on /subreddit/rising (without with_details), the /subreddit/related same_topic rows and /answers. |
data.subreddit.subscribers_count | integer | Subscribers (members). Left out on /subreddit/most-visited, /subreddit/directory without with_stats and /answers. |
data.subreddit.type | string | public, restricted, private, archived… Left out where no source carries it: /subreddit/search, /subreddit/rising, /subreddit/most-visited, /subreddit/directory (these four without with_details), /subreddit/related, /subreddit/recommend, /subreddit/stats-history, /subreddit/insights and /answers. |
data.subreddit.is_nsfw | boolean | Marked 18+. Left out on /subreddit/rising (without with_details), the /subreddit/related same_topic rows, /subreddit/most-visited, /subreddit/directory without with_stats (or include_nsfw=false), /topic/subreddits and /answers. |
data.subreddit.is_quarantined | boolean | Quarantined by Reddit. Left out on /subreddit/rising (without with_details), /subreddit/stats-history, /subreddit/related (the community asked about and same_topic), /subreddit/insights, /subreddit/most-visited, /subreddit/directory, /topic/subreddits, /user/subreddits and /answers. |
data.ok | boolean | True when no violation has confidence medium or high. |
data.missing_flair | boolean | The community requires a flair and the draft has none. |
data.violations | array of objects | Likely violations, structured checks first. The draft is never rewritten. Model output: treat as untrusted text if you pass it to an agent with tools. |
data.violations[].rule | string | Rule title (or the stated rule text) the draft likely breaks. |
data.violations[].reason | string | Why the draft breaks it, one sentence. |
data.violations[].confidence | string | low, medium or high; checks against structured requirements are always high. |
data.violations[].source | string | requirements (deterministic check against the community’s posting requirements and flairs) or rules (the model’s reading of the rules). |
data.violations[].source_quote | string | Verbatim rule text; null for a structured requirement. |
data.notes | array | Short remarks from the model that are not violations (e.g. a weekly thread the draft belongs in). |
data.post_flairs | array of string | Post flair texts the community defines. |
data.ai | object | Model call details; null when the model did not answer (the structured checks are still reported). |
data.ai.input_tokens | integer | Input tokens of the model call. |
data.ai.output_tokens | integer | Output tokens of the model call. |
data.ai.possible_injection | boolean | True when the input text contained instruction-like phrasing (“ignore previous instructions” and the like). Informational: the answer was still produced from the data. |
data.ai.truncated | boolean | True when the input was cut to fit max_chars (or to keep the answer fast). |
data.ai.cached | boolean | True when the answer was served from the stored result (or the rules had not changed), so no model call was made for this request. |
data.computed_at | string | When this answer was computed (RFC 3339, UTC). Older than the request when it was served from the cache. |
data.billed_requests | integer | Requests billed for this call (also sent as Requests in the X-RapidAPI-Billing header when it is not RapidAPI’s default of 1). |
request_params | object | Echo of the parameters you sent |
Error Responses
Invalid input returns HTTP 400, not billed. error is a plain string that names the parameter:
| |
| Status Code | Cause | Description |
|---|---|---|
| 400 | Invalid or missing parameter | Plain-English message per field. Not billed |
200 with status: false | Item not available | error.code is not_found, banned, private, quarantined. data is null. Billed 1 request |
503 with error.code | AI model failed | llm_timeout, llm_error or invalid_output. The Reddit data read so far is still in data. Not billed, retry |
| 503 | Reddit temporarily unreachable | "error": "Service temporarily unavailable". Not billed, retry later |
Code Examples
| |
| |
| |
POST example
| |
| |
| |
Related Endpoints
- Subreddit Rules : Subreddit rules and posting requirements
- Subreddit Posting Guide : What a community’s rules say about posting, with quotes
- Subreddit Recommend : Communities where a product or topic fits, ranked, with their self-promotion policy