{"openapi":"3.1.0","info":{"title":"Overhang Property API","description":"Look up a property by address. Get our measurements of it, and a map of the property to show on your own website. Guide: https://api.dev.overhang.tech/api/v1/docs","version":"1"},"servers":[{"url":"https://api.dev.overhang.tech"}],"paths":{"/api/v1/property":{"get":{"summary":"Get a property's measurements and map","description":"One property: the measurements in `fields` and a map of `layers`.\n\nGive exactly one of `address` (any US street address; we return the\nproperty and grade the match in `match`) or `property_id` (from an earlier\nresponse; no address lookup). `fields` (comma-separated, e.g. `lawn`)\nselects metrics; `layers` (e.g. `lawn,property`) selects the overlays of\nthe embed map. Ask for at least one. `units` is `sqft` (default) or `m2`.","operationId":"get_property_api_v1_property_get","parameters":[{"name":"address","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"A US street address.","examples":["123 Example Street, Anytown, NY 10001"],"title":"Address"},"description":"A US street address."},{"name":"property_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"`property_id` from an earlier response.","title":"Property Id"},"description":"`property_id` from an earlier response."},{"name":"fields","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Comma-separated measurements to return. Available: `lawn`, `canopy`, `buildings`, `overhang`.","examples":["lawn"],"title":"Fields"},"description":"Comma-separated measurements to return. Available: `lawn`, `canopy`, `buildings`, `overhang`."},{"name":"layers","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Comma-separated overlays for the embedded map. Available: `lawn`, `canopy`, `buildings`, `overhang`, `property` (the property boundary).","examples":["lawn,property"],"title":"Layers"},"description":"Comma-separated overlays for the embedded map. Available: `lawn`, `canopy`, `buildings`, `overhang`, `property` (the property boundary)."},{"name":"units","in":"query","required":false,"schema":{"type":"string","description":"Units for areas: `sqft` (default) or `m2`.","default":"sqft","title":"Units"},"description":"Units for areas: `sqft` (default) or `m2`."}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PropertyResponse"}}}},"400":{"description":"Bad parameters (unknown field, layer, or unit)"},"401":{"description":"Missing, invalid, or revoked API key"},"403":{"description":"The property or address is not in your company's ZIP codes (`detail.code` is `not_in_service_area`), or the company is archived (`account_archived`)"},"404":{"description":"No property at this address in your ZIP codes"},"422":{"description":"No measurement for anything you asked for in `fields` and `layers` (`detail.code` is `not_measured`)"},"429":{"description":"More than 60 requests a minute; see Retry-After"},"503":{"description":"A service we depend on is not available; try again"}}}},"/api/v1/coverage":{"get":{"summary":"List your ZIP codes, and the fields and layers in each","description":"The ZIP codes your company has, and for each, the `fields` and `layers`\nwe have properties measured for. Only your company's own grants.","operationId":"get_coverage_api_v1_coverage_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CoverageResponse"}}}},"401":{"description":"Missing, invalid, or revoked API key"},"403":{"description":"The company is archived (`account_archived`)"},"429":{"description":"More than 60 requests a minute; see Retry-After"}}}}},"components":{"schemas":{"BuildingsMetric":{"properties":{"area":{"anyOf":[{"type":"integer"},{"type":"number"}],"title":"Area","description":"The area the buildings on the property cover (their footprints), in `unit`. Whole square feet, or square metres to one decimal place."},"unit":{"type":"string","enum":["sqft","m2"],"title":"Unit","description":"The unit of `area`: `sqft` (square feet) or `m2` (square metres). It is what you sent in `units`, or `sqft` if you did not send `units`."},"count":{"type":"integer","title":"Count","description":"How many buildings are on the property."}},"type":"object","required":["area","unit","count"],"title":"BuildingsMetric","description":"The buildings measurement. Without one, `buildings` is\nlisted in `not_measured`."},"CanopyMetric":{"properties":{"area":{"anyOf":[{"type":"integer"},{"type":"number"}],"title":"Area","description":"The tree canopy area of the property, in `unit`: the ground that trees and tall shrubs cover, seen from above. It includes canopy that hangs over buildings. Whole square feet, or square metres to one decimal place."},"unit":{"type":"string","enum":["sqft","m2"],"title":"Unit","description":"The unit of `area`: `sqft` (square feet) or `m2` (square metres). It is what you sent in `units`, or `sqft` if you did not send `units`."},"percent_of_property":{"type":"number","title":"Percent Of Property","description":"How much of the property is under tree canopy, as a percent from 0 to 100, to one decimal place."}},"type":"object","required":["area","unit","percent_of_property"],"title":"CanopyMetric","description":"The tree canopy measurement. Without one, `canopy` is\nlisted in `not_measured`."},"CoverageResponse":{"properties":{"zip_codes":{"additionalProperties":{"$ref":"#/components/schemas/ZipCoverage"},"type":"object","title":"Zip Codes","description":"Your company's ZIP codes, in order, each mapped to what we have there, for example `{\"10538\": {...}}`. Keys are strings. Ask for other ZIP codes through Overhang support."}},"type":"object","required":["zip_codes"],"title":"CoverageResponse"},"Embed":{"properties":{"url":{"type":"string","title":"Url","description":"The map page. Put it in the `src` of an `<iframe>` on your page. It needs no API key, so it is safe to use in a browser."},"expires_at":{"type":"string","format":"date-time","title":"Expires At","description":"When `url` stops working, in UTC: one hour after your request. Call the API again for a new link."}},"type":"object","required":["url","expires_at"],"title":"Embed","description":"A link to a map of the property that shows the layers you asked for.\nOnly when you send `layers`."},"LawnMetric":{"properties":{"area":{"anyOf":[{"type":"integer"},{"type":"number"}],"title":"Area","description":"The lawn area of the property, in `unit`: the property minus buildings, driveways, sidewalks and other paving, minus ground deep under tree canopy. Grass under small trees and under the outer 1 m of larger canopy still counts. Whole square feet, or square metres to one decimal place."},"unit":{"type":"string","enum":["sqft","m2"],"title":"Unit","description":"The unit of `area`: `sqft` (square feet) or `m2` (square metres). It is what you sent in `units`, or `sqft` if you did not send `units`."},"percent_of_property":{"type":"number","title":"Percent Of Property","description":"How much of the property is lawn, as a percent from 0 to 100, to one decimal place. For example, `38.5` means the lawn covers 38.5 % of the property's area."}},"type":"object","required":["area","unit","percent_of_property"],"title":"LawnMetric","description":"The lawn measurement. Without one, `lawn` is\nlisted in `not_measured`."},"Match":{"properties":{"quality":{"type":"string","enum":["exact","approximate"],"title":"Quality","description":"`exact` or `approximate`. With `exact`, every check passed. With `approximate`, ask your user to confirm the property."},"reasons":{"items":{"type":"string"},"type":"array","title":"Reasons","description":"The checks that failed, for example `[\"number_mismatch\"]`. Empty when `quality` is `exact`. Values: `partial_match`, `interpolated`, `no_house_number`, `number_mismatch`, `postal_mismatch`, `nearest_lot`, `unit`."}},"type":"object","required":["quality","reasons"],"title":"Match","description":"How well the address you sent matches the property we found. Only when\nyou send `address`, not `property_id`."},"Metrics":{"properties":{"lawn":{"anyOf":[{"$ref":"#/components/schemas/LawnMetric"},{"type":"null"}]},"canopy":{"anyOf":[{"$ref":"#/components/schemas/CanopyMetric"},{"type":"null"}]},"buildings":{"anyOf":[{"$ref":"#/components/schemas/BuildingsMetric"},{"type":"null"}]},"overhang":{"anyOf":[{"$ref":"#/components/schemas/OverhangMetric"},{"type":"null"}]}},"type":"object","title":"Metrics","description":"The measurements you asked for in `fields`, one object for each name.\nOnly when you send `fields`."},"OverhangMetric":{"properties":{"area":{"anyOf":[{"type":"integer"},{"type":"number"}],"title":"Area","description":"The roof area that tree canopy hangs over, in `unit`. `0` when no canopy is over a roof. Whole square feet, or square metres to one decimal place."},"unit":{"type":"string","enum":["sqft","m2"],"title":"Unit","description":"The unit of `area`: `sqft` (square feet) or `m2` (square metres). It is what you sent in `units`, or `sqft` if you did not send `units`."}},"type":"object","required":["area","unit"],"title":"OverhangMetric","description":"The roof overhang measurement. Without one, `overhang` is\nlisted in `not_measured`."},"PropertyResponse":{"properties":{"property_id":{"type":"string","title":"Property Id","description":"Our ID for the property, a UUID. It never changes for the same property. Store it and send it as `property_id` next time: you get the same property back, without an address lookup."},"matched_address":{"type":"string","title":"Matched Address","description":"The property's address in our records, for example `123 EXAMPLE ST, Anytown, NY 10001`. It can be written differently from the address you sent. Show it to your user so they can check we found the right property."},"match":{"anyOf":[{"$ref":"#/components/schemas/Match"},{"type":"null"}],"description":"How well the address you sent matches the property we found. Only when you send `address`."},"metrics":{"anyOf":[{"$ref":"#/components/schemas/Metrics"},{"type":"null"}],"description":"The measurements you asked for in `fields`, one object for each name we have a measurement for. Only when we have at least one."},"not_measured":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Not Measured","description":"The names in `fields` and `layers` that we have no measurement for, for example `[\"lawn\"]`. They are not in `metrics` and not on the map. Only when there is at least one. When nothing you asked for is measured, the request fails with 422 instead."},"embed":{"anyOf":[{"$ref":"#/components/schemas/Embed"},{"type":"null"}],"description":"A link to a map of the property. Only when we have at least one of the `layers` you asked for."}},"type":"object","required":["property_id","matched_address"],"title":"PropertyResponse"},"ZipCoverage":{"properties":{"properties":{"type":"integer","title":"Properties","description":"How many properties in the ZIP code your company can look up that we have measurements for."},"fields":{"items":{"type":"string"},"type":"array","title":"Fields","description":"The names you can send in `fields` for properties in this ZIP code. One property can still have no measurement for a name: then the response lists it in `not_measured`."},"layers":{"items":{"type":"string"},"type":"array","title":"Layers","description":"The names you can send in `layers` for properties in this ZIP code. `property` is always here."}},"type":"object","required":["properties","fields","layers"],"title":"ZipCoverage"}},"securitySchemes":{"apiKey":{"type":"http","scheme":"bearer","description":"Your company API key: `Authorization: Bearer osk_…`"}}},"security":[{"apiKey":[]}]}