Base URL: https://api.roofquery.com. Authenticate with Authorization: Bearer <your key> — except the four file routes, which take no key.
Copies this whole page as Markdown, so you can paste it into an assistant and have it write the integration. Nothing secret goes on the clipboard — your keys aren't included.
Measurements arrive on the order itself, so the webhook body,
GET /orders/:id and
GET /orders/:id/status all
carry the same numbers — you never need a second call to get them. totals
covers the whole property; each entry in structures[] is one building
(house, detached garage, shed) with the identical shape.
| Field | What it is |
|---|---|
structureCount | Separate buildings measured. totals is the sum across all of them. Inferred from geometry, not read off the document. |
structures[].index | 1 is the largest building. Ordered by roof area, descending — so structures[0] is the house and outbuildings follow. Stable: the same document always indexes the same way, so an index is safe to store or put in a URL. |
totalAreaSqFt / totalSquares | Sloped roof area. Squares is area ÷ 100. |
facetCount | Number of roof planes. |
predominantPitch | The pitch covering the most area. Flat or N/12. |
pitchAreas | Roof area at each pitch — what you need to price steep-slope labour. |
edgeTotals | Length and count per category: EAVE, RAKE, RIDGE, HIP, VALLEY, STEP_FLASHING, WALL_FLASHING, PARAPET, BEND, OTHER. Always all ten, zero-filled. BEND is a pitch transition — where two different slopes meet; PARAPET is the run of parapet wall along the roof edge. These are the same names the PDF's measurement tables print, so a number you read on the report can be found in the JSON without a lookup. |
totalEdgeLengthFt | Every edge added up. |
hipsAndRidgesLengthFt | Hips and ridges together — ridge cap is ordered against the pair. |
complexity | simple / normal / complex, from facet count and total hip+valley run. |
estimatedAtticSqFt | Sloped area projected back to horizontal. For ventilation and insulation sizing, not a measured floor area. |
diagrams | The four drawings for this target, already addressed. Sits beside the areas on purpose: the moment you have a square footage to show, you have the picture to show with it. |
faces[] | Every roof plane, with its own area, pitch and edge list. |
Edges shared between adjacent faces are counted once per structure, so adding up
faces[].edges[] yourself will overcount — use edgeTotals.
The category names are ours, not the document's. Raw
<LINE> types vary by exporter — the same eave arrives as
FASCIA in one dialect and type="EDGE" subtype="EAVE" in
another, and a pitch transition as BATTEN — so these nine categories are
the normalized form, and they're what the PDF prints too. Parse
edgeTotals rather than joining on raw XML strings. Pitches are snapped to a
reporting ladder (0, ¼, ½, then whole numbers): measured slopes arrive as values like
10.31, and the PDF and these fields round through the same function so
they can't disagree.