### Metrics API Source: https://v3.openstates.org/docs/index Endpoint for retrieving API usage metrics. ```APIDOC ## GET /metrics ### Description Retrieves API usage metrics. ### Method GET ### Endpoint /metrics ### Parameters None ### Response #### Success Response (200) - **metrics** (object) - An object containing various usage metrics. #### Response Example ```json { "metrics": { "total_requests": 15000, "unique_users": 2500, "requests_last_hour": 500 } } ``` ``` -------------------------------- ### Events API Source: https://v3.openstates.org/docs/index Endpoints for retrieving lists of events and details for specific events. ```APIDOC ## GET /events ### Description Retrieves a list of legislative events. ### Method GET ### Endpoint /events ### Parameters #### Query Parameters - **jurisdiction** (string) - Optional - Filter by jurisdiction ID. - **session** (string) - Optional - Filter by legislative session. - **start_date** (string) - Optional - Filter by start date (YYYY-MM-DD). - **end_date** (string) - Optional - Filter by end date (YYYY-MM-DD). - **event_type** (string) - Optional - Filter by event type (e.g., 'hearing', 'floor session'). - **include** (array) - Optional - Fields to include in the response. - **fields** (array) - Optional - Specific fields to return for each event. ### Response #### Success Response (200) - **events** (array of Event) - A list of event objects matching the criteria. #### Response Example ```json { "events": [ { "id": "ocd-event/11223344-5566-7788-9900-aabbccddeeff", "name": "Budget Hearing", "jurisdiction": "ocd-division/country:us/state:ny", "session": { "name": "2023 Regular Session" }, "start_date": "2023-03-15T10:00:00Z" } ] } ``` ## GET /events/{event_id} ### Description Retrieves detailed information for a specific event. ### Method GET ### Endpoint /events/{event_id} ### Parameters #### Path Parameters - **event_id** (string) - Required - The unique identifier of the event. #### Query Parameters - **include** (array) - Optional - Fields to include in the response. - **fields** (array) - Optional - Specific fields to return for the event. ### Response #### Success Response (200) - **event** (Event) - The requested event object. #### Response Example ```json { "event": { "id": "ocd-event/11223344-5566-7788-9900-aabbccddeeff", "name": "Budget Hearing", "jurisdiction": "ocd-division/country:us/state:ny", "session": { "name": "2023 Regular Session" }, "start_date": "2023-03-15T10:00:00Z", "location": { "room": "Hearing Room 1", "building": "Legislative Office Building" } } } ``` ``` -------------------------------- ### Bills API Source: https://v3.openstates.org/docs/index Endpoints for searching and retrieving bill information. ```APIDOC ## GET /bills ### Description Searches for bills across different jurisdictions and sessions. ### Method GET ### Endpoint /bills ### Parameters #### Query Parameters - **jurisdiction** (string) - Optional - Filter by jurisdiction ID. - **session** (string) - Optional - Filter by legislative session. - **query** (string) - Optional - Full-text search query. - **bill_id** (string) - Optional - Filter by bill ID. - **bill_type** (string) - Optional - Filter by bill type (e.g., 'bill', 'resolution'). - **search_window** (string) - Optional - Time window for searching bills (e.g., 'session', 'full_term'). - **sort** (string) - Optional - Sort order for results. - **include** (array) - Optional - Fields to include in the response. - **fields** (array) - Optional - Specific fields to return for each bill. ### Response #### Success Response (200) - **bills** (array of Bill) - A list of bill objects matching the search criteria. #### Response Example ```json { "bills": [ { "id": "ocd-bill/12345678-abcd-1234-5678-12345678abcd", "identifier": "HB 101", "title": "An act relating to education.", "jurisdiction": "ocd-division/country:us/state:tx", "session": { "name": "2023 Regular Session", "start_date": "2023-01-10", "end_date": "2023-05-29" } } ] } ``` ## GET /bills/ocd-bill/{openstates_bill_id} ### Description Retrieves a specific bill by its Open States ID. ### Method GET ### Endpoint /bills/ocd-bill/{openstates_bill_id} ### Parameters #### Path Parameters - **openstates_bill_id** (string) - Required - The Open States identifier for the bill. #### Query Parameters - **include** (array) - Optional - Fields to include in the response. - **fields** (array) - Optional - Specific fields to return for the bill. ### Response #### Success Response (200) - **bill** (Bill) - The requested bill object. #### Response Example ```json { "bill": { "id": "ocd-bill/12345678-abcd-1234-5678-12345678abcd", "identifier": "HB 101", "title": "An act relating to education.", "jurisdiction": "ocd-division/country:us/state:tx" } } ``` ## GET /bills/{jurisdiction}/{session}/{bill_id} ### Description Retrieves a specific bill by its jurisdiction, session, and bill ID. ### Method GET ### Endpoint /bills/{jurisdiction}/{session}/{bill_id} ### Parameters #### Path Parameters - **jurisdiction** (string) - Required - The jurisdiction ID of the bill. - **session** (string) - Required - The legislative session ID. - **bill_id** (string) - Required - The bill identifier. #### Query Parameters - **include** (array) - Optional - Fields to include in the response. - **fields** (array) - Optional - Specific fields to return for the bill. ### Response #### Success Response (200) - **bill** (Bill) - The requested bill object. #### Response Example ```json { "bill": { "id": "ocd-bill/12345678-abcd-1234-5678-12345678abcd", "identifier": "HB 101", "title": "An act relating to education.", "jurisdiction": "ocd-division/country:us/state:tx", "session": { "name": "2023 Regular Session" } } } ``` ``` -------------------------------- ### Jurisdictions API Source: https://v3.openstates.org/docs/index Endpoints for retrieving a list of jurisdictions and details for a specific jurisdiction. ```APIDOC ## GET /jurisdictions ### Description Retrieves a list of all available jurisdictions. ### Method GET ### Endpoint /jurisdictions ### Parameters #### Query Parameters - **include** (array) - Optional - Fields to include in the response. - **fields** (array) - Optional - Specific fields to return for each jurisdiction. ### Response #### Success Response (200) - **jurisdictions** (array of Jurisdiction) - A list of jurisdiction objects. #### Response Example ```json { "jurisdictions": [ { "id": "ocd-division/country:us/state:al", "name": "Alabama", "url": "http://www.alabama.gov", "type": "state" } ] } ``` ## GET /jurisdictions/{jurisdiction_id} ### Description Retrieves detailed information for a specific jurisdiction. ### Method GET ### Endpoint /jurisdictions/{jurisdiction_id} ### Parameters #### Path Parameters - **jurisdiction_id** (string) - Required - The unique identifier of the jurisdiction (e.g., 'ocd-division/country:us/state:al'). #### Query Parameters - **include** (array) - Optional - Fields to include in the response. - **fields** (array) - Optional - Specific fields to return for the jurisdiction. ### Response #### Success Response (200) - **jurisdiction** (Jurisdiction) - A jurisdiction object. #### Response Example ```json { "jurisdiction": { "id": "ocd-division/country:us/state:al", "name": "Alabama", "url": "http://www.alabama.gov", "type": "state", "classification": "state", "country": "us", "feature_code": "ADM1" } } ``` ``` -------------------------------- ### People API Source: https://v3.openstates.org/docs/index Endpoints for searching for people and retrieving people based on geographic location. ```APIDOC ## GET /people ### Description Searches for people within the legislative system. ### Method GET ### Endpoint /people ### Parameters #### Query Parameters - **name** (string) - Optional - Filter by person's name. - **jurisdiction** (string) - Optional - Filter by jurisdiction ID. - **chamber** (string) - Optional - Filter by chamber (e.g., 'upper', 'lower'). - **role** (string) - Optional - Filter by role (e.g., 'legislator'). - **active** (boolean) - Optional - Filter by active status. - **sort** (string) - Optional - Sort order for results. - **include** (array) - Optional - Fields to include in the response. - **fields** (array) - Optional - Specific fields to return for each person. ### Response #### Success Response (200) - **people** (array of Person) - A list of person objects matching the search criteria. #### Response Example ```json { "people": [ { "id": "a64e0d5a-35f0-436e-b192-5e0c5a98e49a", "name": "John Doe", "given_name": "John", "family_name": "Doe", "roles": [ { "name": "State Representative", "start_date": "2023-01-01", "end_date": null, "jurisdiction": "ocd-division/country:us/state:al", "is_current": true, "links": [] } ] } ] } ``` ## GET /people.geo ### Description Retrieves people based on geographic location. ### Method GET ### Endpoint /people.geo ### Parameters #### Query Parameters - **lat** (number) - Required - Latitude of the location. - **lon** (number) - Required - Longitude of the location. - **radius** (number) - Optional - Search radius in kilometers. - **include** (array) - Optional - Fields to include in the response. - **fields** (array) - Optional - Specific fields to return for each person. ### Response #### Success Response (200) - **people** (array of Person) - A list of person objects within the specified geographic area. #### Response Example ```json { "people": [ { "id": "a64e0d5a-35f0-436e-b192-5e0c5a98e49a", "name": "Jane Smith", "roles": [ { "name": "State Senator", "jurisdiction": "ocd-division/country:us/state:ca" } ] } ] } ``` ``` -------------------------------- ### Committees API Source: https://v3.openstates.org/docs/index Endpoints for retrieving lists of committees and details for specific committees. ```APIDOC ## GET /committees ### Description Retrieves a list of legislative committees. ### Method GET ### Endpoint /committees ### Parameters #### Query Parameters - **jurisdiction** (string) - Optional - Filter by jurisdiction ID. - **session** (string) - Optional - Filter by legislative session. - **include** (array) - Optional - Fields to include in the response. - **fields** (array) - Optional - Specific fields to return for each committee. ### Response #### Success Response (200) - **committees** (array of Committee) - A list of committee objects. #### Response Example ```json { "committees": [ { "id": "ocd-committee/abcdef12-3456-7890-abcd-ef1234567890", "name": "Finance Committee", "jurisdiction": "ocd-division/country:us/state:ca", "session": { "name": "2023 Regular Session" } } ] } ``` ## GET /committees/{committee_id} ### Description Retrieves detailed information for a specific committee. ### Method GET ### Endpoint /committees/{committee_id} ### Parameters #### Path Parameters - **committee_id** (string) - Required - The unique identifier of the committee. #### Query Parameters - **include** (array) - Optional - Fields to include in the response. - **fields** (array) - Optional - Specific fields to return for the committee. ### Response #### Success Response (200) - **committee** (Committee) - The requested committee object. #### Response Example ```json { "committee": { "id": "ocd-committee/abcdef12-3456-7890-abcd-ef1234567890", "name": "Finance Committee", "jurisdiction": "ocd-division/country:us/state:ca", "session": { "name": "2023 Regular Session" }, "chair": { "name": "Senator Jane Doe" } } } ``` ``` === COMPLETE CONTENT === This response contains all available snippets from this library. No additional content exists. Do not make further requests.