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

# Get paginated post templates

> Get a paginated list of post templates available to your organisation.



## OpenAPI

````yaml /openapi/admin.json get /templates/posts
openapi: 3.1.0
info:
  title: Nudj Admin API
  version: 1.0.0
servers:
  - url: https://{subdomain}.nudj.cx/api/v2/admin
    description: Organization API Server
    variables:
      subdomain:
        description: Your organization's subdomain (required)
        default: your-org
security:
  - ApiToken: []
paths:
  /templates/posts:
    get:
      tags:
        - Templates
      summary: Get paginated post templates
      description: Get a paginated list of post templates available to your organisation.
      operationId: getPaginatedPostTemplates
      parameters:
        - in: query
          name: limit
          schema:
            type: integer
            minimum: 1
            maximum: 100
            default: 10
          required: false
        - in: query
          name: skip
          schema:
            type: integer
            minimum: 0
            default: 0
          required: false
        - in: query
          name: sort
          schema:
            type: string
        - in: query
          name: search
          schema:
            type: string
        - in: query
          name: communityId
          schema:
            type: string
        - in: query
          name: allocationId
          schema:
            type: string
        - in: query
          name: featured
          schema:
            type: boolean
        - in: query
          name: verified
          schema:
            type: boolean
        - in: query
          name: isShop
          schema:
            type: boolean
        - in: query
          name: type
          schema:
            type: string
        - in: query
          name: status
          schema:
            type: string
        - in: query
          name: eventCategory
          schema:
            type: string
        - in: query
          name: eventSubCategory
          schema:
            type: string
        - in: query
          name: eventName
          schema:
            type: string
        - in: query
          name: displayMode
          schema:
            type: string
        - in: query
          name: fromDate
          schema:
            type: string
        - in: query
          name: toDate
          schema:
            type: string
        - in: query
          name: isGlobalTemplate
          schema:
            type: boolean
        - in: query
          name: key
          schema:
            type: string
        - in: query
          name: progressPeriod
          schema:
            type: string
        - in: query
          name: expand
          schema:
            type: string
        - in: query
          name: redeemableType
          schema:
            type: string
        - in: header
          name: x-language
          description: >-
            The language to return the posts in. If not provided, the default
            language for the organisation will be used.
          schema:
            type: string
            description: >-
              The language to return the posts in. If not provided, the default
              language for the organisation will be used.
      responses:
        '200':
          description: Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  totalCount:
                    type: number
                  edges:
                    type: array
                    items:
                      $ref: '#/components/schemas/Post'
                required:
                  - totalCount
                  - edges
        '400':
          description: Invalid input data
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/error.BAD_REQUEST'
        '404':
          description: Not found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/error.NOT_FOUND'
        '500':
          description: Internal server error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/error.INTERNAL_SERVER_ERROR'
