{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/rutter/json-schema/rutter-get-supplier-enablement-merchant-enrichment-response-schema.json",
  "title": "GetSupplierEnablementMerchantEnrichmentResponse",
  "x-generated": "2026-11-05",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/rutter-supplier-enablement-api-openapi.yml#/components/schemas/GetSupplierEnablementMerchantEnrichmentResponse",
  "anyOf": [
    {
      "$ref": "#/$defs/AsyncResponsePayload"
    },
    {
      "type": "object",
      "properties": {
        "enrichment": {
          "type": "object",
          "properties": {
            "vendor_address": {
              "type": "string",
              "description": "Address of the vendor."
            },
            "vendor_name": {
              "type": "string",
              "description": "Name of the vendor."
            },
            "accepts_card": {
              "type": [
                "boolean",
                "null"
              ],
              "description": "Whether the vendor accepts credit card payments."
            },
            "billing_portal_link": {
              "type": [
                "string",
                "null"
              ],
              "description": "Billing portal link for this vendor, extracted from OCR or other sources."
            },
            "card_activation_flow": {
              "type": [
                "string",
                "null"
              ],
              "enum": [
                "merchant_auth_link",
                "generic_job",
                "payment_link",
                "null"
              ],
              "description": "The recommended card activation flow for this vendor. 'merchant_auth_link' requires user to login via browser session, 'generic_job' queues job for manual action, 'payment_link' uses direct payment link."
            },
            "card_fee": {
              "type": [
                "number",
                "null"
              ],
              "description": "Amount of card payment fees."
            },
            "has_card_fees": {
              "type": [
                "boolean",
                "null"
              ],
              "description": "Whether the vendor has card payment fees."
            },
            "manual_activation_instructions": {
              "type": [
                "string",
                "null"
              ],
              "description": "User-facing instructions on how to pay this vendor by card. To be used in the case when automated card switching is unable to complete successfully. Generated when the vendor accepts cards via billing portal or invoice link."
            },
            "merchant_code": {
              "type": [
                "string",
                "null"
              ],
              "description": "The supported vendor identifier if this vendor matches a known supported vendor (e.g., AWS, VGS)."
            },
            "accepts_card_sources": {
              "type": [
                "array",
                "null"
              ],
              "items": {
                "type": "string"
              },
              "description": "Sources of information for this card acceptance method."
            },
            "card_accept_options_sources": {
              "type": [
                "array",
                "null"
              ],
              "items": {
                "type": "string"
              },
              "description": "Sources of information for this card acceptance options."
            },
            "card_fee_sources": {
              "type": [
                "array",
                "null"
              ],
              "items": {
                "type": "string"
              },
              "description": "Sources of information for this card payment fees."
            },
            "card_accept_options": {
              "type": [
                "array",
                "null"
              ],
              "items": {
                "type": "object",
                "properties": {
                  "description": {
                    "type": "string",
                    "description": "Description of how to use this card acceptance method."
                  },
                  "type": {
                    "type": "string",
                    "enum": [
                      "billing_portal",
                      "invoice_link",
                      "online_checkout",
                      "agent",
                      "phone",
                      "email",
                      "unknown"
                    ],
                    "description": "The type of card acceptance method available."
                  },
                  "sources": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    },
                    "description": "Sources of information for this card acceptance method."
                  }
                },
                "required": [
                  "description",
                  "type",
                  "sources"
                ],
                "additionalProperties": false
              },
              "description": "Available options for setting up card payments with this vendor."
            }
          },
          "required": [
            "vendor_address",
            "vendor_name",
            "accepts_card",
            "billing_portal_link",
            "card_activation_flow",
            "card_fee",
            "has_card_fees",
            "manual_activation_instructions",
            "merchant_code",
            "accepts_card_sources",
            "card_accept_options_sources",
            "card_fee_sources",
            "card_accept_options"
          ],
          "additionalProperties": false
        }
      },
      "required": [
        "enrichment"
      ],
      "additionalProperties": false
    }
  ],
  "$defs": {
    "AsyncResponsePayload": {
      "type": "object",
      "properties": {
        "async_response": {
          "type": "object",
          "properties": {
            "id": {
              "type": "string"
            },
            "response_url": {
              "type": "string"
            },
            "status": {
              "type": "string",
              "enum": [
                "prequeued",
                "pending",
                "success",
                "failure"
              ]
            },
            "platform_rate_limit_details": {
              "type": "object",
              "properties": {
                "lookback_window_seconds": {
                  "type": "number"
                },
                "platform_rate_limited_basis": {
                  "type": "string",
                  "enum": [
                    "platform",
                    "connection",
                    "hybrid"
                  ]
                },
                "recent_connection_rate_limited_job_count": {
                  "type": "number"
                },
                "recent_platform_rate_limited_job_count": {
                  "type": "number"
                },
                "recent_rate_limited_job_count": {
                  "type": "number"
                }
              },
              "required": [
                "lookback_window_seconds",
                "platform_rate_limited_basis",
                "recent_connection_rate_limited_job_count",
                "recent_platform_rate_limited_job_count",
                "recent_rate_limited_job_count"
              ],
              "additionalProperties": false
            }
          },
          "required": [
            "id",
            "response_url",
            "status"
          ],
          "additionalProperties": false
        }
      }
    }
  }
}