> ## Documentation Index
> Fetch the complete documentation index at: https://docs.sazabi.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Apply a status page's structure

> Replace the page's sections and surfaces from one document, matched by key. Surfaces dropped from the document are removed; their history stays on past reports. With dryRun, returns the diff without writing.



## OpenAPI

````yaml /openapi.json put /status-pages/{statusPageId}/structure
openapi: 3.1.1
info:
  title: Sazabi Public API
  version: 1.0.0
  description: >
    Public REST API for Sazabi. Authenticate using a secret API key in the
    Authorization header.


    ## Pagination


    This API uses two pagination strategies depending on the endpoint type:


    ### Cursor-Based Pagination (List Endpoints)


    List endpoints (threads, messages, keys) use cursor-based pagination for
    efficient, consistent results:


    - **Parameters**: `limit` (items per page, default 50, max 100), `cursor`
    (opaque pagination token)

    - **Response**: Includes `nextCursor` field - pass this as `cursor` in the
    next request

    - **End of results**: When `nextCursor` is `null`, there are no more results

    - **Example**: `GET
    /v1/threads?limit=20&cursor=01234567-89ab-cdef-0123-456789abcdef`


    ### Page-Based Pagination (Search Endpoints)


    Search endpoints use page-based pagination due to the underlying search
    engine:


    - **Parameters**: `limit` (items per page, default 20, max 100), `page`
    (1-indexed page number)

    - **Response**: Includes `pagination` object with `page`, `limit`,
    `totalResults`, `totalPages`

    - **Example**: `GET /v1/search/threads?q=error&limit=10&page=2`
servers:
  - url: https://api.sazabi.com/v1
    description: Production
security: []
paths:
  /status-pages/{statusPageId}/structure:
    put:
      tags:
        - StatusPages
      summary: Apply a status page's structure
      description: >-
        Replace the page's sections and surfaces from one document, matched by
        key. Surfaces dropped from the document are removed; their history stays
        on past reports. With dryRun, returns the diff without writing.
      operationId: statusPages.structure.put
      parameters:
        - name: statusPageId
          in: path
          required: true
          schema:
            type: string
            minLength: 1
            maxLength: 64
            description: Status page ID (UUID) or slug.
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                dryRun:
                  type: boolean
                  default: false
                  description: Return the diff without writing anything.
                sections:
                  type: array
                  maxItems: 20
                  items:
                    type: object
                    properties:
                      key:
                        type: string
                        pattern: ^[a-z0-9](?:[a-z0-9._-]{0,62}[a-z0-9])?$
                        description: >-
                          Stable key of a section or surface, unique within the
                          page: lowercase letters, digits, '.', '_' and '-'.
                      name:
                        type: string
                        minLength: 1
                        maxLength: 120
                      description:
                        anyOf:
                          - type: string
                            maxLength: 500
                          - type: 'null'
                        description: Short text shown under the section's name.
                      collapsedByDefault:
                        type: boolean
                      surfaces:
                        type: array
                        maxItems: 100
                        items:
                          type: object
                          properties:
                            key:
                              type: string
                              pattern: ^[a-z0-9](?:[a-z0-9._-]{0,62}[a-z0-9])?$
                              description: >-
                                Stable key of a section or surface, unique
                                within the page: lowercase letters, digits, '.',
                                '_' and '-'.
                            name:
                              type: string
                              minLength: 1
                              maxLength: 120
                            description:
                              anyOf:
                                - type: string
                                  maxLength: 500
                                - type: 'null'
                              description: Short text shown under the surface's name.
                            showUptime:
                              type: boolean
                              description: Show the 90-day uptime bar. Defaults to true.
                          required:
                            - key
                            - name
                        default: []
                    required:
                      - key
                      - name
                  default: []
                surfaces:
                  type: array
                  maxItems: 100
                  items:
                    type: object
                    properties:
                      key:
                        type: string
                        pattern: ^[a-z0-9](?:[a-z0-9._-]{0,62}[a-z0-9])?$
                        description: >-
                          Stable key of a section or surface, unique within the
                          page: lowercase letters, digits, '.', '_' and '-'.
                      name:
                        type: string
                        minLength: 1
                        maxLength: 120
                      description:
                        anyOf:
                          - type: string
                            maxLength: 500
                          - type: 'null'
                        description: Short text shown under the surface's name.
                      showUptime:
                        type: boolean
                        description: Show the 90-day uptime bar. Defaults to true.
                    required:
                      - key
                      - name
                  default: []
                  description: Surfaces at the page's top level, outside any section.
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                type: object
                properties:
                  dryRun:
                    type: boolean
                  created:
                    type: array
                    items:
                      type: string
                    description: Keys of new sections and surfaces.
                  updated:
                    type: array
                    items:
                      type: string
                    description: >-
                      Keys of sections and surfaces whose fields or position
                      changed.
                  removed:
                    type: array
                    items:
                      type: string
                    description: >-
                      Keys dropped from the document. Their history stays on
                      past reports.
                required:
                  - dryRun
                  - created
                  - updated
                  - removed

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.