usgpo / link-service

The link service is used to create links to content and metadata on govinfo

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

link-service

The Link Service is used to create links to content and metadata on GovInfo. This allows for both predictable link creation as well as the ability to point to the latest version of a given resource - like the latest version of a Congressional Bill or latest edition of a CFR section.

For more information, see the interactive documentation available at https://www.govinfo.gov/link-docs/ . This link service has been built and documented using the Open API Spec and Swagger UI

Code of Federal Regulations (CFR)

CFR Title and Part Query

Returns a specific CFR Title and part, including the ability to specify a particular section

Parameters

  • collection: Required - Value is cfr.

  • titlenum: Required - title number. Sample value is 3.

  • partnum: Required - part number. Sample value is 100.

  • sectionnum: Optional - section number. Sample value is 1. If section number is not provided the entire part will be returned.

  • year: Optional - four digit year OR mostrecent. If year is not provided the most recent version of the CFR section or part is returned. Default is most recent. Sample value is 2011.

  • link-type: Optional - format of the returned document. Default is pdf. Other values are xml, mods, premis, details, context, and related.

Examples

Compilation of Presidential Documents (CPD)

DCPD Type or Number Query

Return a specific DCPD document by Supplementary Materials Type or DCPD number

Parameters

  • collection: Required - Value is cpd.

  • year: Required - four digit year. The first Daily Compilation of Presidential Documents (dcpd) document was published on 1/20/2009. Sample value is 2010.

  • dcpnumber: Optional - five digit identifier on a dcpd document. It does not include the four digit year. Document are numbered sequentially within each year. Leading zeros can be supplied but are not required. Sample value is 00123. Either dcpdnumber or dcpdtype is required. If a document contains both a dcpdnumber and a dcpdtype, we recommend providing dcpdtype instead of dcpdnumber. If both are provided, precedence is given to dcpdnumber.

  • dcpdtype: Optional - type of dcpd document. Values are digest, nominations, checklist, actsapproved. Either dcpdnumber or dcpdtype is required. If a document contains both a dcpdnumber and a dcpdtype, we recommend providing dcpdtype instead of dcpdnumber. If both are provided, precedence is given to dcpdnumber.

  • link-type: Optional - format of the returned document. Default is pdf. Other values are html, mods, premis, details, related.

Examples

DCPD doctype or number Query

Return DCPD documents by a specific presidential document type and number.

Parameters

  • collection: Required - Value is cpd.

  • doctype: Required - Values are executiveorder, proclamation, determination.

  • docnum: Required - document number. Sample value is 13514.

  • link-type: Optional - format of the returned document. Default is pdf. Other values are html, mods, premis, details.

Examples

Congressional Bills (BILLS)

BILLS Query

bill number, bill type, congress, bill version OR most recent

Parameters

  • collection: Required - Value is bills.

  • billtype: Required - Values are hr, s, hjres, sjres, hconres, sconres, hres, sres.

  • billversion: Optional - If bill version is not provided, the most recent version of a bill is returned. Values are as, cps, fph, lth, ppv, rds, rhv, rhuc, ash, eah, fps, lts, pap, rev, rih, sc, eas, hdh, nat, pwah, reah, ris, ath, eh, hds, oph, rah, res, rsv, ats, eph, ihv, ops, ras, renr, rth, cdh, enr, iph, pav, rch, rfh, rts, cds, esv, ips, pch, rcs, rfs, s_p, cph, fah, isv, pcs, rdh, rft, sas, mostrecent.

  • billnum: Required - bill number. Sample value is 1027.

  • congress: Required - Congress number. Sample value is 112.

  • link-type: Optional - format of the returned document. Default is pdf. Other values are xml, html, mods, premis, details.

Examples

Congressional Calendars (CCAL)

CCAL section Query

chamber, section, publish date OR most recent

