{
  "description": "An Address following the convention of http://microformats.org/wiki/hcard",
  "type": "object",
  "properties": {
    "post-office-box": { "type": "string" },
    "extended-address": { "type": "string" },
    "street-address": { "type": "string" },
    "locality":{ "type": "string" },
    "region": { "type": "string" },
    "postal-code": { "type": "string" },
    "country-name": { "type": "string"}
  },
  "required": ["locality", "region", "country-name"],
  "allOf": [
    {
      "oneOf": [
        {"not": {"required": ["post-office-box"]}},
        {"required": ["post-office-box", "street-address"]}
      ]
    },
    {
      "oneOf": [
        {"not": {"required": ["extended-address"]}},
        {"required": ["extended-address", "street-address"]}
      ]
    }
  ]
}
