Reports Endpoint
Generate compliance reports, benchmark certificates, and custom data exports via the API.
Base path: /v1/reports
List available report types
curl https://api.sdx.dev/v1/reports/types \
-H "Authorization: Bearer YOUR_API_KEY"
Response:
{
"data": [
{
"type": "benchmark_certificate",
"description": "Single-page benchmark summary for one building",
"formats": ["pdf"],
"scope": "building"
},
{
"type": "portfolio_summary",
"description": "Aggregate performance across all buildings",
"formats": ["pdf", "xlsx"],
"scope": "organisation"
},
{
"type": "compliance_gresb",
"description": "GRESB performance component export",
"formats": ["xlsx"],
"scope": "organisation"
},
{
"type": "compliance_ll97",
"description": "NYC Local Law 97 compliance report",
"formats": ["pdf", "xlsx"],
"scope": "building"
},
{
"type": "compliance_berdo",
"description": "Boston BERDO compliance report",
"formats": ["pdf", "xlsx"],
"scope": "building"
},
{
"type": "custom",
"description": "Custom report from a saved template",
"formats": ["pdf", "xlsx", "csv", "json"],
"scope": "organisation"
}
]
}
Generate a report
Report generation is asynchronous. Submit a request and receive a report ID. Poll the status endpoint or use a webhook to be notified when the report is ready.
curl -X POST https://api.sdx.dev/v1/reports \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"type": "benchmark_certificate",
"building_id": "bld_3nf7p2q1",
"format": "pdf",
"reporting_period": {
"start": "2025-01-01",
"end": "2025-12-31"
}
}'
Response (202 Accepted):
{
"data": {
"id": "rpt_v7w8x9y0",
"type": "benchmark_certificate",
"status": "processing",
"format": "pdf",
"created_at": "2026-01-20T14:00:00Z",
"estimated_completion": "2026-01-20T14:01:00Z"
}
}
Check report status
curl https://api.sdx.dev/v1/reports/rpt_v7w8x9y0 \
-H "Authorization: Bearer YOUR_API_KEY"
Response (complete):
{
"data": {
"id": "rpt_v7w8x9y0",
"type": "benchmark_certificate",
"status": "complete",
"format": "pdf",
"download_url": "https://api.sdx.dev/v1/reports/rpt_v7w8x9y0/download",
"download_expires_at": "2026-01-21T14:00:00Z",
"file_size_bytes": 245760,
"created_at": "2026-01-20T14:00:00Z",
"completed_at": "2026-01-20T14:00:32Z"
}
}
Possible statuses: processing, complete, failed
Download a report
curl -OJ https://api.sdx.dev/v1/reports/rpt_v7w8x9y0/download \
-H "Authorization: Bearer YOUR_API_KEY"
Download URLs are valid for 24 hours. After expiry, request a new download URL by hitting the report status endpoint.
Generate a portfolio report
curl -X POST https://api.sdx.dev/v1/reports \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"type": "portfolio_summary",
"format": "xlsx",
"reporting_period": {
"start": "2025-01-01",
"end": "2025-12-31"
},
"filters": {
"type": "office",
"country": "US"
}
}'
List generated reports
curl https://api.sdx.dev/v1/reports?page=1&per_page=20 \
-H "Authorization: Bearer YOUR_API_KEY"
Returns a paginated list of all reports generated by the organisation, sorted by creation date (newest first).
Required scopes
| Action | Scope |
|---|---|
| List report types / List reports / Check status / Download | reports:read |
| Generate a report | reports:write |