Ask a question

AI answer to a question, from the documents only, with citations (counts as an AI call). Cached answers to the same question within a day don't use an AI call.

POST https://www.chicagopolitics.org/api/v1/answers

Authorizations

HeaderValue
AuthorizationBearer <key>. Get a key; see authentication.

Body

FieldTypeRequiredDescription
questionstringyes
kindstringOne of: matter, meeting.
yearinteger

Response

200 Answer

FieldTypeDescription
questionstring
answerstringCites sources inline as [n]
citationsobject[]
modelstring | null
cachedboolean

Example request

curl -X POST "https://www.chicagopolitics.org/api/v1/answers" \
  -H "Authorization: Bearer $CHICAGO_POLITICS_KEY" \
  -H "Content-Type: application/json" \
  -d '{"question":"What did the City Council approve for Foundry Park?"}'

Errors: 400, 401, 429 (see errors).