{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/lynx/json-schema/lynx-doc-member-incentive-redemption-request-schema.json",
  "title": "DocMemberIncentiveRedemptionRequest",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/lynx-payments-api-openapi.yml#/components/schemas/DocMemberIncentiveRedemptionRequest",
  "type": "object",
  "properties": {
    "data": {
      "$ref": "#/$defs/DocRedemptionMemberIncentive"
    },
    "idempotency": {
      "$ref": "#/$defs/Idempotency",
      "description": "Unique identifier that represents the operation"
    }
  },
  "required": [
    "data",
    "idempotency"
  ],
  "$defs": {
    "BaseMember": {
      "type": "object",
      "properties": {
        "clientMemberId": {
          "type": "string",
          "description": "Unique client-side identifier for the member"
        }
      },
      "required": [
        "clientMemberId"
      ]
    },
    "ClientOrgDto": {
      "type": "object",
      "properties": {
        "name": {
          "type": "string",
          "description": "The name of the client organization"
        }
      },
      "required": [
        "name"
      ]
    },
    "DocMemberIncentiveRedemptionTransaction": {
      "type": "object",
      "properties": {
        "clientTransactionIdentifier": {
          "type": "string",
          "description": "Transaction reference identifier"
        },
        "amount": {
          "type": "number",
          "description": "Dollar transaction amount. Either amount or incentiveValue is required."
        },
        "incentiveValue": {
          "type": "number",
          "description": "Virtual currency balance of the incentive account based on the incentive ratio. Either amount or incentiveValue is required."
        },
        "transactionDate": {
          "type": "string",
          "format": "date-time",
          "description": "Date of service that triggered this transaction"
        },
        "shortMemo": {
          "type": "string",
          "description": "10 character memo"
        },
        "longMemo": {
          "type": "string",
          "description": "Long descriptions Max 100 characters"
        },
        "type": {
          "type": "string",
          "description": "Type of redemption",
          "enum": [
            "Reimbursement",
            "MemberPurchase",
            "TransferPointsToDollars",
            "MemberTransfer",
            "Closed"
          ]
        },
        "tags": {
          "type": "array",
          "items": {
            "$ref": "#/$defs/TagDto"
          }
        }
      },
      "required": [
        "clientTransactionIdentifier",
        "shortMemo",
        "type"
      ]
    },
    "DocRedemptionMemberIncentive": {
      "type": "object",
      "properties": {
        "clientOrg": {
          "$ref": "#/$defs/ClientOrgDto"
        },
        "product": {
          "$ref": "#/$defs/ProductNameDto"
        },
        "member": {
          "$ref": "#/$defs/BaseMember"
        },
        "memberTransaction": {
          "$ref": "#/$defs/DocMemberIncentiveRedemptionTransaction"
        }
      }
    },
    "Idempotency": {
      "type": "object",
      "properties": {
        "idempotencyKey": {
          "type": "string",
          "description": "Unique identifier that represents the operation"
        }
      }
    },
    "ProductNameDto": {
      "type": "object",
      "properties": {
        "name": {
          "type": "string",
          "description": "The name of the product"
        }
      },
      "required": [
        "name"
      ]
    },
    "TagDto": {
      "type": "object",
      "properties": {
        "name": {
          "type": "string",
          "description": "Constant used to define the metadata within a key-value pair"
        },
        "value": {
          "type": "string",
          "description": "Variable belonging to the metadata within a key-value pair"
        },
        "type": {
          "type": "string",
          "description": "Additional client-defined qualifier that may be used to further classify the key-value pair"
        }
      },
      "required": [
        "name",
        "value"
      ]
    }
  }
}