Skip to main content

Get Audit Reports

GET /api/v1/reports/audit/{audit_id} Returns all reports associated with an audit.
audit_id
integer
Audit ID
total_reports
integer
Number of reports available
reports
array
Array of report objects

Download Report

GET /api/v1/reports/download/{report_id} Redirects to signed Supabase URL for downloading the report file.
302
redirect
Redirects to signed download URL

Get Markdown Report

GET /api/v1/reports/markdown/{audit_id} Returns the audit report in Markdown format.
curl -X GET https://api.latentgeo.com/api/v1/reports/markdown/123 \
  -H "Authorization: Bearer YOUR_TOKEN"
{
  "audit_id": 123,
  "markdown": "# SEO Audit Report\n\n## Executive Summary...\n",
  "created_at": "2026-03-03T10:30:00Z"
}
audit_id
integer
Audit ID
markdown
string
Full report in Markdown format
created_at
string
Report creation timestamp

Get JSON Report

GET /api/v1/reports/json/{audit_id} Returns the audit report in structured JSON format.
audit_id
integer
Audit ID
url
string
Audited URL
domain
string
Domain name
status
string
Audit status
is_ymyl
boolean
Whether site is YMYL (Your Money Your Life)
category
string
Site category
target_audit
object
Complete audit data object
external_intelligence
object
External intelligence data
search_results
object
Search engine results data
fix_plan
array
Actionable fix plan

Generate PDF (Deprecated)

POST /api/v1/reports/generate-pdf
This endpoint is deprecated. Use POST /api/v1/audits/{audit_id}/generate-pdf instead.
Redirects to the new PDF generation endpoint with HTTP 307.

Error Codes

400
error
Report not ready or invalid request
404
error
Report not found
409
error
Legacy local PDF paths disabled (Supabase-only mode)
500
error
Internal server error

Build docs developers (and LLMs) love