UNPKG

shipengine-json-schema

Version:
94 lines 2.48 kB
{ "$id": "validate_address_request_body", "title": "validate_address_request_body", "type": "array", "items": { "allOf": [ { "title": "address_to_validate", "type": "object", "required": [ "address_line1", "city_locality", "state_province", "country_code" ], "additionalProperties": false, "allOf": [ { "title": "partial_address", "type": "object", "additionalProperties": false, "properties": { "name": { "type": "string", "minLength": 1 }, "phone": { "type": "string", "minLength": 1 }, "company_name": { "type": "string", "minLength": 1 }, "address_line1": { "type": "string", "minLength": 1 }, "address_line2": { "type": "string", "minLength": 1 }, "address_line3": { "type": "string", "minLength": 1 }, "city_locality": { "type": "string", "minLength": 1 }, "state_province": { "type": "string", "minLength": 1 }, "postal_code": { "allOf": [ { "title": "postal_code", "minLength": 1, "type": "string" } ] }, "country_code": { "allOf": [ { "title": "country_code", "type": "string", "minLength": 2, "maxLength": 2 } ] }, "address_residential_indicator": { "default": "unknown", "allOf": [ { "title": "address_residential_indicator", "type": "string", "enum": [ "unknown", "yes", "no" ] } ] } } } ] } ] } }