components:
  schemas:
    Post:
      type: object
      properties:
        id:
          type: string
          pattern: ^[0-9a-fA-F]{24}$
          description: The id of the post
        organisationId:
          type: string
          pattern: ^[0-9a-fA-F]{24}$
          description: The organisation that the post belongs to
        communityId:
          type: string
          pattern: ^[0-9a-fA-F]{24}$
          description: The community that the post belongs to
        details:
          allOf:
            - $ref: '#/components/schemas/Details'
          description: >-
            The details of this post such as title, description, bannerUrl,
            logoUrl
        content:
          type:
            - string
            - 'null'
          description: >
            The content of the post in HTML. Example: 

            <h1>Welcome to Your New Post</h1>

            <p>This is a placeholder post to demonstrate the capabilities of the
            editor. Feel free to explore and edit this content to see what you
            can do!</p>


            <h2>Basic Formatting</h2>

            <p>You can use <strong>bold</strong>, <em>italic</em>, underline,
            and <s>strikethrough</s> text to emphasize your content. </p>


            <h2>Lists</h2>

            <p>You can create a bullet list:  

            </p><ul data-tight="true" class="list-disc list-outside leading-3
            -mt-2 tight"><li class="leading-normal -mb-2"><p>Item 1</p></li><li
            class="leading-normal -mb-2"><p>Item 2</p></li><li
            class="leading-normal -mb-2"><p>Item 3 </p></li></ul><p>Or a
            numberered list:</p><ol data-tight="true" class="list-decimal
            list-outside leading-3 -mt-2 tight"><li class="leading-normal
            -mb-2"><p> First Item </p></li><li class="leading-normal
            -mb-2"><p>Second Item </p></li><li class="leading-normal
            -mb-2"><p>Third Item </p></li></ol>


            <h2>Links </h2>

            <p>You can also add links to your content. For example, visit <a
            href="https://www.example.com" class="underline
            underline-offset-[3px] hover:text-primary transition-colors
            cursor-pointer" rel="noopener noreferrer nofollow">Example.com</a>
            for more information. </p>


            <h2>Images </h2>

            <p>Including images is simple. Here is an example image: </p><img
            src="https://via.placeholder.com/150" class="rounded-lg border
            border-muted">


            <h2>Blockquotes </h2>

            <p>You can use blockquotes to highlight important quotes or
            information: </p><blockquote class="border-l-4
            border-primary"><p>"This is a sample blockquote. It's great for
            highlighting quotes or important information in your post."
            </p></blockquote><p></p>


            <p>Feel free to edit this content and explore the various features
            of the editor. Happy posting!</p>
        likes:
          type: array
          items:
            type: string
            pattern: ^[0-9a-fA-F]{24}$
          description: Array of user IDs who liked this post
        disableComments:
          type: boolean
          description: Whether comments are disabled on this post. Defaults to false.
        disableLikes:
          type: boolean
          description: Whether likes are disabled on this post. Defaults to false.
        displayBannerOnPost:
          type: boolean
          description: Whether to display a banner on this post. Defaults to false.
        status:
          type: string
          enum:
            - archived
            - draft
            - expired
            - live
            - scheduled
          description: The status of the post
        startsAt:
          type:
            - string
            - 'null'
          description: The date when this post becomes visible.
        expiresAt:
          type:
            - string
            - 'null'
          description: The date when this post expires.
        featured:
          type:
            - boolean
            - 'null'
        tags:
          type: array
          items:
            type: string
            pattern: ^[0-9a-fA-F]{24}$
          description: A list of tags to associate with this post
        campaigns:
          type: array
          items:
            type: string
            pattern: ^[0-9a-fA-F]{24}$
          description: A list of campaigns to associate with this post
        availableAsTemplateForOrganisations:
          type: array
          items:
            type: string
            pattern: ^[0-9a-fA-F]{24}$
          description: The organisations that the post is available as a template for
        isGlobalTemplate:
          type: boolean
          description: Whether the post is a global template
        createdAt:
          type: string
          description: The date when this post was created
        createdBy:
          type: string
          pattern: ^[0-9a-fA-F]{24}$
          description: The user who created this post
        updatedAt:
          type:
            - string
            - 'null'
          description: The date when this post was updated
        updatedBy:
          type:
            - string
            - 'null'
          pattern: ^[0-9a-fA-F]{24}$
          description: The user who last updated this post
        isEditing:
          type: boolean
      required:
        - id
        - organisationId
        - communityId
        - details
        - likes
        - disableComments
        - disableLikes
        - displayBannerOnPost
        - status
        - tags
        - campaigns
        - availableAsTemplateForOrganisations
        - isGlobalTemplate
        - createdAt
        - createdBy
        - isEditing
      title: Post
      description: A post
    error.BAD_REQUEST:
      type: object
      properties:
        message:
          type: string
          description: The error message
          example: Invalid input data
        code:
          type: string
          description: The error code
          example: BAD_REQUEST
        issues:
          type: array
          items:
            type: object
            properties:
              message:
                type: string
            required:
              - message
          description: An array of issues that were responsible for the error
          example: []
      required:
        - message
        - code
      title: Error
      description: The error information
      example:
        code: BAD_REQUEST
        message: Invalid input data
        issues: []
    error.NOT_FOUND:
      type: object
      properties:
        message:
          type: string
          description: The error message
          example: Not found
        code:
          type: string
          description: The error code
          example: NOT_FOUND
        issues:
          type: array
          items:
            type: object
            properties:
              message:
                type: string
            required:
              - message
          description: An array of issues that were responsible for the error
          example: []
      required:
        - message
        - code
      title: Error
      description: The error information
      example:
        code: NOT_FOUND
        message: Not found
        issues: []
    error.INTERNAL_SERVER_ERROR:
      type: object
      properties:
        message:
          type: string
          description: The error message
          example: Internal server error
        code:
          type: string
          description: The error code
          example: INTERNAL_SERVER_ERROR
        issues:
          type: array
          items:
            type: object
            properties:
              message:
                type: string
            required:
              - message
          description: An array of issues that were responsible for the error
          example: []
      required:
        - message
        - code
      title: Error
      description: The error information
      example:
        code: INTERNAL_SERVER_ERROR
        message: Internal server error
        issues: []
    Details:
      type: object
      properties:
        title:
          type: string
          description: The title of the entity
        description:
          type:
            - string
            - 'null'
          description: The description of the entity
        light:
          type: object
          properties:
            primaryImageUrl:
              type:
                - string
                - 'null'
              description: The url of the primary image for this theme mode
            secondaryImageUrl:
              type:
                - string
                - 'null'
              description: The url of the secondary image for this theme mode
          required:
            - primaryImageUrl
            - secondaryImageUrl
          description: Light theme images
        dark:
          type: object
          properties:
            primaryImageUrl:
              type:
                - string
                - 'null'
              description: The url of the primary image for this theme mode
            secondaryImageUrl:
              type:
                - string
                - 'null'
              description: The url of the secondary image for this theme mode
          required:
            - primaryImageUrl
            - secondaryImageUrl
          description: Dark theme images
      required:
        - title
        - description
        - light
        - dark
      description: Used to describe an entity
      title: Details
  securitySchemes:
    ApiToken:
      type: apiKey
      in: header
      name: x-api-token

````