> ## Documentation Index
> Fetch the complete documentation index at: https://omniflow-vpn.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Post v1panelnotices preview

> Requires settings.write — a preview stores nothing, but it runs the renderer over caller-supplied text, and a read permission should not be a way to do that.
Renders a body against the notice's sample values, so an operator judges a message rather than a template. An empty body previews the shipped wording, which is what a customer would receive if nothing were saved. It refuses exactly what a save refuses, so a preview can never show something that could not then be stored.



## OpenAPI

````yaml https://raw.githubusercontent.com/kewldan/omniflow/main/api/openapi.yaml post /v1/panel/notices/{code}/preview
openapi: 3.0.3
info:
  title: Omniflow API
  version: 1.0.0
  description: >-
    Customer, commerce, payment, wallet, fulfillment, and operations API for
    Omniflow.
servers: []
security: []
paths:
  /v1/panel/notices/{code}/preview:
    post:
      tags:
        - panel
      description: >-
        Requires settings.write — a preview stores nothing, but it runs the
        renderer over caller-supplied text, and a read permission should not be
        a way to do that.

        Renders a body against the notice's sample values, so an operator judges
        a message rather than a template. An empty body previews the shipped
        wording, which is what a customer would receive if nothing were saved.
        It refuses exactly what a save refuses, so a preview can never show
        something that could not then be stored.
      operationId: previewPanelNotice
      parameters:
        - in: path
          name: code
          required: true
          schema:
            type: string
        - $ref: '#/components/parameters/CSRFToken'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              required:
                - locale
              properties:
                locale:
                  type: string
                  enum:
                    - en
                    - ru
                body:
                  type: string
                  maxLength: 2000
                  description: Empty previews the shipped wording.
      responses:
        '200':
          description: Preview
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PanelNoticePreview'
        '403':
          $ref: '#/components/responses/Problem'
        '422':
          $ref: '#/components/responses/Problem'
components:
  parameters:
    CSRFToken:
      in: header
      name: X-CSRF-Token
      required: true
      description: >-
        Echoes the token from the current session. Required on every unsafe
        method.
      schema:
        type: string
  schemas:
    PanelNoticePreview:
      type: object
      required:
        - rendered
      properties:
        rendered:
          type: string
        placeholders:
          type: array
          description: >-
            What the body actually used, which is how an operator notices they
            deleted {days} from the expiry warning.
          items:
            type: string
    Problem:
      type: object
      required:
        - type
        - title
        - status
      properties:
        type:
          type: string
          format: uri
        title:
          type: string
        status:
          type: integer
        detail:
          type: string
        request_id:
          type: string
  responses:
    Problem:
      description: Request failed
      content:
        application/problem+json:
          schema:
            $ref: '#/components/schemas/Problem'

````

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