Skip to main content
Pre-release

This release is a pre-release and may not be stable for production use.

NanoPing API for Python

A typed client for the REST API of a NanoPing node. It covers every method of the API, with helpers for flows that take more than one call, such as joining a hub. It has a blocking and an asyncio client, and needs Python 3.11 or later.

This repository is generated from the NanoPing sources on every release, and its version matches the NanoPing release it was made from. Changes made here are overwritten by the next release.

Install

pip install nanoping-api

Use

from nanoping_api import NanopingClient

client = NanopingClient("http://127.0.0.1:10565")

local = client.hub_client.get_local_node_id()
for update in client.hub_client.stream_connection_state():
    print(update.state)

AsyncNanopingClient has the same methods for asyncio, and its streams are read with async for. Requests and responses are dataclasses, and the fields of a request are passed as keyword arguments. A failed call raises an ApiError, whose code says why, such as Code.NOT_FOUND.

Examples

examples holds the program the HTTP REST guide is made from. It joins a node to a hub and manages pipelines on both. Start the two nodes as the comment in examples/main.py describes, then run

pip install nanoping-api
python examples/main.py --client http://127.0.0.1:10565 --server http://127.0.0.1:10566

The API is documented at https://docs.nanoping.com/api/reference.

Metadata

Release files for nanoping-api 11.1.0.dev0

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

Source distribution (sdist)

Source distribution for nanoping-api 11.1.0.dev0
File Size Uploaded
nanoping_api-11.1.0.dev0.tar.gz 35.3 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for nanoping-api 11.1.0.dev0
File Interpreter ABI Platform
nanoping_api-11.1.0.dev0-py3-none-any.whl Python 3 none any Details

Total release size: 69.4 kB

Release files / nanoping_api-11.1.0.dev0.tar.gz

Download URL nanoping_api-11.1.0.dev0.tar.gz
Size 35.3 kB
Tags Source
SHA-256 checksum
How to use checksums
6a1d5b72ac14056f84c01fbc8494914c9c3e17fe57bc8b091ecc8cc86f74d856
BLAKE2b-256 checksum
How to use checksums
32fa8529b10d6fca4ed7acead8b4b9603303f8424191555b1c82c609f03a1971
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 1, 2026.

Transparency log

Release files / nanoping_api-11.1.0.dev0-py3-none-any.whl

Download URL nanoping_api-11.1.0.dev0-py3-none-any.whl
Size 34.2 kB
Tags Python 3
SHA-256 checksum
How to use checksums
1eac434d126c7225f9f223e510f9bac5c7b6468fde82a3dd00589da4a16f34c4
BLAKE2b-256 checksum
How to use checksums
9f2d63665fd455af5324225a851b1d9ae9b37481885b98bd813e0639c2d998a1
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 1, 2026.

Transparency log

Release history Release notifications | RSS feed

This release

11.1.0.dev0 This release

2 release files

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