Besides the master people.xml file, there is a Congress-specific people.xml file for each recent Congress. For instance, data/us/112/people.xml mimics the layout of the master people.xml file but only contains those Members of Congress who have or had a role during that particular Congress and the roles they served in that Congress only. Because of resignations and deaths the file contains Members of Congress no longer serving, if they served at some point during the Congress.
Here is an example record from the master people.xml file:
<people> ... <person id='300087' lastname='Schumer' firstname='Charles' middlename='E.' birthday='1950-11-23' gender='M' pvsid='26976' osid='N00001093' bioguideid='S000148' metavidid='Charles_Schumer' youtubeid='senatorschumer' name='Sen. Charles Schumer [D, NY]' title='Sen.' state='NY' > <role type='rep' startdate='1981-01-05' enddate='1982-12-23' party='Democrat' state='NY' district='16' /> <role type='rep' startdate='1983-01-03' enddate='1984-10-12' party='Democrat' state='NY' district='10' /> <role type='rep' startdate='1985-01-03' enddate='1986-10-18' party='Democrat' state='NY' district='10' /> <role type='rep' startdate='1987-01-06' enddate='1988-10-22' party='Democrat' state='NY' district='10' /> <role type='rep' startdate='1989-01-03' enddate='1990-10-28' party='Democrat' state='NY' district='10' /> <role type='rep' startdate='1991-01-03' enddate='1992-10-09' party='Democrat' state='NY' district='10' /> <role type='rep' startdate='1993-01-05' enddate='1994-12-01' party='Democrat' state='NY' district='9' /> <role type='rep' startdate='1995-01-04' enddate='1996-10-04' party='Democrat' state='NY' district='9' /> <role type='rep' startdate='1997-01-07' enddate='1998-12-19' party='Democrat' state='NY' district='9' /> <role type='sen' startdate='1999-01-06' enddate='2004-12-09' party='Democrat' state='NY' class='3' url='http://schumer.senate.gov/' /> <role type='sen' startdate='2005-01-04' enddate='2010-12-22' party='Democrat' state='NY' class='3' url='http://schumer.senate.gov/' /> <role type='sen' startdate='2011-01-05' enddate='2016-12-31' party='Democrat' state='NY' class='3' url='http://schumer.senate.gov/' current='1' /> </person> ... </people>
In the Congress-specific people.xml files, only the role with the "current" attribute is included.
The format of this file is essentially self-explanatory. Here are the details:
- On the <person> elements, the only obligatory fields are "id", "firstname", "lastname", and "name". Other fields are omitted if they are not known. "name" is a good field for you to display.
- Biographical attributes include "gender" ("M" or "F") and "birthday" (YYYY-MM-DD).
- The attributes "bioguideid", "osid", and "pvsid" refer to the ids assigned at bioguide.congress.gov, the Center for Responsive Politics, and VoteSmart. "youtubeid" and "twitterid" give the name of the official YouTube feed of the person; twitterid gives the person’s Twitter screen name. Note that bioguideid will be absent for records for presidents that never served in Congress.
- "title", "state", and "district" attributes on each <person> element are set if the person currently has a role in Congress. They are redundant with the information contained in the <role> elements.
- <role> elements within each <person> element indicate each elected term in Congress or as President the person has served or is serving. The start and end date of the terms are given in the "startdate" and "enddate" attributes in YYYY-MM-DD format. For senator and representative roles, the dates normally refer to the starting day of the Congressional session and the day of adjournment of the Congressional session to which the Member of Congress was elected (i.e. two-year terms for representatives, six-year terms for senators). But Members that are sworn-in late or resign or die will have other dates.
- The "type" attribute on a <role> is "sen" (senator), "rep" (congressman), or "prez" (U.S. president). For senators, the "state" attribute gives their state and a "class" attribute gives their election class (1, 2, or 3). (Senior vs. junior status are not indicated.) For representatives, the "state" attribute gives their state and the "district" attribute gives the congressional district, or 0 for at-large districts and -1 for historical data where the district is not known.
- The "party" attribute on a <role> has the political party of the individual during that term. (When an individual changes parties, it is the most recent party.)
- The "url" attribute on a <role> gives the address of the official homepage of the individual.
- The "current" attribute on a <role> is present and set to 1 if the role is current. Otherwise, the role is archival (the person resigned, died, or the role ended). You can also determine this by looking at the start and end dates, which are in YYYY-MM-DD format.