Parameters

  • collection: Required - Value is ccal.

  • chamber: Required - chamber of Congress. Values are house, senate.

  • section: Required - name of the calendar section. Recommend encoding special characters and spaces (%20). Common sample values include Unanimous Consent Agreements, Cover and Special Orders, Subjects on the Table, Union Calendar, Bills in Conference, Special Legislative Days.

  • publishdate: Optional - If date is not provided, the most recent version of the calendar is returned. Values are date formated as yyyy-mm-dd or mostrecent. Default is most recent.

  • link-type: Optional - format of the returned document. Default is pdf. Other values are html, mods, premis, details, context.

Examples

CCAL Latest Full Calendar Query

Returns the latest full House or Senate Calendar

Parameters

  • collection: Required - Value is ccal.

  • chamber: Required - chamber of Congress. Values are house, senate.

  • publishdate: Optional - If date is not provided, the most recent version of the calendar is returned. Values are date formated as yyyy-mm-dd or mostrecent. Default is most recent.

  • link-type: Optional - format of the returned document. Default is pdf. Other values are html, mods, premis, details, context, zip.

Examples

Congressional Committee Prints (CPRT)

CPRT by Jacket Number Query

Returns a specific committee print by Congress and GPO jacket number

Parameters

  • collection: Required - Value is cprt.

  • congress: Required - Congress number. Sample value is 112.

  • jacketid: - GPO jacket number. The jacket number is typically listed on the first page in the lower left corner. Jacket number is unique within a Congress. Sample value is 74-558.

  • link-type: Optional - format of the returned document. Default is pdf. Other values are html, mods, premis, details.

Examples

CPRT by Senate Print Number Query

Returns a specific Senate committee print by Congress and unique Senate Print number

Parameters

  • collection: Required - Value is cprt.

  • congress: Required - Congress number. Sample value is 112.

  • chamber: Required - chamber of Congress. Value is senate.

  • printnum: Required - Senate print number. Senate prints are numbered consecutively across committees within a Congress. Sample value is 4.

  • link-type: Optional - format of the returned document. Default is pdf. Other values are html, mods, premis, details.

Example

CPRT by House Committee and Serial Number Query

Returns a specific committee print by Congress, House Committee, and serial number

Parameters

  • collection: Required - Value is cprt.

  • congress: Required - Congress number. Sample value is 109.

  • chamber: Required - chamber of Congress. Value is house.

  • printnum: Required - House committee print number. House prints are not numbered consecutively across committees within a Congress. For example, 109-2 could exist for both the Ways and Means Committee and the Rules and Administration Committee within the 109th Congress. Sample value is 2.

  • committee: Required - name of the House committee. Recommend encoding special characters and spaces (%20). Sample value is Ways and Means.

  • link-type: Optional - format of the returned document. Default is pdf. Other values are html, mods, premis, details.

Example

Congressional Documents (CDOC)

CDOC by Jacket Number Query

Return a specific Congressional Document by Congress and GPO Jacket number.

Parameters

  • collection: Required - Value is cdoc.

  • congress: Required - Congress number. Sample value is 112.

  • jacketid: - GPO jacket number. The jacket number is typically listed on the first page in the lower left corner. Jacket number is unique within a Congress. Sample value is 66-208.

  • link-type: Optional - format of the returned document. Default is pdf. Other values are html, mods, premis, details.

Examples

CDOC by Document Type and Number Query

congress, document type, document number

Parameters

  • collection: Required - Value is cdoc.

  • doctype: Required - congressional document type. Congressional documents can either be house documents, senate documents, or treaty documents. Values are hdoc, sdoc, tdoc.

  • docnum: Required - document number. Congressional documents are numbered consecutively within a Congress for each document type. Sample value is 15. Note:** congressional documents that have been processed through the GPO collection are currently not available through the Link Service.

  • link-type: Optional - format of the returned document. Default is pdf. Other values are html, mods, premis, details.

Examples

Congressional Hearings (CHRG)

CHRG by Jacket Number Query

