Skip to main content

Polyswarm Customer CLI

A CLI tool for interacting with the PolySwarm Customer APIs.

Supports Python 3.10 and greater.

Installation

From PyPI:

pip install polyswarm

From source:

python setup.py install

Usage

Command line client

See the Polyswarm Customer CLI documentation for usage guidance.

Using as a package

The polyswarm-cli package is built on top of the polyswarm-api package, and it includes a set of higher-level methods that facilitates the usage of parallelism when making requests to the api. We provide a class Polyswarm that extends from PolyswarmAPI and includes these methods. For example:

from polyswarm.polyswarm import Polyswarm
api = Polyswarm('my-api-key')
results = api.search_hashes(['e182cdfd5e7463d11f5e7bc49b4377ab25e58b9ff04266df3c34e6261c7b0df9',
                             'd80a1e42791d17cbce8d053afccd1dae7fb9f615676cb81a3a1699e86c344cb8',
                             '275a021bbfb6489e54d471899f7db9d1663fc695ec2fe2a2c4538aabf651fd0f'])
for result in results:
    print(result.id)

Each hash lookup is done in a different thread using a ThreadPoolExecutor and results are yielded as they come in the same order as in the input. All functionality that is available in the command line tool is also available for developers through this class.

Automated Tests

To run automated tests suite (unit and integration):

pip install -r requirements.txt
pytest

To check current coverage by tests:

pytest --cov=polyswarm tests/

Questions? Problems?

File a ticket or email us at info@polyswarm.io.

Metadata

Release files for polyswarm 4.8.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for polyswarm 4.8.1
File Size Uploaded Provenance Actions
polyswarm-4.8.1.tar.gz 44.6 kB Without provenance Details for polyswarm-4.8.1.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for polyswarm 4.8.1
File Interpreter ABI Platform Actions
polyswarm-4.8.1-py3-none-any.whl Python 3 none any Details for polyswarm-4.8.1-py3-none-any.whl

Total release size: 100.6 kB

Release files / polyswarm-4.8.1.tar.gz

Download URL polyswarm-4.8.1.tar.gz
Size 44.6 kB
Tags Source
SHA-256 checksum
How to use checksums
e954cb6d26ae89e107439ec340afff5c8e6de433bfd8ae2b14912e52b17de514
BLAKE2b-256 checksum
How to use checksums
7ed40204006dcd7b4343198aab69a5a477aee6b45b1654f81cde3594beb6223c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.16

Release files / polyswarm-4.8.1-py3-none-any.whl

Download URL polyswarm-4.8.1-py3-none-any.whl
Size 56.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
af5a6748442f694ca7fc51f5dcb4c3d95fd7ad254437de9801311afcf91e9fc8
BLAKE2b-256 checksum
How to use checksums
7fc1ef4930d4d8a3411865810c58a99cba5aa539cdc40125448c96e7e7dbd23a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.16

Security for polyswarm 4.8.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

4.8.1 This release

2 release files No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page