Vai al contenuto
GET /v1/current

Current members of Congress

Provalo dal vivo

10 chiamate gratuite al giorno — senza registrazione, senza chiave API. Passa dal gateway oanor.

Intestazioni personalizzate (facoltative)
api.oanor.com/congress-api

Funziona. Prendi una chiave API e usala nel tuo progetto.

Ottieni una chiave API

Frammenti di codice

curl "https://api.oanor.com/congress-api/v1/current" \
  -H "x-oanor-key: oanor_test_..."
await fetch("https://api.oanor.com/congress-api/v1/current", {
  headers: { "x-oanor-key": "oanor_test_..." }
});
$ch = curl_init("https://api.oanor.com/congress-api/v1/current");
curl_setopt($ch, CURLOPT_HTTPHEADER, ["x-oanor-key: oanor_test_..."]);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
$out = curl_exec($ch);
import requests
requests.get(
    "https://api.oanor.com/congress-api/v1/current",
    headers={"x-oanor-key": "oanor_test_..."}
)

Risposta di esempio

Una risposta reale di questo endpoint, acquisita dall'ultimo health check.

{
    "data": {
        "count": 50,
        "limit": 50,
        "total": 100,
        "offset": 0,
        "filters": {
            "party": null,
            "state": null,
            "chamber": "senate"
        },
        "results": [
            {
                "name": "Maria Cantwell",
                "party": "Democrat",
                "state": "WA",
                "chamber": "senate",
                "current": true,
                "bioguide": "C000127",
                "district": null,
                "govtrack": 300018,
                "served_to": "2031-01-03",
                "term_count": 6,
                "served_from": "1993-01-05"
            },
            {
                "name": "Amy Klobuchar",
                "party": "Democrat",
                "state": "MN",
                "chamber": "senate",
                "current": true,
                "bioguide": "K000367",
                "district": null,
                "govtrack": 412242,
                "served_to": "2031-01-03",
                "term_count": 4,
                "served_from": "2007-01-04"
            },
            {
                "name": "Bernard Sanders",
                "party": "Independent",
                "state": "VT",
                "chamber": "senate",
                "current": true,
                "bioguide": "S000033",
                "district": null,
                "govtrack": 400357,
                "served_to": "2031-01-03",
                "term_count": 12,
                "served_from": "1991-01-03"
            },
            {
                "name": "Sheldon Whitehouse",
                "party": "Democrat",
                "state": "RI",
                "chamber": "senate",
                "current": true,
                "bioguide": "W000802",
                "district": null,
                "govtrack": 412247,
                "served_to": "2031-01-03",
                "term_count": 4,
                "served_from": "2007-01-04"
            },
            {
                "name": "John Barrasso",
                "party": "Republican",
                "state": "WY",
                "chamber": "senate",
                "current": true,
                "bioguide": "B001261",
                "district": null,
                "govtrack": 412251,
                "served_to": "2031-01-03",
                "term_count": 4,
                "served_from": "2007-06-25"
            },
            {
                "name": "Roger F. Wicker",
                "party": "Republican",
                "state": "MS",
                "chamber": "senate",
                "current": true,
                "bioguide": "W000437",
                "district": null,
                "govtrack": 400432,
                "served_to": "2031-01-03",
                "term_count": 11,
                "served_from": "1995-01-04"
            },
            {
                "name": "Susan M. Collins",
                "party": "Republican",
                "state
…