Class LegiScan_Pull
LegiScan API Pull Class
Basic pull class to generate API requests and decode responses. Doing something
interesting with the results is the job of LegiScan_Process
. Each get*()
function maps to the corresponding API operation, preparing the request array
and processing through LegiScan_Pull::apiRequest().
Copyright: 2010-2020 LegiScan LLC
License: https://opensource.org/licenses/BSD-2-Clause
Author: LegiScan API Team api@legiscan.com
See:
LegiScan_CommandLine
See:
LegiScan_Process
See:
LegiScan_Worker
Link: https://api.legiscan.com/dl/
Link: https://legiscan.com/legiscan
Located at LegiScan.php
public
|
|
public
array
|
|
public
array
|
|
public
array
|
#
getMasterListRaw( integer $session_id )
Get a master list of bills for a specific session_id optimized for
|
public
array
|
|
public
array
|
|
public
array
|
#
getAmendment( integer $amendment_id )
Get a copy of the bill amendment for the specified amendment id |
public
array
|
#
getSupplement( integer $supplement_id )
Get a copy of the bill supplement for the specified supplement id |
public
array
|
#
getRollCall( integer $roll_call_id )
Get the roll call record for a specified bill with vote summary and individual legislator vote information |
public
array
|
|
public
array
|
|
public
array
|
#
getSearchRaw( array $search )
Performs a raw search against the LegiScan national legislative database |
public
array
|
|
public
array
|
#
getDataset( integer $session_id, string $access_key )
Get a dataset archive payload for a specific session id |
public
array
|
#
getSessionPeople( integer $session_id )
Retrieve a list of people records active in a specific session id |
public
array
|
#
getSponsoredList( integer $people_id )
Retrieve a list of bills sponsored by an individual legislator |
protected
mixed[]
|
#
apiRequest( string $op, array $params )
Makes the actual request to the LegiScan API server via cURL |
public
boolean
|
#
importBillList( array $bills,
Process a bill_id list processing and requesting any necessary missing child objects |
public
string
|
|
public
string
|
#
getRawResponse( )
Return the JSON payload of the most recent Pull API request by |
public
string
|
protected
string
|
$api_key
LegiScan API key for requests from |
|
protected
string
|
$response
Raw response from an API call |
|
protected
mixed[]
|
$payload
Decoded associative array representing the API response |
|
protected
|
$cache
Cache layer interface |
|
protected
string
|
$request_url
Most recent Pull API request URL |