| Crates.io | capitol |
| lib.rs | capitol |
| version | 0.2.2 |
| created_at | 2025-01-17 19:04:33.049292+00 |
| updated_at | 2025-03-19 16:07:57.90935+00 |
| description | Parse United States Congress legislative document citations |
| homepage | |
| repository | https://github.com/blackerby/capitol |
| max_upload_size | |
| id | 1520902 |
| size | 21,012 |
Capitol is a Rust library for converting citation strings for United States Congressional documents of the form <Congress><ObjectType><ObjectNumber>, e.g., 118hr815 representing the H.R.815 in the 118th Congress, into Rust types. These Rust types can be printed as Congress.gov URLs.
This project is in its earliest stage of development, but potential future uses include:
As of this writing, only citations for bills and resolutions and commitee reports from either chamber are implemented. For example, calling Citation::parse with the argument 118hr815 returns this Rust struct:
Citation {
congress: Congress(118),
chamber: Chamber::House,
object_type: CongObjectType::HouseBill,
number: 815,
ver: None
}
Calling to_url on that struct return https://www.congress.gov/bill/118th-congress/house-bill/815.
Capitol is available from crates.io.