API 사용

이 문서에서는 Google Civic Information API를 사용하기 위해 알아야 할 사항을 설명합니다. Civic Info API FAQ에서 API에 관한 기본 정보와 사용자 포럼에서 자주 묻는 질문(FAQ)을 확인할 수 있습니다. 또한 아래에서 두 가지 예를 확인할 수 있습니다. 하나는 선거 중에 유권자 정보를 검색하는 것이고 두 번째는 선출된 대표자를 검색하는 것입니다.

Google에 애플리케이션 식별

애플리케이션은 각 요청에 API 키를 포함하여 Google Civic Information API에 요청을 전송할 때마다 자신을 식별해야 합니다.

API 키 획득 및 사용

API 키를 획득하려면 다음 안내를 따르세요.

  1. API 콘솔에서 사용자 인증 정보 페이지를 엽니다.
  2. 이 API는 두 가지 유형의 사용자 인증 정보를 지원합니다. 프로젝트에 적합한 사용자 인증 정보를 만듭니다.
    • OAuth 2.0: 애플리케이션에서 비공개 사용자 데이터를 요청할 때마다 요청과 함께 OAuth 2.0 토큰을 보내야 합니다. 애플리케이션은 먼저 토큰을 획득하기 위해 클라이언트 ID나 클라이언트 보안 비밀번호를 보냅니다. 웹 애플리케이션, 서비스 계정, 설치된 애플리케이션의 OAuth 2.0 사용자 인증 정보를 생성할 수 있습니다.

      참고: 이 API에는 OAuth 2.0 승인이 필요한 메서드가 없으므로 아래 설명된 API 키만 가져오면 됩니다. 하지만 애플리케이션이 사용자 승인이 필요한 다른 API를 호출하는 경우에도 OAuth 2.0 사용자 인증 정보가 필요합니다.

      자세한 내용은 OAuth 2.0 문서를 참조하세요.

    • API 키: OAuth 2.0 토큰을 제공하지 않는 요청은 API 키를 전송해야 합니다. 키는 프로젝트를 식별하고 API 액세스, 할당량, 보고서를 제공합니다.

      API는 여러 유형의 API 키 제한 사항을 지원합니다. 필요한 API 키가 아직 없는 경우 사용자 인증 정보 만들기 > API 키를 클릭하여 Console에서 API 키를 만듭니다. 프로덕션 단계에서 사용하기 전에 키 제한을 클릭하고 제한사항 중 하나를 선택하여 키를 제한할 수 있습니다.

API 키를 안전하게 보호하려면 API 키를 안전하게 사용하기 위한 권장사항을 따르세요.

API 키가 있으면 애플리케이션은 모든 요청 URL에 쿼리 매개변수 key=yourAPIKey를 추가할 수 있습니다.

API 키는 URL에 포함하기에 안전합니다. 인코딩이 전혀 필요하지 않습니다.

API 키 제한사항

API 키는 기본적으로 제한되지 않습니다. 따라서 누구나 이 키를 읽거나 (예: 브라우저 내에 배치된 경우) 키가 있는 기기에 액세스할 수 있다면 안전하지 않습니다. 승인되지 않은 사용을 방지하려면 이 API 키에 제한을 적용하는 것이 좋습니다.

제한사항을 추가하려면 API 키 생성됨 대화상자에서 키 제한을 클릭합니다. API 키 구성 패널이 표시됩니다.

선택하는 제한사항 유형은 애플리케이션 요구사항에 따라 달라집니다.

  • 백엔드나 미들웨어를 통하지 않고 API와 직접 상호작용하는 웹 애플리케이션은 HTTP 리퍼러 제한을 추가해야 합니다. 그러나 이러한 애플리케이션은 API 키를 공개적으로 노출하므로 서비스 계정 인증 스키마를 대신 사용하는 것이 좋습니다.
  • 달리 서비스 계정을 지원할 수 없는 백엔드 애플리케이션(예: 클라이언트 라이브러리에 지원되는 언어가 없는 내장형 기기)은 서로 다른 IP 주소의 클라이언트에서 사용하지 못하도록 보호하려면 IP 주소 제한을 추가해야 합니다.
  • Android 애플리케이션은 Android 앱 제한을 추가하고 패키지 이름과 SHA-1 서명 인증서 디지털 지문을 추가해야 합니다.
  • iOS 애플리케이션은 iOS 앱 제한을 추가하고 모든 iOS 번들 식별자를 추가하여 이러한 iOS 번들로 API 호출을 제한해야 합니다.

