{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://raw.githubusercontent.com/api-evangelist/certifyos/main/json-schema/certifyos-standardize-address-request-schema.json",
  "title": "StandardizeAddressRequest",
  "description": "Input address to be standardized and validated",
  "x-generated": "2026-10-20",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/certifyos-addressstandardization-api-openapi.yml#/components/schemas/StandardizeAddressRequest",
  "type": "object",
  "required": [
    "addressLine1"
  ],
  "properties": {
    "addressLine1": {
      "type": "string",
      "pattern": "\\S",
      "description": "Primary street line"
    },
    "addressLine2": {
      "type": "string",
      "description": "Secondary street line (apt, suite, unit, floor)"
    },
    "city": {
      "type": "string",
      "description": "City"
    },
    "county": {
      "type": "string",
      "description": "County"
    },
    "state": {
      "type": "string",
      "description": "State / province code"
    },
    "zip": {
      "type": "string",
      "pattern": "\\d{5}(?:-\\d{4})?",
      "description": "ZIP / postal code (5 or 5+4, hyphen-separated)"
    },
    "country": {
      "type": "string",
      "description": "ISO country code",
      "default": "US"
    },
    "addressType": {
      "type": "string",
      "description": "Optional address type hint (e.g. billing, mailing, office, remit_to, service, irs)"
    }
  }
}