> ## Documentation Index
> Fetch the complete documentation index at: https://yuno-3979e326-docs-agent-readable-descriptions.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Create Customer

> Create a customer in the sandbox using the sandbox-tested endpoint.



## OpenAPI

````yaml /openapi/yuno_sandbox_tested.json POST /v1/customers
openapi: 3.1.0
info:
  title: Yuno Payments API
  version: 1.0.0
  description: >
    The Yuno Payments API is built around REST principles, using standard HTTP
    methods and JSON payloads.


    ## Authentication

    All requests require two headers:

    ```

    public-api-key: YOUR_PUBLIC_KEY

    private-secret-key: YOUR_PRIVATE_KEY

    ```


    ## Idempotency

    Payment mutations (create, capture, cancel, refund, payout) require an
    `X-Idempotency-Key` header (UUID).

    The API stores the key and returns the same response for duplicate requests
    within 24 hours.


    ## Environments

    | Environment | Base URL |

    |-------------|----------|

    | Sandbox | `https://api-sandbox.y.uno/v1` |

    | Production | `https://api.y.uno/v1` |
  contact:
    name: Yuno Support
    url: https://docs.y.uno
  license:
    name: Proprietary
servers:
  - url: https://api-sandbox.y.uno
    description: Sandbox
  - url: https://api.y.uno
    description: Production
security:
  - PublicApiKey: []
    PrivateSecretKey: []
tags:
  - name: Customers
    description: Create and manage customer records.
  - name: Checkout Sessions
    description: Initialize the Yuno SDK on the front-end.
  - name: Payment Methods
    description: Enroll and manage vaulted payment methods.
  - name: Payments
    description: Create and manage payment transactions.
  - name: Payment Links
    description: Hosted payment pages requiring no SDK.
  - name: Subscriptions
    description: Recurring billing management.
  - name: Payouts
    description: Disburse funds to individuals or entities.
  - name: Reports
    description: Generate and download transaction reports.
  - name: Currency Conversion
    description: Dynamic currency conversion (DCC).
paths:
  /v1/customers:
    post:
      tags:
        - Customers
      summary: Create Customer
      operationId: create-customer
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CreateCustomerRequest'
            example:
              merchant_customer_id: customer-001
              first_name: John
              last_name: Doe
              email: john.doe@example.com
              gender: M
              date_of_birth: '1990-01-15'
              nationality: US
              country: US
              document:
                document_type: DNI
                document_number: '123456789'
              phone:
                country_code: '+1'
                number: '5550000001'
              billing_address:
                address_line_1: 123 Main St
                city: New York
                state: NY
                zip_code: '10001'
                country: US
              metadata:
                - key: source
                  value: web
      responses:
        '201':
          description: Customer created
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Customer'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
components:
  schemas:
    CreateCustomerRequest:
      type: object
      required:
        - merchant_customer_id
      properties:
        merchant_customer_id:
          type: string
          minLength: 3
          maxLength: 255
        first_name:
          type: string
          minLength: 3
          maxLength: 255
        last_name:
          type: string
          minLength: 3
          maxLength: 255
        gender:
          type: string
          enum:
            - M
            - F
            - NB
            - NA
            - NK
            - U
        date_of_birth:
          type: string
          pattern: ^\d{4}-\d{2}-\d{2}$
          example: '1990-01-15'
        email:
          type: string
          format: email
        nationality:
          $ref: '#/components/schemas/Country'
        country:
          $ref: '#/components/schemas/Country'
        document:
          $ref: '#/components/schemas/Document'
        phone:
          $ref: '#/components/schemas/Phone'
        billing_address:
          $ref: '#/components/schemas/Address'
        shipping_address:
          $ref: '#/components/schemas/Address'
        metadata:
          $ref: '#/components/schemas/Metadata'
    Customer:
      type: object
      properties:
        id:
          type: string
          format: uuid
        merchant_customer_id:
          type: string
        first_name:
          type: string
        last_name:
          type: string
        email:
          type: string
        country:
          type: string
        document:
          $ref: '#/components/schemas/Document'
        phone:
          $ref: '#/components/schemas/Phone'
        billing_address:
          $ref: '#/components/schemas/Address'
        metadata:
          $ref: '#/components/schemas/Metadata'
        created_at:
          type: string
          format: date-time
        updated_at:
          type: string
          format: date-time
    Country:
      type: string
      enum:
        - AR
        - BO
        - BR
        - CL
        - CO
        - CR
        - EC
        - SV
        - GT
        - HN
        - MX
        - NI
        - PA
        - PY
        - PE
        - US
        - UY
      description: ISO 3166-1 alpha-2 country code
    Document:
      type: object
      properties:
        document_type:
          type: string
          enum:
            - DNI
            - CI
            - LC
            - LE
            - CUIT
            - CUIL
            - PAS
            - CPF
            - RG
            - CNH
            - CNPJ
            - RUT
            - RUN
            - CC
            - CE
            - NIT
            - DUI
            - PIC
            - DPI
            - IFR
            - INE
            - CP
            - RFC
            - CURP
            - CIP
            - CIC
            - CUI
            - RUC
        document_number:
          type: string
          minLength: 3
          maxLength: 40
    Phone:
      type: object
      properties:
        country_code:
          type: string
          example: '+1'
        number:
          type: string
          example: '5550000001'
    Address:
      type: object
      properties:
        address_line_1:
          type: string
        address_line_2:
          type: string
        city:
          type: string
        state:
          type: string
        zip_code:
          type: string
        country:
          $ref: '#/components/schemas/Country'
        neighborhood:
          type: string
    Metadata:
      type: array
      maxItems: 120
      items:
        type: object
        properties:
          key:
            type: string
            maxLength: 48
          value:
            type: string
            maxLength: 512
    Error:
      type: object
      properties:
        code:
          type: string
        message:
          type: string
        details:
          type: object
  responses:
    BadRequest:
      description: Invalid request — schema violation or missing required field
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    Unauthorized:
      description: Invalid or missing API credentials
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'

````