NHLA Liberty Ratings

v1.1.0
org.nhliberty/liberty-ratings Checked 4 days ago Published 25 days ago

Liberty Ratings for every New Hampshire state legislator since 2006, and who represents a town.

These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.

grade_key

What each grade means for a given year, the percentage band it covered, and how many legislators received it. The bands change from year to year.

ParameterTypeDescription
yearintegerthe rating year; defaults to the most recent session

legislator_record

One legislator's Liberty Rating in every session they served, found by name, slug, personId or employeeNo. Joins the two employee numbers a member holds if they moved between the House and the Senate.

ParameterTypeDescription
legislator *stringa name, slug, personId or employeeNo
fromYearintegerearliest session to report
toYearintegerlatest session to report

legislator_votes

The roll calls NHLA scored in one session, how a legislator voted on each, and whether that matched NHLA's position. Optionally filtered to one bill, or with only to the votes against NHLA's position, with it, or missed. For "where did they vote against NHLA" pass only: "against" rather than reading every roll call.

ParameterTypeDescription
legislator *stringa name, slug, personId or employeeNo
billstringlimit to one bill, e.g. HB609
limitintegerhow many roll calls to return; default 50, maximum 200
onlystringreturn only the roll calls where they voted 'against' NHLA's position, voted 'with' it, or 'missed' the vote; omit for all
yearintegerthe session; defaults to the most recent one they served

legislators_for_town

Every state representative and senator for a New Hampshire town, with their Liberty Rating. Use this for "who represents me". A town is usually in more than one district; report all of them. For a city divided into wards, pass the ward. Given only a ZIP code, pass zip; a ZIP code covering several towns comes back asking which one.

ParameterTypeDescription
townstringthe town or city, spelled as a person would type it; pass this or zip
wardintegerthe ward number, in a city divided into wards
yearintegerthe rating year; defaults to the most recent session
zipstringa five-digit ZIP code, when the person gave that instead of a town

top_legislators

Ranks legislators statewide by Liberty Rating score for one session: the highest or the lowest scorers, in the House, the Senate or both, optionally within one party. Use this for "who scored highest", "the ten best senators" or "the lowest-rated Republicans". Legislators tied at the cut are all returned.

ParameterTypeDescription
chamberstring'house' or 'senate'; omit to rank both chambers together
limitintegerhow many to list; default 10, maximum 50. Legislators tied with the last one listed are always included
orderstring'highest' (the default) or 'lowest'
partystringlimit to one party: 'R', 'D', 'L' or 'I' (or the party's name)
yearintegerthe rating year; defaults to the most recent session