get_candidate: Get Candidate Info https://www.propublica.org/datastore/apis...

View source: R/get_candidate.R

get_candidateR Documentation

Get Candidate Info https://www.propublica.org/datastore/apis GET https://api.propublica.org/campaign-finance/v1/cycle/candidates/fec-id

Description

Get Candidate Info https://www.propublica.org/datastore/apis GET https://api.propublica.org/campaign-finance/v1/cycle/candidates/fec-id

Usage

get_candidate(FEC_ID, cycle = 2018, page = 1, myAPI_Key)

Arguments

FEC_ID

The FEC-assigned 9-character ID of a candidate.

cycle

The election cycle must be even-numbered year between 1996 and 2018

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.

Value

a list object with the return values about candidate basic information

Examples

## Not run: 
get_candidate('P60005915', 2016)

## End(Not run)


ProPublicaR documentation built on Sept. 8, 2023, 5:53 p.m.