Learn R Programming

ProPublicaR (version 1.1.4)

get_recent_votes: Get Recent Votes

Description

You can get recent votes from the House, Senate or both chambers using this request. This request returns the 20 most recent results, sorted by date and roll call number, and you can paginate through votes using the offset querystring parameter that accepts multiples of 20. HTTP Request: GET https://api.propublica.org/congress/v1/chamber/votes/recent.json

Usage

get_recent_votes(chamber, page = 1, myAPI_Key)

Value

List of returned JSON from endpoint that retrieves the 20 most recent votes from the House, Senate or both chambers

Arguments

chamber

house, senate or both.

page

Results come in batches of 20. The page parameter specifies which one to retrieve.

myAPI_Key

API key from Propublica To use the congress API, you must sign up for an API key.

Examples

Run this code
if (FALSE) {
get_recent_votes('senate')
}

Run the code above in your browser using DataLab