Return a specific Congressional Hearing by Congress and GPO jacket number.

Parameters

  • collection: Required - Value is chrg.

  • congress: Required - Congress number. Sample value is 105.

  • jacketid: - GPO jacket number. The jacket number is typically listed on the first page in the lower left corner. Jacket number is unique within a Congress. Sample value is 48-707.

  • link-type: Optional - format of the returned document. Default is pdf. Other values are html, mods, premis, details.

Example

CHRG - Senate Hearing Number Query

congress, chamber, senate hearing number

Parameters

  • collection: Required - Value is chrg.

  • congress: Required - Congress number. Sample value is 122.

  • chamber: Required - chamber of Congress. Value is senate.

  • hearingnumber: Required - Senate hearing number. Senate hearings are numbered consecutively across committees within a Congress. Sample value is 122.

  • link-type: Optional - format of the returned document. Default is pdf. Other values are html, mods, premis, details.

Example

CHRG - House Serial Number Query

Return a specific House Hearing by Congress, committee and serial number

Parameters

  • collection: Required - Value is chrg.

  • chamber: Required - chamber of Congress. Value is house.

  • committee: Required - name of the House committee. Recommend encoding special characters and spaces (%20). Sample value is energy.

  • serialnumber: Required - house committee serial number. House hearings are not numbered consecutively across committees within a Congress. For example, 109-138 could exist for both the Energy Committee and the Rules and Administration Committee within the 109th Congress. Sample value is 138.

  • link-type: Optional - format of the returned document. Default is pdf. Other values are html, mods, premis, details.

Example

Congressional Record - Daily (CREC)

CREC Page Number Query

Return a specific Congressional Record document by volume, page prefix, and page number.

Parameters

  • collection: Required - Value is crec.

  • volume: Required - volume number. Sample value is 158.

  • pageprefix: Required - page prefix that corresponds to the Congressional Record section. Sections are Daily Digest, House, Senate, and Extensions of Remarks. Values are d, h, s, e.

  • page: Required - page number. Congressional record pages are numbered consecutively in a section within a volume. Note: when multiple granules are contained on a page, content and metadata for the last granule on the page will be returned. Recommend selecting PDF link-type to return content for all granules on a page. Sample value is 234.

  • link-type: Optional - format of the returned document. Default is pdf. Other values are html, mods, premis, details.

Examples

CREC document type Query

Return the latest Congressional Record Document by type. More information below. Note that in instances where there are multiple documents of a type for a given date, the desired document may not be returned. In this case, it would be preferable to use the page reference query above.

Parameters

  • collection: Required - Value is crec.

  • type: Optional - type of Congressional Record document within each section. Please see tables below for values.

  • publishdate: Optional - If date is not provided, the most recent version of the Congressional Record document is returned. Values are date formated as yyyy-mm-dd or mostrecent. Default is most recent.

  • link-type: Optional - format of the returned document. Default is pdf. Other values are html, mods, premis, details.

Examples

Type Values

The information below lists the allowable values for the type field. Values are not case sensitive. Note: some values may produce multiple results. For example, both the House section and Senate section could contain a tributeto granule on the same day. In this case, the desired document may not be returned.

