openapi: 3.1.1
info:
  title: Buyer
  version: 2.0.0
  description: Schema definition for Buyer in the Beckn Protocol
  license:
    name: CC-BY-NC-SA 4.0 International
  contact:
    name: Beckn Labs
    url: https://beckn.io
components:
  schemas:
    Buyer:
      x-iri: https://schema.nfh.global/Buyer/v2.0
      description: Schema definition for Buyer in the Beckn Protocol
      title: Buyer
      type: object
      properties:
        beckn:id:
          type: string
          description: Unique identifier for the buyer (personId or orgId in legacy
            schema)
          x-jsonld:
            '@id': schema:identifier
        beckn:role:
          type: string
          enum:
          - BUYER
          - SELLER
          - INTERMEDIARY
          - PAYER
          - PAYEE
          - FULFILLER
          description: The functional role of the buyer in the transaction.
          x-jsonld:
            '@id': schema:roleName
        beckn:displayName:
          type: string
          description: Human-readable display name
          x-jsonld:
            '@id': schema:name
        beckn:telephone:
          type: string
          description: Telephone number
          x-jsonld:
            '@id': schema:telephone
        beckn:email:
          type: string
          format: email
          description: Email Address
          x-jsonld:
            '@id': schema:email
        beckn:taxID:
          type: string
          description: Tax identifier for the buyer.
          x-jsonld:
            '@id': schema:taxID
        beckn:buyerAttributes:
          $ref: https://schema.nfh.global/Attributes/v2.0/attributes.yaml#/components/schemas/Attributes
          description: "Attribute Pack reference for richer identity: # buyer/identity.v1\
            \ (contact details: email, phone, address) # buyer/org-ids.v1 (LEI, GSTIN,\
            \ ISIN, CUSIP\u2026) # buyer/kyc.v1 (jurisdictional compliance fields)\
            \ # buyer/preferences.v1 (delivery preferences, accessibility needs, etc.)\n"
      required:
      - beckn:id
      additionalProperties: false
