FOIA_Doc_Search / ingest /discovery.py
GodsDevProject's picture
Create ingest/discovery.py
505a0fe verified
from ingest.registry import get_all_adapters
def agency_discovery():
"""
Transparency-only discovery table.
"""
rows = []
for adapter in get_all_adapters():
rows.append({
"Agency": adapter.name,
"Status": "Live" if adapter.is_live else "Stub",
"Reason": (
"Public FOIA Reading Room"
if adapter.is_live
else "robots.txt blocked or no public endpoint"
)
})
return rows