테스트를 위해 제한을 두지 않을 수도 있습니다. 하지만 프로덕션에 애플리케이션을 배포한 후 이 키에 제한사항을 추가하거나 삭제하는 것이 좋습니다.

선거 쿼리 예

다음은 electionQuery API를 호출하여 유효한 선거 ID 목록을 가져온 다음, voterInfoQuery API를 유권자의 등록 주소와 함께 사용하여 선택한 선거에 대한 정보를 가져오는 예입니다 (API 버전 'v2' 사용).

ElectionQuery를 사용하여 유효한 선거 ID 목록 가져오기:

  https://www.googleapis.com/civicinfo/v2/elections?key=<YOUR_API_KEY>
  

선거 쿼리 응답:

{
 "kind": "civicinfo#electionsqueryresponse",
 "elections": [
  {
   "id": "2000",
   "name": "VIP Test Election",
   "electionDay": "2013-06-06"
  },
  {
   "id": "2124",
   "name": "Rhode Island 2012 Primary Election",
   "electionDay": "2012-09-11"
  },
  {
   "id": "2126",
   "name": "Delaware 2012 Primary Election",
   "electionDay": "2012-09-11"
  }
 ]
}

curl을 사용한 votesrInfoQuery

curl을 사용하여 VIP 테스트 선거 ID 2000 및 (테스트) 주소 1263 Pacific Ave. Kansas City, KS의 유권자에 대한 투표자 정보 쿼리를 보냅니다 (아래의 voterInfoQuery 응답 참고).

curl "https://www.googleapis.com/civicinfo/v2/voterinfo?key=<YOUR_API_KEY>&address=1263%20Pacific%20Ave.%20Kansas%20City%20KS&electionId=2000"

JavaScript용 Google API 클라이언트 라이브러리를 사용하는 votesrInfoQuery

이 예에서는 이전 curl 예와 동일한 투표자 정보 쿼리를 실행하지만 JavaScript 클라이언트 라이브러리를 사용합니다. voterInfoQuery 응답은 curl 예 응답과 동일합니다.

<!doctype html>
<html>
  <head>
    <script>
      /**
       * Build and execute request to look up voter info for provided address.
       * @param {string} address Address for which to fetch voter info.
       * @param {function(Object)} callback Function which takes the
       *     response object as a parameter.
       */
       function lookup(address, callback) {
       /**
         * Election ID for which to fetch voter info.
         * @type {number}
         */
        var electionId = 2000;
 
        /**
         * Request object for given parameters.
         * @type {gapi.client.HttpRequest}
         */
        var req = gapi.client.request({
            'path' : '/civicinfo/v2/voterinfo',
            'params' : {'electionId' : electionId, 'address' : address}
        });
       req.execute(callback);
      }

      /**
       * Render results in the DOM.
       * @param {Object} response Response object returned by the API.
       * @param {Object} rawResponse Raw response from the API.
       */
      function renderResults(response, rawResponse) {
        var el = document.getElementById('results');
        if (!response || response.error) {
          el.appendChild(document.createTextNode(
              'Error while trying to fetch polling place'));
          return;
        }
        var normalizedAddress = response.normalizedInput.line1 + ' ' +
            response.normalizedInput.city + ', ' +
            response.normalizedInput.state + ' ' +
            response.normalizedInput.zip;
        if (response.pollingLocations.length > 0) {
          var pollingLocation = response.pollingLocations[0].address;
          var pollingAddress = pollingLocation.locationName + ', ' +
              pollingLocation.line1 + ' ' +
              pollingLocation.city + ', ' +
              pollingLocation.state + ' ' +
              pollingLocation.zip;
          var normEl = document.createElement('strong');
          normEl.appendChild(document.createTextNode(
              'Polling place for ' + normalizedAddress + ': '));
          el.appendChild(normEl);
          el.appendChild(document.createTextNode(pollingAddress));
        } else {
          el.appendChild(document.createTextNode(
              'Could not find polling place for ' + normalizedAddress));
        }
      }

      /**
       * Initialize the API client and make a request.
       */
      function load() {
        gapi.client.setApiKey('YOUR API KEY GOES HERE');
        lookup('1263 Pacific Ave. Kansas City KS', renderResults);
      }
    </script>
    <script src="https://apis.google.com/js/client.js?onload=load"></script>
  </head>
  <body>
    <div id="results"></div>
  </body>
