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

# Create customer



## OpenAPI

````yaml POST /customers
openapi: 3.0.0
info:
  title: Palomma API
  description: This API includes functionality of the Palomma API.
  version: 1.0.0
servers:
  - url: https://api.palomma.com/v0
    description: Production server
  - url: https://sandbox.api.palomma.com/v0
    description: Sandbox server
security:
  - BearerAuth: []
paths:
  /customers:
    post:
      tags:
        - customers
      summary: Creates a new customer
      operationId: createCustomer
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              required:
                - name
                - documentType
                - documentNumber
                - email
                - phoneNumber
              properties:
                reference:
                  type: string
                  description: Reference sent in by merchant to identify customer.
                name:
                  type: string
                  description: >-
                    First and last name for a natural person, and company name
                    for a juridical person.
                documentType:
                  type: string
                  description: Colombian ID type for customer.
                  enum:
                    - cc
                    - ce
                    - nit
                documentNumber:
                  type: string
                  description: Colombian ID number for customer.
                email:
                  type: string
                  description: Customer’s email.
                phoneNumber:
                  type: string
                  description: Customer’s phone number.
      responses:
        '200':
          description: Customer created successfully.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Customer'
        '400':
          description: Bad request.
          content:
            application/json:
              schema:
                type: object
                properties:
                  message:
                    type: string
        '401':
          description: Unauthorized.
          content:
            application/json:
              schema:
                type: object
                properties:
                  message:
                    type: string
        '500':
          description: Internal server error.
          content:
            application/json:
              schema:
                type: object
                properties:
                  message:
                    type: string
components:
  schemas:
    Customer:
      type: object
      properties:
        id:
          type: string
          description: Unique identifier for this customer.
          example: 01HPR57X6QR5ZRKEEKBSDBW4RA
        reference:
          type: string
          description: Reference sent in by merchant to identify customer.
        name:
          type: string
          description: >-
            First and last name for a natural person, and company name for a
            juridical person.
          example: Pepito Perez
        documentType:
          type: string
          description: Colombian ID type for customer.
          enum:
            - cc
            - ce
            - nit
        documentNumber:
          type: string
          description: Colombian ID number for customer.
          example: '1037551022'
        email:
          type: string
          description: Customer’s email.
          example: pepito@gmail.com
        phoneNumber:
          type: string
          description: Customer’s phone number.
          example: '3013111111'
        createdAt:
          type: string
          format: date-time
          description: ISO string indicating when the customer was created.
        updatedAt:
          type: string
          format: date-time
          description: ISO string indicating when the customer was updated.
  securitySchemes:
    BearerAuth:
      type: http
      scheme: bearer

````