Daily Digest Type Values
Type Value User Readable Value
DDALLOTHER All Other
DDSCHAMBER Senate Chamber Action
DDSCMEETINGS Senate Committee Meetings
DDHCHAMBER House Chamber Action
DDHCMEETINGS House Committee Meetings
DDNEWPUBLAWS New Public Laws
DDAHEAD Congressional Program Ahead
DDCOMMITTEEMEETINGS Committee Meetings Upcoming
DDRESUMEONGOING Resume of Congressional Activity - Ongoing
DDRESUMEFINAL Resume of Congressional Activity - Final
DDENDMATTER End Matter
House, Senate, and Extensions of Remarks Type Values
Type Value User Readable Value
ALLOTHER All Other Legislative Business
PRAYER Prayer
PLEDGE Pledge of Allegiance
ADJOURNMENT Adjournment
EXECUTIVECOMM Executive and other Communications
JOINTMEETINGS Joint Meetings of the House and Senate
ENROLLEDSIGNED Enrolled Legislation Signed
ENROLLEDPRESENTED Enrolled Legislation Presented
MSGPRESIDENT Messages From the President
TECHNICALCORRECTIONS Making Technical Corrections
PERSONALEXPLAIN Personal Explanation
RECOGNIZING Recognitions
HONORING Honoring
COMMEMORATING Commemorations
CELEBRATING Celebrations
COMMENDING Commending
PASSINGOF On the passing of
TRIBUTETO Tribute
CONGRATULATIONS Congratulations
RETIREMENT Retirement Of
DESIGNATING Designating
INMEMORYOF In Memory Of
House Type Values
Type Value User Readable Value
HDESIGNATION Designation of The Speaker Pro Tempore
HJOURNAL The Journal
HMESSAGE Message From the Senate
HCLERK Communication From The Clerk of the House
HANNOUNCEMENT Announcement by the Speaker
HMORNINGDEBATE Morning Hour Debates
HREPORTON Report On
HCONFREPORTON Conference Report On
HSENATEBILLREFERRED Senate Bill Referred
HLEGPROGRAM Legislative Program
HTIMELIMIT Time Limitation Of Referred Bill
HEXPENDITURE Expenditure Reports Concerning Official Foreign Travel
HCORRECTIONS Honoring
COMMEMORATING Commemorations
CELEBRATING Celebrations
COMMENDING Commending
PASSINGOF On the passing of
TRIBUTETO Tribute
CONGRATULATIONS Congratulations
RETIREMENT Retirement Of
DESIGNATING Designating
INMEMORYOF In Memory Of
HPETITIONS Petitions
HAMENDMENTS Amendments
HEARMARKS Congressional Earmarks, Limited Tax Benefits, Or Limited Tariff Benefits
Senate Type Values
Type Value User Readable Value
SENATEALLOTHER All Other Legislative Business
SAPPOINTMENT Appointment of The Acting President Pro Tempore
SORDER Order of Procedure
SSCHEDULE Schedule
SSSCHEDULE Senate Schedule
SMEASUREDCAL Measures Placed on the Calendar
SMBUSINESS Morning Business
SCONBUSINESS Conclusion of Morning Business
SRECESS Recess
SADDITIONAL Additional Statements
SMSGHOUSE Message From the House
SCOMMREPORT Reports of Committees
SEXECREPORT Executive Reports of Committees
SPETANDMEM Petitions and Memorials
SREFERRED Measures Referred
SREADFIRST Measures Read the First Time
SDISCHARGED Measures Discharged
SDICHARGEREF Discharge and Referral
SMSGEXEC Executive Messages Referred
SINTROBILLS Introduction of Bills and Joint Resolutions
SSUBMISSION Submission of Concurrent and Senate Resolutions
SCOSPONSORS Additional Cosponsors
SSTATEMENTS Statements on Introduced Bills and Joint Resolutions
SSUBMITTED Submitted Resolutions
SRESOLUTION Senate Resolution
SAMENDMENTSSUB Amendments Submitted and Proposed
SAMENDMENTTEXT Text of Amendments
SNOTICE Notice of Hearings
SAUTHORITY Authority for Committees to Meet
SPRIVILEGES Privileges of the Floor
SPROGRAM Program
SCALENDAR The Calendar
SCONSENTAGREE Unanimous Consent Agreement
SCONSENTREQUEST Unanimous Consent Request
SORDERFOR Order For
SEXECSESSION Executive Session
SEXECCAL Executive Calendar
SLEGISLATIVE Legislative Session
SNOMINATIONS Nominations
SWITHDRAWAL Withdrawals
SCONFIRMATIONS Confirmation
SCLOTURE Cloture Motion
Extensions of Remarks Type Values
Type Value User Readable Value
ESENATECOMMITTEE Senate Committee Meetings
EINTRODUCTIONOF Introducing Legislation

