{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/moov/json-schema/moov-underwriting-schema.json",
  "title": "Underwriting",
  "description": "Describes underwriting values (in USD) used for card payment acceptance.",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/moov-underwriting-api-openapi.yml#/components/schemas/Underwriting",
  "type": "object",
  "properties": {
    "averageTransactionSize": {
      "type": "integer",
      "format": "int64"
    },
    "maxTransactionSize": {
      "type": "integer",
      "format": "int64"
    },
    "averageMonthlyTransactionVolume": {
      "type": "integer",
      "format": "int64"
    },
    "status": {
      "$ref": "#/$defs/UnderwritingStatus"
    },
    "volumeByCustomerType": {
      "$ref": "#/$defs/VolumeByCustomerType"
    },
    "cardVolumeDistribution": {
      "$ref": "#/$defs/CardVolumeDistribution"
    },
    "fulfillment": {
      "$ref": "#/$defs/FulfillmentDetails"
    },
    "geographicReach": {
      "$ref": "#/$defs/GeographicReach"
    },
    "businessPresence": {
      "$ref": "#/$defs/BusinessPresence"
    },
    "pendingLitigation": {
      "$ref": "#/$defs/PendingLitigation"
    },
    "volumeShareByCustomerType": {
      "$ref": "#/$defs/VolumeShareByCustomerType"
    },
    "collectFunds": {
      "$ref": "#/$defs/CollectFunds"
    },
    "moneyTransfer": {
      "$ref": "#/$defs/MoneyTransfer"
    },
    "sendFunds": {
      "$ref": "#/$defs/SendFunds"
    }
  },
  "$defs": {
    "BusinessPresence": {
      "type": "string",
      "enum": [
        "commercial-office",
        "home-based",
        "mixed-presence",
        "mobile-business",
        "online-only",
        "retail-storefront"
      ]
    },
    "CardAcceptanceMethods": {
      "type": "object",
      "properties": {
        "inPersonPercentage": {
          "type": "integer",
          "format": "int32",
          "description": "Percentage of card transactions that are in-person payments. Minimum value is 0, maximum is 100."
        },
        "mailOrPhonePercentage": {
          "type": "integer",
          "format": "int32",
          "description": "Percentage of card transactions that are mail or phone payments. Minimum value is 0, maximum is 100."
        },
        "onlinePercentage": {
          "type": "integer",
          "format": "int32",
          "description": "Percentage of card transactions that are online payments. Minimum value is 0, maximum is 100."
        }
      },
      "description": "Describes the distribution of card transactions by payment method."
    },
    "CardVolumeDistribution": {
      "type": "object",
      "required": [
        "ecommercePercentage",
        "cardPresentPercentage",
        "mailOrPhonePercentage",
        "debtRepaymentPercentage"
      ],
      "properties": {
        "ecommercePercentage": {
          "type": "integer",
          "format": "int32"
        },
        "cardPresentPercentage": {
          "type": "integer",
          "format": "int32"
        },
        "mailOrPhonePercentage": {
          "type": "integer",
          "format": "int32"
        },
        "debtRepaymentPercentage": {
          "type": "integer",
          "format": "int32"
        }
      }
    },
    "CollectFunds": {
      "type": "object",
      "properties": {
        "ach": {
          "$ref": "#/$defs/CollectFundsAch"
        },
        "cardPayments": {
          "$ref": "#/$defs/CollectFundsCardPayments"
        }
      }
    },
    "CollectFundsAch": {
      "type": "object",
      "properties": {
        "estimatedActivity": {
          "$ref": "#/$defs/EstimatedActivity"
        }
      }
    },
    "CollectFundsCardPayments": {
      "type": "object",
      "properties": {
        "cardAcceptanceMethods": {
          "$ref": "#/$defs/CardAcceptanceMethods"
        },
        "currentlyAcceptsCards": {
          "type": "boolean"
        },
        "estimatedActivity": {
          "$ref": "#/$defs/EstimatedActivity"
        },
        "fulfillment": {
          "$ref": "#/$defs/Fulfillment"
        },
        "refundPolicy": {
          "$ref": "#/$defs/RefundPolicy"
        }
      }
    },
    "EstimatedActivity": {
      "type": "object",
      "properties": {
        "averageTransactionAmount": {
          "type": "integer",
          "format": "int64"
        },
        "maximumTransactionAmount": {
          "type": "integer",
          "format": "int64"
        },
        "monthlyVolumeRange": {
          "$ref": "#/$defs/MonthlyVolumeRange"
        }
      }
    },
    "Fulfillment": {
      "type": "object",
      "properties": {
        "method": {
          "$ref": "#/$defs/FulfillmentMethod"
        },
        "timeframe": {
          "$ref": "#/$defs/FulfillmentTimeframe"
        }
      }
    },
    "FulfillmentDetails": {
      "type": "object",
      "required": [
        "hasPhysicalGoods",
        "isShippingProduct",
        "shipmentDurationDays",
        "returnPolicy"
      ],
      "properties": {
        "hasPhysicalGoods": {
          "type": "boolean"
        },
        "isShippingProduct": {
          "type": "boolean"
        },
        "shipmentDurationDays": {
          "type": "integer",
          "format": "int64"
        },
        "returnPolicy": {
          "$ref": "#/$defs/ReturnPolicyType"
        }
      }
    },
    "FulfillmentMethod": {
      "type": "string",
      "enum": [
        "bill-or-debt-payment",
        "digital-content",
        "donation",
        "in-person-service",
        "local-pickup-or-delivery",
        "other",
        "remote-service",
        "shipped-physical-goods",
        "subscription-or-membership"
      ]
    },
    "FulfillmentTimeframe": {
      "type": "string",
      "enum": [
        "immediate",
        "other",
        "over-30-days",
        "pre-order",
        "recurring-schedule",
        "scheduled-event",
        "within-30-days",
        "within-7-days"
      ]
    },
    "GeographicReach": {
      "type": "string",
      "enum": [
        "international-only",
        "us-and-international",
        "us-only"
      ]
    },
    "MoneyTransfer": {
      "type": "object",
      "properties": {
        "pullFromCard": {
          "$ref": "#/$defs/MoneyTransferPullFromCard"
        },
        "pushToCard": {
          "$ref": "#/$defs/MoneyTransferPushToCard"
        }
      }
    },
    "MoneyTransferPullFromCard": {
      "type": "object",
      "properties": {
        "estimatedActivity": {
          "$ref": "#/$defs/EstimatedActivity"
        }
      }
    },
    "MoneyTransferPushToCard": {
      "type": "object",
      "properties": {
        "estimatedActivity": {
          "$ref": "#/$defs/EstimatedActivity"
        }
      }
    },
    "MonthlyVolumeRange": {
      "type": "string",
      "enum": [
        "under-10k",
        "10k-50k",
        "50k-100k",
        "100k-250k",
        "250k-500k",
        "500k-1m",
        "1m-5m",
        "over-5m"
      ],
      "description": "The low value in each range is included. The high value in each range is excluded."
    },
    "PendingLitigation": {
      "type": "string",
      "enum": [
        "bankruptcy-or-insolvency",
        "consumer-protection-or-class-action",
        "data-breach-or-privacy",
        "employment-or-workplace-disputes",
        "fraud-or-financial-crime",
        "government-enforcement-or-investigation",
        "intellectual-property",
        "none",
        "other",
        "personal-injury-or-medical"
      ]
    },
    "RefundPolicy": {
      "type": "string",
      "enum": [
        "conditional-refund",
        "custom-policy",
        "event-based-policy",
        "full-refund-extended-window",
        "full-refund-within-30-days",
        "no-refunds",
        "partial-refund",
        "prorated-refund",
        "store-credit-only"
      ]
    },
    "ReturnPolicyType": {
      "type": "string",
      "enum": [
        "none",
        "exchangeOnly",
        "withinThirtyDays",
        "other"
      ]
    },
    "SendFunds": {
      "type": "object",
      "properties": {
        "ach": {
          "$ref": "#/$defs/SendFundsAch"
        },
        "pushToCard": {
          "$ref": "#/$defs/SendFundsPushToCard"
        },
        "rtp": {
          "$ref": "#/$defs/SendFundsRtp"
        },
        "instantBank": {
          "$ref": "#/$defs/SendFundsInstantBank"
        }
      }
    },
    "SendFundsAch": {
      "type": "object",
      "properties": {
        "estimatedActivity": {
          "$ref": "#/$defs/EstimatedActivity"
        }
      }
    },
    "SendFundsInstantBank": {
      "type": "object",
      "properties": {
        "estimatedActivity": {
          "$ref": "#/$defs/EstimatedActivity"
        }
      }
    },
    "SendFundsPushToCard": {
      "type": "object",
      "properties": {
        "estimatedActivity": {
          "$ref": "#/$defs/EstimatedActivity"
        }
      }
    },
    "SendFundsRtp": {
      "type": "object",
      "properties": {
        "estimatedActivity": {
          "$ref": "#/$defs/EstimatedActivity"
        }
      }
    },
    "UnderwritingStatus": {
      "type": "string",
      "enum": [
        "approved",
        "rejected",
        "pendingReview",
        "pending",
        "notRequested"
      ],
      "deprecated": true
    },
    "VolumeByCustomerType": {
      "type": "object",
      "required": [
        "businessToBusinessPercentage",
        "consumerToBusinessPercentage"
      ],
      "properties": {
        "businessToBusinessPercentage": {
          "type": "integer",
          "format": "int32"
        },
        "consumerToBusinessPercentage": {
          "type": "integer",
          "format": "int32"
        }
      }
    },
    "VolumeShareByCustomerType": {
      "type": "object",
      "properties": {
        "business": {
          "type": "integer",
          "format": "int32"
        },
        "consumer": {
          "type": "integer",
          "format": "int32"
        },
        "p2p": {
          "type": "integer",
          "format": "int32"
        }
      }
    }
  }
}