v52

latestOpenAPI 3.0.3raw.githubusercontent.com2026-07-2113138232.4 KB
pages

pages

Create a new custom page. Requires administrative privileges.

    ### Body Parameter Guidelines:
    - **title**: Heading displayed at the top of the page.
    - **slug**: URL path identifier. Must be unique and URL-safe.
    - **body_markdown**: Content written in Markdown format.
    - **body_json**: Optional JSON payload for API-consumed/structured data pages.
    - **is_top_level_path**: Set to `true` to serve the page directly at the root (e.g. `/{slug}`) instead of under the default namespace `/page/{slug}`. Use with caution to avoid namespace collisions with core Forem paths.
    - **template**: Layout styling options (`contained` or custom layouts).
post/api/pages

Request body

titlestring

Title of the page

slugstring

Used to link to this page in URLs, must be unique and URL-safe

descriptionstring

For internal use, helps similar pages from one another

body_markdownstring

The text (in markdown) of the page (required)

body_jsonstring

For JSON pages, the JSON body

is_top_level_pathboolean

If true, the page is available at '/{slug}' instead of '/page/{slug}', use with caution

template'contained' | 'full_within_layout' | 'nav_bar_included' | 'json' | 'css' | 'txt'

Controls what kind of layout the page is rendered in

Response

successful