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

# Create a palette

> Creates a palette of solid colours, each with an optional CMYK value and spot colour name for print.



## OpenAPI

````yaml openapi.json POST /v2/palettes
openapi: 3.1.0
info:
  title: Print.App API
  version: 2.1.0
  description: >-
    Server-to-server API for Print.App integrations: designs and their page
    content, folders, files, fonts, palettes, product assignments, projects and
    editor links. Authenticate every request with a secret key: `Authorization:
    Bearer sk_…`. Never call it from a browser.
servers:
  - url: https://api.print.app
    description: Production
security:
  - bearerAuth: []
tags:
  - name: Account
    description: The account a secret key belongs to.
  - name: Designs
    description: >-
      The designs (templates) your customers start from: create them at a size,
      manage their pages, and place text, images and shapes on them.
  - name: Design folders
    description: >-
      Folders that organise your designs. A design can sit in more than one
      folder.
  - name: Files
    description: >-
      Your own images and graphics, used in designs and offered to customers in
      the editor.
  - name: Graphic folders
    description: >-
      Folders of files, shown in the editor under Pictures, Backgrounds,
      Textures or Frames.
  - name: Fonts
    description: >-
      The fonts your designs and customers can use: the built-in set, imported
      Google fonts and fonts you upload.
  - name: Palettes
    description: Colour palettes offered in the editor.
  - name: Products
    description: Which designs open for each product (and variant) in your store.
  - name: Projects
    description: Your customers' saved designs.
  - name: Links
    description: Shareable editor links that open a design or project at create.print.app.
paths:
  /v2/palettes:
    post:
      tags:
        - Palettes
      summary: Create a palette
      description: >-
        Creates a palette of solid colours, each with an optional CMYK value and
        spot colour name for print.
      operationId: createPalette
      parameters:
        - $ref: '#/components/parameters/IdempotencyKey'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/PaletteCreate'
            example:
              title: Brand
              colors:
                - name: Navy
                  hex: '#1f2a44'
                  cmyk: 100,80,30,40
                - name: Gold
                  hex: '#c9a227'
                  spot: PANTONE 7753 C
      responses:
        '201':
          description: Created.
          headers:
            x-request-id:
              $ref: '#/components/headers/RequestId'
            idempotent-replayed:
              $ref: '#/components/headers/IdempotentReplayed'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Palette'
              example:
                object: palette
                id: folder:8a1d2c3b-4e5f-4a6b-8c7d-9e0f1a2b3c4d
                title: Brand
                colors:
                  - name: Navy
                    type: solid
                    hex: '#1f2a44'
                    cmyk: 100,80,30,40
                    spot: null
                builtIn: false
                created: '2026-10-27T10:00:00Z'
                modified: '2026-10-27T10:00:00Z'
        '400':
          description: >-
            A parameter or body field is malformed: `param` names it and
            `details` lists every problem found.
          headers:
            x-request-id:
              $ref: '#/components/headers/RequestId'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
              example:
                error: true
                code: invalid_request
                message: width is required.
                param: width
                requestId: FZn-uhymjoEEJow=
        '401':
          description: Missing, unknown, revoked or expired secret key.
          headers:
            x-request-id:
              $ref: '#/components/headers/RequestId'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
              example:
                error: true
                code: unauthorized
                message: >-
                  Missing or invalid secret key. Send it as "Authorization:
                  Bearer sk_…".
                requestId: FZn-uhymjoEEJow=
        '403':
          description: The account is suspended for an unpaid invoice.
          headers:
            x-request-id:
              $ref: '#/components/headers/RequestId'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
              example:
                error: true
                code: account_suspended
                message: >-
                  This account is suspended. Settle the outstanding invoice in
                  the Print.App dashboard.
                requestId: FZn-uhymjoEEJow=
        '415':
          description: The body is not JSON.
          headers:
            x-request-id:
              $ref: '#/components/headers/RequestId'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
              example:
                error: true
                code: unsupported_media_type
                message: >-
                  Send the request body as JSON, with "Content-Type:
                  application/json".
                requestId: FZn-uhymjoEEJow=
        '429':
          description: >-
            Rate limited by the API gateway. Back off and retry. This response
            comes from the gateway, so its body is `{ "message": "Too Many
            Requests" }`, not the standard error.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GatewayError'
              example:
                message: Too Many Requests
        '500':
          description: >-
            Something failed on our side. Retry; quote the requestId to support
            if it persists.
          headers:
            x-request-id:
              $ref: '#/components/headers/RequestId'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
              example:
                error: true
                code: internal_error
                message: >-
                  Something went wrong on our side. Retry the request; if it
                  keeps failing, contact support with the requestId.
                requestId: FZn-uhymjoEEJow=
components:
  parameters:
    IdempotencyKey:
      name: Idempotency-Key
      in: header
      required: false
      schema:
        type: string
        minLength: 1
        maxLength: 255
      description: >-
        Makes a retry safe: a second request with the same key and the same body
        gets the first response back (for 24 hours) instead of creating the
        resource again. Use a new key, such as a UUID, for every new request.
  schemas:
    PaletteCreate:
      title: PaletteCreate
      description: A new palette.
      type: object
      additionalProperties: false
      required:
        - title
        - colors
      properties:
        title:
          type: string
          minLength: 1
          maxLength: 200
          description: The palette's name.
        colors:
          type: array
          maxItems: 500
          items:
            type: object
            additionalProperties: false
            required:
              - hex
            properties:
              name:
                type: string
                maxLength: 100
                description: The colour's name, shown in the editor.
              hex:
                type: string
                format: color
                description: The screen colour, `#rrggbb`.
              cmyk:
                type: string
                pattern: ^\d{1,3},\d{1,3},\d{1,3},\d{1,3}$
                description: >-
                  The print colour as `c,m,y,k` percentages, for example
                  `0,16,100,0`.
              spot:
                type: string
                maxLength: 100
                description: A spot colour name for print, for example `PANTONE 186 C`.
          description: The colours, in order.
      examples:
        - title: Brand
          colors:
            - name: Navy
              hex: '#1f2a44'
              cmyk: 100,80,30,40
            - name: Gold
              hex: '#c9a227'
              spot: PANTONE 7753 C
    Palette:
      title: Palette
      description: A colour palette.
      type: object
      required:
        - object
        - id
        - title
        - colors
        - builtIn
        - created
        - modified
      properties:
        object:
          type: string
          const: palette
        id:
          type: string
        title:
          type:
            - string
            - 'null'
        colors:
          type: array
          items:
            type: object
            required:
              - name
              - type
              - hex
              - cmyk
              - spot
            properties:
              name:
                type:
                  - string
                  - 'null'
              type:
                type: string
                enum:
                  - solid
                  - foil
                  - gradient
                  - texture
              hex:
                type:
                  - string
                  - 'null'
                description: '`#rrggbb` for solid colours.'
              cmyk:
                type:
                  - string
                  - 'null'
              spot:
                type:
                  - string
                  - 'null'
        builtIn:
          type: boolean
          description: >-
            Provided by Print.App: it cannot be changed, only hidden by deleting
            it.
        created:
          type:
            - string
            - 'null'
          format: date-time
        modified:
          type:
            - string
            - 'null'
          format: date-time
      examples:
        - object: palette
          id: folder:8a1d2c3b-4e5f-4a6b-8c7d-9e0f1a2b3c4d
          title: Brand
          colors:
            - name: Navy
              type: solid
              hex: '#1f2a44'
              cmyk: 100,80,30,40
              spot: null
          builtIn: false
          created: '2026-10-27T10:00:00Z'
          modified: '2026-10-27T10:00:00Z'
    Error:
      title: Error
      description: >-
        Every error the API itself returns. Match on `code`; `message` is for
        people and may be reworded.
      type: object
      required:
        - error
        - code
        - message
        - requestId
      properties:
        error:
          type: boolean
          const: true
        code:
          type: string
          enum:
            - unauthorized
            - account_suspended
            - invalid_request
            - not_found
            - route_not_found
            - idempotency_key_reused
            - idempotency_in_progress
            - folder_not_empty
            - builtin_folder
            - builtin_palette
            - editor_not_supported
            - design_changed
            - payload_too_large
            - unsupported_media_type
            - ops_failed
            - internal_error
            - service_unavailable
          description: >-
            `unauthorized` (401): missing, unknown, revoked or expired secret
            key. `account_suspended` (403): the account has an unpaid invoice.
            `invalid_request` (400): a parameter or body field is malformed —
            see `param` and `details`. `not_found` (404): no such resource in
            your account. `route_not_found` (404): no such endpoint.
            `idempotency_key_reused` (409): the Idempotency-Key was used for a
            different request. `idempotency_in_progress` (409): the first
            request with that key is still running. `folder_not_empty` (409):
            the folder still holds designs or folders. `builtin_folder`,
            `builtin_palette` (409): Print.App's own folders and palettes cannot
            be changed. `editor_not_supported` (409): page content can only be
            edited on accounts that use the new editor. `design_changed` (409):
            the design was saved elsewhere while the batch ran; read it again
            and retry. `payload_too_large` (413): a body or file over the limit.
            `unsupported_media_type` (415): send JSON. `ops_failed` (422): an
            operation in the batch failed, nothing was saved — see `details`.
            `internal_error` (500): retry; contact support with the `requestId`
            if it persists. `service_unavailable` (503): retry in a few seconds.
        message:
          type: string
        param:
          type: string
          description: The parameter or body field at fault, as a path (`pages[0].title`).
        details:
          type: array
          description: >-
            Every problem found, when there was more than one
            (`invalid_request`), or each operation's result (`ops_failed`).
          items:
            type: object
        requestId:
          type: string
          description: >-
            Also sent as the `x-request-id` header. Quote it when contacting
            support.
      examples:
        - error: true
          code: invalid_request
          message: limit must be an integer from 1 to 100.
          param: limit
          requestId: FZn-uhymjoEEJow=
    GatewayError:
      type: object
      properties:
        message:
          type: string
      description: Returned by the API gateway itself (429).
  headers:
    RequestId:
      description: Identifies the request. Quote it when contacting support.
      schema:
        type: string
    IdempotentReplayed:
      description: >-
        `true` when the response is the stored answer to an earlier request with
        the same Idempotency-Key.
      schema:
        type: string
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: >-
        A secret key from Print.App admin → Domains → Secret keys, sent as
        `Authorization: Bearer sk_…`. Server-side only.

````

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