LibraryOfCongress / api.congress.gov

congress.gov API
642 stars 39 forks source link

Bound congressional record: error with data since 2006 #155

Closed LatifaTam closed 5 months ago

LatifaTam commented 1 year ago

I tried to access the recent bound congressional record with the following link: https://api.congress.gov/v3/bound-congressional-record/1990?api_key=[INSERT_KEY] It's supposed to "Return a list of bound Congressional Records filtered by the specified year", according to https://api.congress.gov/#/. I was changing the "1990" to a wide range of numbers, and the calls worked perfectly with years before 2006. Starting from the year 2006 to the most recent(2023), the call doesn't respond with the expected result. For example, when I call the API with https://api.congress.gov/v3/bound-congressional-record/2020?api_key=[my_KEY], it returns error as the following: { "error": "Object of type HttpResponse is not JSON serializable (TypeError)" }

mnewatloc commented 1 year ago

This is a bit confusing to us, too. We support the Bound Congressional Record up to 1994 only: https://www.congress.gov/help/congressional-record

We wouldn't expect any search after that to produce results.

I see that the Government Publishing Office has it up to 2017: https://www.govinfo.gov/app/collection/crecb/163_crecb

Some of those have apparently made it into our API, even though they're not available on Congress.gov. This is not expected behavior and we are investigating.

LatifaTam commented 1 year ago

Thank you for the clarification. I didn't see the year limitation "up to 1994" in the documentation. Did I miss out on any documentation stating the range of variables(e.g. year variables only support 1994 or smaller)? For unexpected data that is currently available with your API(1995-2005), do you suggest it as a reliable data sources?

mnewatloc commented 12 months ago

We do not suggest using that data--we have not validated its accuracy. We're discussing suppressing that data until we have a chance to look it over.