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

# Match One

> Match a single company to a Companies House number.



## OpenAPI

````yaml https://datamatcher-api.thedatacity.com/api/v1/openapi.json post /api/v1/match
openapi: 3.1.0
info:
  title: DataMatcher API
  version: 0.1.0
servers:
  - url: https://datamatcher-api.thedatacity.com
    description: Production
security: []
paths:
  /api/v1/match:
    post:
      tags:
        - match
      summary: Match One
      description: Match a single company to a Companies House number.
      operationId: match-match_one
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/MatchInput'
        required: true
      responses:
        '200':
          description: >-
            Match result. Fields rigorous_match, route, reasons, degraded, and
            error are only included when the API key belongs to a superuser.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/MatchResult'
              example:
                input_name: Sainsbury's Supermarkets Ltd
                id: demo-sainsburys
                matched_company_number: '3261722'
                matched_company_name: SAINSBURY'S SUPERMARKETS LTD
                active: Active
                rigorous_match: false
                route: fast
                reasons: []
                degraded: []
        '401':
          description: Missing or invalid API key
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
        '503':
          description: Matching engine not ready
      security:
        - APIKey: []
components:
  schemas:
    MatchInput:
      properties:
        input_name:
          type: string
          maxLength: 512
          minLength: 1
          title: Input Name
        input_url:
          anyOf:
            - type: string
              maxLength: 2048
            - type: 'null'
          title: Input Url
        postcode:
          anyOf:
            - type: string
              maxLength: 32
            - type: 'null'
          title: Postcode
        sic_code:
          anyOf:
            - type: string
              maxLength: 16
            - type: 'null'
          title: Sic Code
        start_trading_date:
          anyOf:
            - type: string
              maxLength: 32
            - type: 'null'
          title: Start Trading Date
        id:
          anyOf:
            - type: string
              maxLength: 128
            - type: 'null'
          title: Id
      type: object
      required:
        - input_name
      title: MatchInput
      examples:
        - id: demo-sainsburys
          input_name: Sainsbury's Supermarkets Ltd
        - id: demo-holmes-llp
          input_name: Holmes Joinery Partners LLP
        - id: demo-qmul
          input_name: Queen Mary University of London
    MatchResult:
      properties:
        id:
          anyOf:
            - type: string
            - type: 'null'
          title: Id
        input_name:
          type: string
          title: Input Name
        input_url:
          anyOf:
            - type: string
            - type: 'null'
          title: Input Url
        postcode:
          anyOf:
            - type: string
            - type: 'null'
          title: Postcode
        sic_code:
          anyOf:
            - type: string
            - type: 'null'
          title: Sic Code
        start_trading_date:
          anyOf:
            - type: string
            - type: 'null'
          title: Start Trading Date
        matched_company_number:
          anyOf:
            - type: string
            - type: 'null'
          title: Matched Company Number
        matched_company_name:
          anyOf:
            - type: string
            - type: 'null'
          title: Matched Company Name
        active:
          anyOf:
            - type: string
            - type: 'null'
          title: Active
        rigorous_match:
          type: boolean
          title: Rigorous Match
          default: false
        route:
          anyOf:
            - type: string
            - type: 'null'
          title: Route
        reasons:
          items:
            type: string
          type: array
          title: Reasons
          default: []
        degraded:
          items:
            type: string
          type: array
          title: Degraded
          default: []
        error:
          anyOf:
            - type: string
            - type: 'null'
          title: Error
      type: object
      required:
        - input_name
      title: MatchResult
      description: >-
        Full match result. Debug fields are returned only for superuser API
        keys.
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
        input:
          title: Input
        ctx:
          type: object
          title: Context
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError
  securitySchemes:
    APIKey:
      type: http
      description: Customer API key (`dm_live_…`)
      scheme: bearer

````