Python tools for navigating federal contracting
Project description
procurement-tools
A handy collection of python utilities and tools to navigate federal contracting.
Features
- UEI validation
- Get a URL for an entity from USASpending
- Get recent award data for an entity from USASpending
- Lookup a FAR provision by citation
- Get entity information from the SAM entity
- Access innovations from the Periodic Table of Acquisition Innovations
Usage
For full documentation, head to the docs.
from procurement_tools import FAR, UEI, USASpending, PeriodicTable
print(UEI.is_valid("J7M9HPTGJ1S9"))
# True
print(USASpending.get_usaspending_URL("J7M9HPTGJ1S9"))
# 'https://www.usaspending.gov/recipient/bf1220c1-2373-042a-e8e1-33d5a29639d0-P/latest'
print(FAR.get_section("17.502-2"))
# Returns a pydantic model with the title, section number, url, and text of the section
print(PeriodicTable.get_random_innovation())
# Returns a dict with an innovation from the FAI Periodic Table of Acquisition Innovations
Additionally, we have the beginning of a SAM API client:
from procurement_tools import get_entity
res = get_entity({"ueiSAM":"XRVFU3YRA2U5"})
print(res)
# Returns a pydantic model with the latest SAM data for a given Entity
CLI Usage
fargo
Usage:
$ fargo [OPTIONS] COMMAND [ARGS]...
Options:
--install-completion
: Install completion for the current shell.--show-completion
: Show completion for the current shell, to copy it or customize the installation.--help
: Show this message and exit.
Commands:
far
: Get a provision of the FARsam
: Get a SAM entity's JSON data by providing...usaspending
: Get JSON data about an entity from...
fargo far
Get a provision of the FAR
Usage:
$ fargo far [OPTIONS] SECTION_NUMBER
Arguments:
SECTION_NUMBER
: [required]
Options:
--help
: Show this message and exit.
fargo sam
Get a SAM entity's JSON data by providing a UEI
Usage:
$ fargo sam [OPTIONS] UEI
Arguments:
UEI
: [required]
Options:
--help
: Show this message and exit.
fargo usaspending
Get JSON data about an entity from USASpending by providing a UEI
Usage:
$ fargo usaspending [OPTIONS] UEI
Arguments:
UEI
: [required]
Options:
--awards / --no-awards
: [default: no-awards]--help
: Show this message and exit.
Installation
pip install procurement-tools
License
Apache 2.0
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
procurement_tools-0.1.5.tar.gz
(36.0 kB
view hashes)
Built Distribution
Close
Hashes for procurement_tools-0.1.5-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 7a5412e7b3eb702317f226e76b6afed7f272d375540ebf6a7ef48cabbe535b4c |
|
MD5 | 273ee89de7503d38463d9b98fd5e000d |
|
BLAKE2b-256 | d091209ad4e56a9f391302908f8633fe3de0522ce62e1cd7241295327559bd60 |