forward-sdk
Python SDK for the Forward Networks REST API.
A Forward Networks Field Integration. Built and maintained by the field team to make integration work easier. It is not a supported Forward Networks product: it carries no SLA, and issues are handled on a best-effort basis rather than through Forward Support.
Status: pre-release. The public API is not yet stable.
pip install forward-sdk
from forward_sdk import ForwardClient
with ForwardClient.from_env() as client:
for network in client.networks.list():
print(network.id, network.name)
rows = client.nqe.query(
"foreach device in network.devices select {name: device.name}",
network_id="101",
)
Authentication is HTTP basic with an API token: its access key is the username and its secret is the password.
What it covers
Every operation in Forward's API. The groups integrations use most -- NQE, snapshots, networks, devices and device tags -- are hand-written with curated names and behaviour such as waiting for a snapshot to finish processing. The rest are generated from the OpenAPI description Forward produces from its own server code.
Both a synchronous and an asynchronous client, with identical surfaces.
Notable
NQE first. Running a query, paging or streaming the results, diffing a query across snapshots, and publishing queries to the library are all first-class. Paging carries guard rails for the ways it can go wrong in production: a result set that ends early, a server that stops advancing, a query far larger than expected.
Typed, but tolerant. Responses are pydantic models. Unknown fields and
unknown enum values are preserved rather than rejected, so a Forward release
that adds either does not break an older SDK. NQE rows stay dict[str, Any],
because a query's columns are defined by the query.
Honest about refusals. A missing licence, a feature absent from your deployment, and a role-based denial all arrive as the same status codes, so the SDK does not pretend to tell them apart. It gives you Forward's own explanation and a documented hint about what gates that operation.
Documentation
https://forwardnetworks.github.io/forward-python-sdk/
- Quickstart
- Configuration
- NQE guide
- Availability and gating
- Migrating from the NetBox plugin or the Nautobot plugin
Requirements
Python 3.10 or newer.
Licence
MIT.
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file forward_sdk-0.1.14.tar.gz.
File metadata
- Download URL: forward_sdk-0.1.14.tar.gz
- Upload date:
- Size: 673.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via:
twine/7.0.0 CPython/3.13.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
dff19f87da7c0ddad32ac72d683ce5593266555c0839b9563cf099702c22ca21
|
|
| MD5 |
4cfe7d8e1fb9469270b9d5d258b3f770
|
|
| BLAKE2b-256 |
f6b8256e8da59d85ce3df175a2779e766b1107464238d5dfc9a2fe3872c6708a
|
Provenance
The following attestation bundles were made for forward_sdk-0.1.14.tar.gz:
Publisher:
release.yml on forwardnetworks/forward-python-sdk
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
forward_sdk-0.1.14.tar.gz -
Subject digest:
dff19f87da7c0ddad32ac72d683ce5593266555c0839b9563cf099702c22ca21 - Sigstore transparency entry: 2809246913
- Sigstore integration time:
-
Permalink:
forwardnetworks/forward-python-sdk@c60b2d3834569003849b5d43d3afad154deaf8cf -
Branch / Tag:
refs/tags/v0.1.14 - Owner: https://github.com/forwardnetworks
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@c60b2d3834569003849b5d43d3afad154deaf8cf -
Trigger Event:
push
-
Statement type:
File details
Details for the file forward_sdk-0.1.14-py3-none-any.whl.
File metadata
- Download URL: forward_sdk-0.1.14-py3-none-any.whl
- Upload date:
- Size: 365.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via:
twine/7.0.0 CPython/3.13.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
45139d3c025480091a86c3ab08506fa155ef5e8cf640e66ada67ea8547dd3b0b
|
|
| MD5 |
22ceec0bbf6c0fc1e86a715b1791a3e5
|
|
| BLAKE2b-256 |
e98181896858698d93ec713d47da0b62723461049f2bf980a93e97f21da7604a
|
Provenance
The following attestation bundles were made for forward_sdk-0.1.14-py3-none-any.whl:
Publisher:
release.yml on forwardnetworks/forward-python-sdk
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
forward_sdk-0.1.14-py3-none-any.whl -
Subject digest:
45139d3c025480091a86c3ab08506fa155ef5e8cf640e66ada67ea8547dd3b0b - Sigstore transparency entry: 2809246937
- Sigstore integration time:
-
Permalink:
forwardnetworks/forward-python-sdk@c60b2d3834569003849b5d43d3afad154deaf8cf -
Branch / Tag:
refs/tags/v0.1.14 - Owner: https://github.com/forwardnetworks
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@c60b2d3834569003849b5d43d3afad154deaf8cf -
Trigger Event:
push
-
Statement type: