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

# Map CSV columns to schema fields

> Use AI to intelligently map CSV column names to supported KYC/KYB schema fields



## OpenAPI

````yaml api-reference/openapi.yaml post /mapCsvColumns
openapi: 3.0.0
info:
  title: Parcha API
  version: 1.0.0
  description: API for managing Parcha jobs and checks
servers:
  - url: https://api.parcha.ai/api/v1
    description: Agent Hub API server
  - url: https://demo.parcha.ai/api/v1
    description: Sandbox API server
  - url: https://us1.parcha.ai/api/v1
    description: Legacy API server
  - url: http://{your-company-domain}.parcha.ai/api/v1
    description: Custom Enterpris server (your company's API server)
security:
  - bearerAuth: []
paths:
  /mapCsvColumns:
    post:
      summary: Map CSV columns to schema fields
      description: >-
        Use AI to intelligently map CSV column names to supported KYC/KYB schema
        fields
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              required:
                - agent_type
                - csv_columns
              properties:
                agent_type:
                  type: string
                  enum:
                    - kyc
                    - kyb
                  description: The type of agent (kyc or kyb)
                csv_columns:
                  type: array
                  items:
                    type: string
                  description: List of column names from the CSV file
                sample_data:
                  type: array
                  items:
                    type: object
                  description: Sample rows from the CSV for context
      responses:
        '200':
          description: CSV columns mapped successfully
          content:
            application/json:
              schema:
                type: object
                properties:
                  mappings:
                    type: array
                    items:
                      type: object
                  unmapped_columns:
                    type: array
                    items:
                      type: string
        '400':
          description: Invalid input
        '500':
          description: Mapping failed
      security:
        - bearerAuth: []
components:
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: >-
        API key obtained from your Parcha account settings. Include as Bearer
        token in the Authorization header.

````