New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

sam-scraper

Package Overview
Dependencies
Maintainers
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

sam-scraper

The `sam-scraper` is designed for seamless interaction with the sam.gov API,

  • 0.1.2
  • PyPI
  • Socket score

Maintainers
1

Sam Scraper

Introduction

The sam-scraper Python package is designed for seamless interaction with the sam.gov API, enabling efficient search operations, detailed retrieval of records, and resource downloads.

Features

  • Advanced Search Capabilities: Execute detailed searches using criteria such as relevance, status, and result limits.
  • Detailed Information Retrieval: Access in-depth details for records, including exclusion details and resource information.
  • Resource Download: Directly download resource files using specific record IDs.
  • Ease of Use: Offers intuitive methods and clear documentation for an optimal user experience.

Installation

To install sam-scraper, run the following command in your terminal:

pip install sam-scraper

Usage

Below is a step-by-step guide on how to utilize sam-scraper in your projects.

Importing the Module

First, import the Sam class from the sam_scraper package:

from sam import Sam

Creating an Instance

Instantiate the Sam class:

sam = Sam.Scraper()

To perform a search using the sam.gov API, use the search method. You can specify parameters such as sort, status, and limit:

results = sam.search(sort="relevance", status="active", limit="10")
print(results)

Getting Detailed Information

Retrieve detailed information of a record by providing an ID. This ID can be obtained from the search results:

details = sam.get_details(id="962c49a01a204a25bfcad1b4c894b4ed")
print(details)

Downloading a Resource

Download a resource file associated with a specific ID by using the download_resource method:

sam.download_resource(ID="resource_id", name_file="desired_filename.pdf")

License

This project is licensed under the MIT License - see the `LICENSE.md` file for details.

FAQs


Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc