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

# Create a list

> Creates a new list. Creates a candidate, client, or client contact list based on the path type.



## OpenAPI

````yaml /openapi-private.json post /lists/{entityType}
openapi: 3.1.0
info:
  title: Spott API Reference
  version: '0.1'
servers:
  - url: https://api.gospott.com
security: []
tags: []
paths:
  /lists/{entityType}:
    post:
      tags:
        - Lists
      summary: Create a list
      description: >-
        Creates a new list. Creates a candidate, client, or client contact list
        based on the path type.
      operationId: createList
      parameters:
        - name: entityType
          required: true
          in: path
          schema:
            enum:
              - candidate
              - client
              - client-contact
            type: string
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CreateListDto'
      responses:
        '201':
          description: List created successfully. Returns the list ID.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/CreateRecordResponseDto'
        '400':
          description: Bad request - missing or invalid required fields
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ExceptionBaseDto'
        '401':
          description: Unauthorized - invalid or missing authentication
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ExceptionBaseDto'
        '500':
          description: Error response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ExceptionBaseDto'
      security:
        - x-api-key: []
components:
  schemas:
    CreateListDto:
      type: object
      properties:
        name:
          type: string
          minLength: 1
        colorHex:
          type: string
          pattern: ^#([0-9a-fA-F]{3}|[0-9a-fA-F]{4}|[0-9a-fA-F]{6}|[0-9a-fA-F]{8})$
        type:
          type: string
          enum:
            - PERSONAL
            - WORKSPACE
      required:
        - name
        - colorHex
        - type
      id: PrivateCreateListDto
    CreateRecordResponseDto:
      type: object
      properties:
        id:
          type: string
          minLength: 1
      required:
        - id
      id: CreateRecordResponseDto
    ExceptionBaseDto:
      type: object
      properties:
        status:
          type: integer
          minimum: -9007199254740991
          maximum: 9007199254740991
        message:
          type: string
        requestId:
          type: string
      required:
        - status
        - message
        - requestId
      id: ExceptionBaseDto
  securitySchemes:
    x-api-key:
      type: apiKey
      name: x-api-key
      in: header
      description: >-
        API key for authentication. Get your API key from Settings → API Keys in
        your Spott dashboard.

````