</html>

투표자 정보 쿼리 응답:

{
 "kind": "civicinfo#voterinforesponse",
 "status": "success",
 "election": {
  "id": "2000",
  "name": "VIP Test Election",
  "electionDay": "2013-06-06"
 },
 "normalizedInput": {
  "line1": "1263 Pacific Ave",
  "city": "Kansas City",
  "state": "KS",
  "zip": "66102"
 },
 "pollingLocations": [
  {
   "address": {
    "locationName": "National Guard Armory",
    "line1": "100 S 20th St",
    "line2": "",
    "line3": "",
    "city": "Kansas City",
    "state": "KS",
    "zip": "66102 "
   },
   "pollingHours": " - "
  }
 ],
 "contests": [
  {
   "type": "General",
   "office": "Attorney"
  },
  {
   "type": "General",
   "office": "Sheriff"
  },
  {
   "type": "General",
   "office": "Kansas Representative 32",
   "district": {
    "name": "Kansas Representative 32",
    "scope": "stateLower",
    "id": "32"
   },
   "sources": [
    {
     "name": "Voting Information Project",
     "official": true
    }
   ]
  },
  {
   "type": "General",
   "office": "Governor/Lt. Governor",
   "candidates": [
    {
     "name": "Andrew P.  Gray",
     "party": "Libertarian",
     "email": "chair@lpks.org"
    },
    {
     "name": "Kenneth (ken) W. Cannon",
     "party": "Reform"
    },
    {
     "name": "Tom Holland",
     "party": "Democratic",
     "candidateUrl": "www.tomhollandforkansas.com",
     "email": "info@tomhollandforkansas.com"
    },
    {
     "name": "Sam Brownback",
     "party": "Republican",
     "candidateUrl": "www.brownbackforkansas.com",
     "email": "media@brownback.com"
    }
   ]
  },
  {
   "type": "General",
   "office": "KCKCC Member AL Brd of Trustee"
  },
  {
   "type": "General",
   "office": "Secretary of State",
   "candidates": [
    {
     "name": "Chris Biggs",
     "party": "Democratic"
    },
    {
     "name": "Kris Kobach",
     "party": "Republican"
    },
    {
     "name": "Phillip Horatio Lucas",
     "party": "Libertarian"
    },
    {
     "name": "Derek Langseth",
     "party": "Reform"
    }
   ]
  },
  {
   "type": "General",
   "office": "U.S. Senate",
   "district": {
    "name": "U.S. Senate",
    "scope": "statewide",
    "id": "5"
   },
   "candidates": [
    {
     "name": "Lisa Johnston",
     "party": "Democratic",
     "candidateUrl": "www.lisaforkansas.com",
     "phone": "913-662-1457",
     "email": "lisa@lisaforkansas.com"
    },
    {
     "name": "Jerry Moran",
     "party": "Republican"
    },
    {
     "name": "Michael Wm. Dann",
     "party": "Libertarian"
    },
    {
     "name": "Joseph (joe) K. Bellis",
     "party": "Reform"
    }
   ],
   "sources": [
    {
     "name": "Voting Information Project",
     "official": true
    }
   ]
  },
  {
   "type": "General",
   "office": "BD of Public Utilities 2"
  },
  {
   "type": "General",
   "office": "Attorney General",
   "candidates": [
    {
     "name": "Steve Six",
     "party": "Democratic"
    },
    {
     "name": "Derek Schmidt",
     "party": "Republican"
    },
    {
     "name": "Dennis Hawver",
     "party": "Libertarian"
    }
   ]
  },
  {
   "type": "General",
   "office": "U.S. Representative 3"
  },
  {
   "type": "General",
   "office": "Governor/Lt. Governor",
   "district": {
    "name": "Governor/Lt. Governor",
    "scope": "statewide",
    "id": "1"
   },
   "candidates": [
    {
     "name": "Andrew P.  Gray",
     "party": "Libertarian",
     "email": "chair@lpks.org"
    },
    {
     "name": "Kenneth (ken) W. Cannon",
     "party": "Reform"
    },
    {
     "name": "Tom Holland",
     "party": "Democratic",
     "candidateUrl": "www.tomhollandforkansas.com",
     "email": "info@tomhollandforkansas.com"
    },
    {
     "name": "Sam Brownback",
     "party": "Republican",
     "candidateUrl": "www.brownbackforkansas.com",
     "email": "media@brownback.com"
    }
   ],
   "sources": [
    {
     "name": "Voting Information Project",
     "official": true
    }
   ]
  },
  {
   "type": "General",
   "office": "Commissioner-At-Large 2"
  },
  {
   "type": "General",
   "office": "Kansas Senate 6"
  },
  {
   "type": "General",
   "office": "Clerk"
  },
  {
   "type": "General",
   "office": "President / Vice President"
  },
  {
   "type": "General",
   "office": "Register of Deeds"
  },
  {
   "type": "General",
   "office": "BD of Public Utilities (AL)"
  },
  {
   "type": "General",
   "office": "Commissioner 2"
  },
  {
   "type": "General",
   "office": "USD 500"
  },
  {
   "type": "General",
   "office": "State Board of Education 1"
  },
  {
   "type": "General",
   "office": "Treasurer"
  }
 ],
 "state": [
  {
   "name": "State of Kansas",
   "electionAdministrationBody": {
    "name": "Kansas",
    "electionOfficials": [
     {
      "name": "Brad Bryant",
      "title": "Election Director",
      "officePhoneNumber": "785-296-4561",
      "emailAddress": "cclark@essvote.com"
     }
    ]
   },
   "local_jurisdiction": {
    "name": "Wyandotte",
    "electionAdministrationBody": {
     "name": "Wyandotte",
     "electionInfoUrl": "http://www.wycokck.org/election",
     "electionOfficials": [
      {
       "name": "Bruce Newby",
       "title": "Election Commissioner",
       "officePhoneNumber": "(913) 573-8500",
       "emailAddress": "hbbrooks@essvote.com"
      }
     ]
    },
    "sources": [
     {
      "name": "Voting Information Project",
      "official": true
     }
    ]
   },
   "sources": [
    {
     "name": "Voting Information Project",
     "official": true
    }
   ]
  }
 ]
}