CREC Section Query

Return a specific Congressional Record section

Parameters

  • collection: Required - Value is crec.

  • section: Required - Congressional Record section. Values are dailydigest, senate, house, extensions.

  • publishdate: Optional - If date is not provided, the most recent version of the Congressional Record section is returned. Values are date formated as yyyy-mm-dd or mostrecent. Default is most recent.

  • link-type: Optional - format of the returned document. Default is pdf. Other values are mods, premis, details. Note: mods, premis, and details are returned at the package level because they are not available for section level granules.

Examples

Senate Amendments Query

Return the text of a specific Senate Amendment within the Congressional Record

Parameters

  • collection: Required - Value is crec.

  • congress: Required - Congress number. Sample value is 117.

  • amendmentNumber: Required - Senate amendment number. Sample value is 5010.

  • link-type: Optional - format of the returned document. Default is html. Other values are mods, premis, details, context, related.

Examples

Congressional Reports (CRPT)

Report Type and Number Query

congress, report type, report number

Parameters

  • collection: Required - Value is crpt.

  • congress: Required - Congress number. Sample value is 112.

  • reportnum: Required - report number. Congressional reports are numbered consecutively within a Congress for each report type. Sample value is 154.

  • doctype: Required - congressional report type. Congressional reports can either be house reports, senate reports, or senate executive reports. Values are hrpt, srpt, erpt.

  • link-type: Optional - format of the returned document. Default is pdf. Other values are html, mods, premis, details, context, related.

Examples

Associated Bill Query

Returns a specific Congressional report based on an associated Congressional bill

Parameters

  • collection: Required - Value is crpt.

  • congress: Required - Congress number. Sample value is 112.

  • associatedbillnum: Required - Congressional reports often accompany a specific bill. Note: some associated bill numbers may produce multiple results. This will occur when two different reports are issued to accompany a single bill within a single Congress. In this case, the desired report may not be returned. Sample value is h.r.2297.

  • link-type: Optional - format of the returned document. Default is pdf. Other values are html, mods, premis, details, context, related.

Examples

Federal Register (FR)

FR Volume and Page Number Query

Return a specific portion of the Federal Register by Volume and page citation

Parameters

  • collection: Required - Value is fr.

  • volume: Required - volume number. Sample value is 76.

  • page: Required - page number. Federal Register pages are numbered consecutively within a volume. Note: when multiple granules are contained on a page, content and metadata for the last granule on the page will be returned. Recommend selecting PDF link-type to return content for all granules on a page. Sample value is 575.

  • link-type: Optional - format of the returned document. Default is pdf. Other values are html, mods, premis, details, context, related.

Examples

Federal Register document number Query

Returns specific FR content by FR document number

Parameters

  • publishdate: Optional If date is not provided, the most recent version of the Federal Register is returned. Values are date formated as yyyy-mm-dd or mostrecent. Default is most recent.

  • link-type: Optional - format of the returned document. Default is pdf. Other values are toc, mods, premis, details, context, zip.

Examples

Latest Federal Register Query

Returns the latest edition of the Federal Register

Parameters

  • collection: Required - Value is fr.

  • frdocnum: Required - The is the FR doc number that is listed at the end of each Federal Register document. Sample value is 2010-32535.

  • link-type: Optional - format of the returned document. Default is pdf. Other values are html, mods, premis, details.

Examples

Public and Private Laws (PLAW)

Congress, Law Type and Number Query

Returns a public or private law based on Congress, law type, and number

Parameters

  • collection: Required - Value is plaw.

  • congress: Required - Congress number. Sample value is 111.

  • lawtype: Required - law type. Laws can either be public laws or private laws. Values are public, private.

  • lawnum: Required - law number. Laws are numbered consecutively within each law type within a Congress. Sample value is 78.

  • link-type: Optional - format of the returned document. Default is pdf. Other values are html, mods, premis, details, related.

