Skip to main content

Python Asyncio Client for IP Fabric

This package contains a Python 3.8+ asyncio client for use wih the IP Fabric product.

Downloads Supported Python Version Contributors License

Installating aio-ipfabric and supported versions

aio-ipfabric is available on PyPI:

pip install aio-ipfabric

Direct installation

pip install git+https://github.com/jeremyschulman/aio-ipfabric@master#egg=aio-ipfabric

Requests officially supports Python 3.8+.

Quick Start

from aioipfabric import IPFabricClient

async def demo_1_devices_list():
    """
    Example code that uses IPFabricClient without contextmanager
    """

    # create a client using environment variables (see next section)
    ipf = IPFabricClient()

    # alternatively create instance with parameters
    # ipf = IPFabricClient(base_url='https://myipfserver.com', username='admin', password='admin12345')
    # ipf = IPFabricClient(base_url='https://myipfserver.com', token='TOKENFROMIPF')
    
    # login to IP Fabric system
    await ipf.login()

    # fetch the complete device inventory
    device_list = await ipf.fetch_devices()
    
    # close asyncio connection, otherwise you will see a warning.
    await ipf.logout()
    
    return device_list

async def demo_2_devices_list():
    """
    Example code that uses IPFabricClient as contextmanager
    """

    # create a client using environment variables (see next section)
    async with IPFabricClient() as ipf:
        return await ipf.fetch_devices()    

Environment Variables

The following environment variable can be used so that you do no need to provide them in your program:

  • IPF_ADDR - IP Fabric server URL, for example "https://my-ipfabric-server.com/"
  • IPF_USERNAME - Login username
  • IPF_PASSWORD - Login password
  • IPF_TOKEN - A persistent API token

You can use either the login credentials or the token to login.

If you prefer not to use environment variables, the call to IPFabricClient() accepts parameters; refer to the help(IPFabricClient) for details.

Documentation

See the docs directory.

Metadata

Release files for aio-ipfabric 1.0.0

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

Source distribution (sdist)

Source distribution for aio-ipfabric 1.0.0
File Size Uploaded Provenance
aio_ipfabric-1.0.0.tar.gz 20.7 kB Without provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for aio-ipfabric 1.0.0
File Interpreter ABI Platform
aio_ipfabric-1.0.0-py3-none-any.whl Python 3 none any Details

Total release size: 49.7 kB

Release files / aio_ipfabric-1.0.0.tar.gz

Download URL aio_ipfabric-1.0.0.tar.gz
Size 20.7 kB
Tags Source
SHA-256 checksum
How to use checksums
11c9f92bea495f061bc03ea60fdb58c348f3235181d1437e1920e3234a54c580
BLAKE2b-256 checksum
How to use checksums
9b7439a66753e3c7f6fb9764ba3c432b47592bd02bbdeabed71c3be266643563
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.10.6

Release files / aio_ipfabric-1.0.0-py3-none-any.whl

Download URL aio_ipfabric-1.0.0-py3-none-any.whl
Size 29.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
b18c6b00673cde1611ed865536aafc704de7aab92159ada0e73b4ca2f5fd2d11
BLAKE2b-256 checksum
How to use checksums
f95a4c1ad8d2d142daf9a6d3e1ab499dcb77783ac73a57daea79a983556d2538
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.10.6

Security for aio-ipfabric 1.0.0

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.

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