curl을 사용한 대표 정보 쿼리

다음은 주소의 선출된 대리인을 조회하는 예입니다. curl을 사용하여 (테스트) 주소 1263 Pacific Ave. Kansas City, KS에 대한 representativeInfoByAddress 요청을 보냅니다(아래의 representativeInfoByAddress 응답 참고).

curl "https://www.googleapis.com/civicinfo/v2/representatives?key=<YOUR_API_KEY>&address=1263%20Pacific%20Ave.%20Kansas%20City%20KS"

오류 신고

선출된 공무원에 대한 정보가 누락되었거나 잘못되었나요? 공무원이 임기가 끝나기 전에 퇴사하거나 연락처 정보를 변경하는 경우가 있습니다. Google에서 반환하는 데이터에 아직 반영되지 않은 변경사항에 대해 알려주세요.

Google에서는 다른 사용자, 데이터 제공업체 또는 공식 정부 데이터 소스를 통해 신고 내용을 확인합니다. 신고 건수가 많아 직접 답변을 드리지 못할 수도 있습니다. 변경사항이 승인되는 경우 변경사항이 API 결과에 표시되는 데 다소 시간이 걸릴 수 있습니다.

오류를 신고하려면 이 양식을 작성하세요.

대표 정보별 주소 응답:

{
 "kind": "civicinfo#representativeInfoResponse",
 "status": "success",
 "normalizedInput": {
  "line1": "1263 pacific ave",
  "city": "kansas city",
  "state": "KS",
  "zip": "66102"
 },
 "divisions": {
  "ocd-division/country:us/state:ks/county:wyandotte/council_district:2": {
   "name": "Wyandotte County Commissioner District 2",
   "scope": "countyCouncil"
  },
  "ocd-division/country:us/state:ks/cd:3": {
   "name": "Kansas's 3rd congressional district",
   "scope": "congressional",
   "officeIndices": [ 0 ]
  },
  "ocd-division/country:us/state:ks/sldl:32": {
   "name": "Kansas House of Representatives district 32",
   "scope": "stateLower",
   "officeIndices": [ 1 ]
  },
  "ocd-division/country:us/state:ks/place:kansas_city": {
   "name": "Kansas City city",
   "scope": "citywide",
   "officeIndices": [ 2, 3, 4, 5, 6, 7, 8 ]
  },
  "ocd-division/country:us/state:ks/county:wyandotte": {
   "name": "Wyandotte County",
   "scope": "countywide"
  },
  "ocd-division/country:us": {
   "name": "United States",
   "scope": "national",
   "officeIndices": [ 9, 10 ]
  },
  "ocd-division/country:us/state:ks": {
   "name": "Kansas",
   "scope": "statewide",
   "officeIndices": [ 11, 12, 13, 14, 15, 16, 17 ]
  },
  "ocd-division/country:us/state:ks/sldu:6": {
   "name": "Kansas State Senate district 6",
   "scope": "stateUpper",
   "officeIndices": [ 18 ]
  }
 },
 "offices": [
  {
   "name": "United States House of Representatives KS-03",
   "level": "federal",
   "officialIndices": [ 0 ]
  },
  {
   "name": "KS State House District 32",
   "level": "state",
   "officialIndices": [ 1 ]
  },
  {
   "name": "Sheriff",
   "level": "county",
   "officialIndices": [ 2 ]
  },
  {
   "name": "District Attorney",
   "level": "county",
   "officialIndices": [ 3 ]
  },
  {
   "name": "Register of Deeds",
   "level": "county",
   "officialIndices": [ 4 ]
  },
  {
   "name": "Director of Revenue",
   "level": "county",
   "officialIndices": [ 5 ]
  },
  {
   "name": "Unified Government Clerk",
   "level": "county",
   "officialIndices": [ 6 ]
  },
  {
   "name": "Unified Government Commission, At Large, District 1",
   "level": "county",
   "officialIndices": [ 7 ]
  },
  {
   "name": "Unified Government Commission, At Large, District 2",
   "level": "county",
   "officialIndices": [ 8 ]
  },
  {
   "name": "President",
   "level": "federal",
   "officialIndices": [ 9 ]
  },
  {
   "name": "Vice President",
   "level": "federal",
   "officialIndices": [ 10 ]
  },
  {
   "name": "Governor",
   "level": "state",
   "officialIndices": [ 11 ]
  },
  {
   "name": "State Treasurer",
   "level": "state",
   "officialIndices": [ 12 ]
  },
  {
   "name": "Attorney General",
   "level": "state",
   "officialIndices": [ 13 ]
  },
  {
   "name": "Secretary of State",
   "level": "state",
   "officialIndices": [ 14 ]
  },
  {
   "name": "Lieutenant Governor",
   "level": "state",
   "officialIndices": [ 15 ]
  },
  {
   "name": "United States Senate",
   "level": "federal",
   "officialIndices": [ 16, 17 ]
  },
  {
   "name": "Insurance Commissioner",
   "level": "state",
   "officialIndices": [ 18 ]
  },
  {
   "name": "KS State Senate District 6",
   "level": "state",
   "officialIndices": [ 19 ]
  }
 ],
 "officials": [
  {
   "name": "Kevin Yoder",
   "address": [
    {
     "line1": "215 Cannon HOB",
     "city": "washington d.c.",
     "state": "DC",
     "zip": "20515"
    }
   ],
   "party": "Republican",
   "phones": [
    "(202) 225-2865"
   ],
   "urls": [
    "http://yoder.house.gov/"
   ],
   "photoUrl": "http://yoder.house.gov/images/user_images/headshot.jpg",
   "channels": [
    {
     "type": "Facebook",
     "id": "CongressmanKevinYoder"
    },
    {
     "type": "Twitter",
     "id": "RepKevinYoder"
    }
   ]
  },
  {
   "name": "Mike Peterson",
   "address": [
    {
     "line1": "450 North 17th",
     "city": "kansas city",
     "state": "KS",
     "zip": "66102"
    }
   ],
   "party": "Democratic",
   "phones": [
    "(785) 296-7371"
   ],
   "urls": [
    "http://www.kslegislature.org/li/b2013_14/members/rep_peterson_michael_1/"
   ],
   "photoUrl": "http://www.kslegislature.org/li/m/images/pics/rep_peterson_michael_1.jpg",
   "emails": [
    "michael.peterson@house.ks.gov"
   ]
  },
  {
   "name": "Donald Ash",
   "address": [
    {
     "line1": "701 Nth 7th Street Suite 20",
     "city": "kansas city",
     "state": "KS",
     "zip": "66101"
    }
   ],
   "party": "Democratic",
   "phones": [
    "(913) 573-2861"
   ],
   "urls": [
    "http://www.wycokck.org/DefaultDept32.aspx?id=2614"
   ],
   "emails": [
    "dash@wycokck.org"
   ]
  },
  {
   "name": "Jerome Gorman",
   "address": [
    {
     "line1": "701 Nth 7th Street Suite 10",
     "city": "kansas city",
     "state": "KS",
     "zip": "66101"
    }
   ],
   "party": "Democratic",
   "phones": [
    "(913) 573-2851"
   ],
   "urls": [
    "http://www.wycokck.org/Internet2010DistAttyBanner.aspx?id=176&banner=6912&menu_id=946"
   ]
  },
  {
   "name": "Nancy Burns",
   "address": [
    {
     "line1": "710 n. 7th street",
     "city": "kansas city",
     "state": "KS",
     "zip": "66101"
    }
   ],
   "party": "Unknown",
   "phones": [
    "(913) 573-2841"
   ],
   "urls": [
    "http://www.wycokck.org/Internetdept.aspx?id=2600&menu_id=1024&banner=15284"
   ],
   "emails": [
    "nburns@wycokck.org"
   ]
  },
  {
   "name": "Debbie Pack",
   "address": [
    {
     "line1": "710 n. 7th street",
     "city": "kansas city",
     "state": "KS",
     "zip": "66101"
    }
   ],
   "party": "Unknown",
   "phones": [
    "(913) 573-2821"
   ],
   "urls": [
    "http://www.wycokck.org/treasury/"
   ],
   "emails": [
    "dpack@wycokck.org"
   ]
  },
  {
   "name": "Bridgette D. Cobbins",
   "address": [
    {
     "line1": "710 n. 7th street",
     "city": "kansas city",
     "state": "KS",
     "zip": "66101"
    }
   ],
   "party": "Unknown",
   "phones": [
    "(913) 573-5260"
   ],
   "urls": [
    "http://www.wycokck.org/InternetDept.aspx?id=18992&menu_id=554&terms=Bridgette%20Cobbins"
   ],
   "emails": [
    "clerkwest@wycokck.org"
   ]
  },
  {
   "name": "Vacant",
   "address": [
    {
     "line1": "701 Nth 7th Street Suite 979",
     "city": "kansas city",
     "state": "KS",
     "zip": "66101"
    }
   ],
   "party": "Unknown",
   "phones": [
    "(913) 573-5040"
   ],
   "urls": [
    "http://www.wycokck.org/InternetDept.aspx?id=5750&menu_id=1278&banner=15284"
   ],
   "channels": [
    {
     "type": "Facebook",
     "id": "cityofkck"
    },
    {
     "type": "Twitter",
     "id": "CityofKCK"
    }
   ]
  },
  {
   "name": "John Mendez",
   "address": [
    {
     "line1": "701 Nth 7th Street Suite 979",
     "city": "kansas city",
     "state": "KS",
     "zip": "66101"
    }
   ],
   "party": "Unknown",
   "phones": [
    "(913) 573-5040"
   ],
   "urls": [
    "http://www.wycokck.org/Internetdept.aspx?id=5752&menu_id=1278&banner=15284"
   ],
   "emails": [
    "jmendez@wycokck.org"
   ],
   "channels": [
    {
     "type": "Facebook",
     "id": "cityofkck"
    },
    {
     "type": "Twitter",
     "id": "CityofKCK"
    }
   ]
  },
  {
   "name": "Barack Hussein Obama II",
   "address": [
    {
     "line1": "The White House",
     "line2": "1600 Pennsylvania Avenue NW",
     "line3": "",
     "city": "Washington",
     "state": "DC",
     "zip": "20500"
    }
   ],
   "party": "Democrat",
   "phones": [
    "(202) 456-1111",
    "(202) 456-1414"
   ],
   "urls": [
    "http://www.whitehouse.gov/administration/president_obama/",
    "http://www.barackobama.com/index.php"
   ],
   "photoUrl": "http://www.whitehouse.gov/sites/default/files/imagecache/admin_official_lowres/administration-official/ao_image/president_official_portrait_hires.jpg",
   "channels": [
    {
     "type": "GooglePlus",
     "id": "110031535020051778989"
    },
    {
     "type": "Twitter",
     "id": "barackobama"
    },
    {
     "type": "Facebook",
     "id": "barackobama"
    },
    {
     "type": "YouTube",
     "id": "barackobama"
    }
   ]
  },
  {
   "name": "Joseph (Joe) Robinette Biden Jr.",
   "address": [
    {
     "line1": "The White House",
     "line2": "1600 Pennsylvania Avenue NW",
     "line3": "",
     "city": "Washington",
     "state": "DC",
     "zip": "20500"
    }
   ],
   "party": "Democrat",
   "urls": [
    "http://www.whitehouse.gov/administration/vice-president-biden"
   ],
   "photoUrl": "http://www.whitehouse.gov/sites/default/files/imagecache/admin_official_lowres/administration-official/ao_image/vp_portrait.jpeg",
   "channels": [
    {
     "type": "Twitter",
     "id": "VP"
    },
    {
     "type": "Twitter",
     "id": "JoeBiden"
    },
    {
     "type": "Facebook",
     "id": "joebiden"
    }
   ]
  },
  {
   "name": "Sam Brownback",
   "address": [
    {
     "line1": "Capitol",
     "line2": "300 sw 10th ave.",
     "city": "topeka",
     "state": "KS",
     "zip": "66612"
    }
   ],
   "phones": [
    "(785) 296-3232"
   ],
   "urls": [
    "http://www.governor.ks.gov/"
   ],
   "channels": [
    {
     "type": "Facebook",
     "id": "govsambrownback"
    },
    {
     "type": "Twitter",
     "id": "govsambrownback"
    }
   ]
  },
  {
   "name": "Ron Estes",
   "address": [
    {
     "line1": "Kansas State Treasurer 900 SW Jackson",
     "line2": "Suite 201",
     "city": "topeka",
     "state": "KS",
     "zip": "66612"
    }
   ],
   "phones": [
    "(785) 296-3171"
   ],
   "urls": [
    "http://www.kansasstatetreasurer.com/prodweb/main/index.php"
   ],
   "emails": [
    "ron@treasurer.ks.gov"
   ],
   "channels": [
    {
     "type": "Facebook",
     "id": "130975650300043"
    },
    {
     "type": "Twitter",
     "id": "RonEstesKS"
    }
   ]
  },
  {
   "name": "Derek Schmidt",
   "address": [
    {
     "line1": "120 SW 10th Ave",
     "line2": "2nd Floor",
     "city": "topeka",
     "state": "KS",
     "zip": "66612"
    }
   ],
   "phones": [
    "(785) 296-2215"
   ],
   "urls": [
    "http://ag.ks.gov/"
   ],
   "channels": [
    {
     "type": "Twitter",
     "id": "KSAGOffice"
    }
   ]
  },
  {
   "name": "Kris Kobach",
   "address": [
    {
     "line1": "Kansas Secretary of State Memorial Hall",
     "line2": "1st Floor",
     "line3": "120 sw 10th avenue",
     "city": "topeka",
     "state": "KS",
     "zip": "66612"
    }
   ],
   "phones": [
    "(785) 296-4564"
   ],
   "urls": [
    "http://www.kssos.org/"
   ],
   "emails": [
    "kssos@sos.ks.gov"
   ],
   "channels": [
    {
     "type": "Facebook",
     "id": "Kansas-Secretary-of-State"
    },
    {
     "type": "Twitter",
     "id": "kansassos"
    }
   ]
  },
  {
   "name": "Jeff Coyler",
   "address": [
    {
     "line1": "State Capitol",
     "line2": "2nd Floor",
     "line3": "300 sw 10th ave.",
     "city": "topeka",
     "state": "KS",
     "zip": "66612"
    }
   ],
   "phones": [
    "(785) 296-2214"
   ],
   "urls": [
    "https://governor.ks.gov/about-the-office/lt-govenor-jeff-colyer"
   ]
  },
  {
   "name": "Jerry Moran",
   "address": [
    {
     "line1": "361A Russell Senate Office Building",
     "city": "washington d.c.",
     "state": "DC",
     "zip": "20510"
    }
   ],
   "party": "Republican",
   "phones": [
    "(202) 224-6521"
   ],
   "urls": [
    "http://www.moran.senate.gov/public/"
   ],
   "photoUrl": "http://moran.senate.gov/public/index.cfm/files/serve?File_id=cd666b47-46e3-4a48-bcf1-ea2890f99817",
   "channels": [
    {
     "type": "Facebook",
     "id": "jerrymoran"
    },
    {
     "type": "Twitter",
     "id": "JerryMoran"
    },
    {
     "type": "YouTube",
     "id": "senatorjerrymoran"
    }
   ]
  },
  {
   "name": "Pat Roberts",
   "address": [
    {
     "line1": "109 Hart Senate Office Building",
     "city": "washington d.c.",
     "state": "DC",
     "zip": "20510"
    }
   ],
   "party": "Republican",
   "phones": [
    "(202) 224-4774"
   ],
   "urls": [
    "http://www.roberts.senate.gov/public/"
   ],
   "photoUrl": "http://roberts.senate.gov/public/index.cfm?a=Files.Serve&File_id=b42c6b05-966e-48ea-b3ed-9e5fc4ab1a0d",
   "emails": [
    "pat_roberts@roberts.senate.gov"
   ],
   "channels": [
    {
     "type": "Facebook",
     "id": "SenPatRoberts"
    },
    {
     "type": "Twitter",
     "id": "SenPatRoberts"
    },
    {
     "type": "YouTube",
     "id": "SenPatRoberts"
    }
   ]
  },
  {
   "name": "Sandy Praeger",
   "address": [
    {
     "line1": "420 sw 9th street",
     "city": "topeka",
     "state": "KS",
     "zip": "66612"
    }
   ],
   "phones": [
    "(785) 296-3071"
   ],
   "urls": [
    "http://www.ksinsurance.org/"
   ],
   "emails": [
    "commissioner@ksinsurance.org"
   ],
   "channels": [
    {
     "type": "Facebook",
     "id": "KansasInsuranceDepartment"
    }
   ]
  },
  {
   "name": "Pat Pettey",
   "address": [
    {
     "line1": "Kansas State Capitol",
     "line2": "300 SW 10th St.",
     "line3": "Room 125-E",
     "city": "Topeka",
     "state": "KS",
     "zip": "66612-1504"
    },
    {
     "line1": "5316 Lakewood Street",
     "line2": "",
     "line3": "",
     "city": "Kansas City",
     "state": "KS",
     "zip": "66106"
    }
   ],
   "party": "Democratic",
   "phones": [
    "(785) 296-7375"
   ],
   "urls": [
    "http://www.kslegislature.org/li/b2013_14/members/sen_pettey_pat_1/"
   ],
   "photoUrl": "http://www.kslegislature.org/li/m/images/pics/sen_pettey_pat_1.jpg",
   "emails": [
    "Pat.Pettey@senate.ks.gov"
   ],
   "channels": [
    {
     "type": "Twitter",
     "id": "PatHPettey"
    },
    {
     "type": "Facebook",
     "id": "PetteyForSenate"
    }
   ]
  }
 ]
}