Example

Associated Bill Query

Return a public or private law (if it exists) based on associated bill numbers

Parameters

  • collection: Required - Value is plaw.

  • congress: Required - Congress number. Sample value is 111.

  • associatedbillnum: Required - Public and private laws are associated with a primary bill number. The primary bill number is listed at the beginning of the law. Sample value is S. 3397.

  • link-type: Optional - format of the returned document. Default is pdf. Other values are html, mods, premis, details.

Example

Statutes at Large citation Query

Returns public or private law based on Statutes at Large citation

Parameters

  • collection: Required - Value is plaw.

  • statutecitation: Required - A Statutes at Large citation is listed at the top of each page of a law. Use a + (plus sign) in place of spaces in the citation. Sample value is 124+stat+2859.

  • link-type: Optional - format of the returned document. Default is pdf. Other values are html, mods, premis, details.

Example

Statutes at Large (STATUTE)

Statute by Congress and Law Query

Returns a public or private law in the U.S. Statutes at Large based on Congress, law type, and number

Parameters

  • collection: Required - Value is statute.

  • congress: Required - Congress number. Sample value is 108.

  • lawtype: Required - law type. Laws can either be public laws or private laws. Values are public, private.

  • lawnum: Required - law number. Laws are numbered consecutively within each law type within a Congress. Sample value is 841.

  • link-type: Optional - format of the returned document. Default is pdf. Other values are html, mods, premis, details.

Example

Statute Citation Query

Returns a Statutes at Large document based on Statute Citation

Parameters

  • collection: Required - Value is statute.

  • volume: Required - volume number. Sample value is 118.

  • page: Required - page number. Statutes at Large pages are numbered consecutively within a volume. Note: when multiple granules are contained on a page, content and metadata for the last granule on the page will be returned. Recommend selecting PDF link-type to return content for all granules on a page. Sample value is 3910.

  • link-type: Optional - format of the returned document. Default is pdf. Other values are html, mods, premis, details, context.

Example

United States Code (USCODE)

Query

title number, type, section, year OR most recent

Parameters

  • collection: Required - Value is uscode.

  • title: Required - title number. Sample value is 5.

  • section: Required - section number. Sample value is 104.

  • type: Optional - U.S. Code section type. Values are usc, uscappendix. Default value is usc. year Optional - four digit year OR mostrecent. If year is not provided the most recent version of the U.S. Code section is returned. Default is most recent. Sample value is 2010.

  • link-type: Optional - format of the returned document. Default is pdf. Other values are html, mods, premis, details.

Examples

Common Errors

Multiple Results Found

This error occurs when more than one document matches parameters for a given request. Additional parameters must be specified in order to return a single document.

No Results Found

This error occurs if a match document was not found for the given parameters. Please check the API documentation to make sure values provided are correct.

Validation Failed

This error occurs when request parameters fail validation. Possible causes include the following:

  • No queries found for COLLECTION CODE. This error occurs if the value for collection is incorrect or has not been enabled yet. Please check the documentation for available collections and collection codes.

  • Request parameter XXXX is not found but is required. This error occurs if a required parameter is missing in the URL. Please check the documentation for required parameters for each collection.

  • The value provided for XXXX is invalid. One of the following [XXXX, YYYY] is expected. This error occurs if a value provided for a parameter is not among the listed choices. Please check the documentation for parameter values.

Content File Not Found

This error can occur for an invalid or unavailable link-type value. Allowable values are pdf, html, mods, premis and details. This error can also occur if a requested link-type is not available for a specific document.

System Error

Please report any errors encountered while using the Link Service on https://ask.gpo.gov/s/contactsupport using the govinfo.gov question category. Please include the link you tried generating and what issue you are seeing.

About

The link service is used to create links to content and metadata on govinfo

License:Other