██████╗ ██████╗ ██╗ ██╔═══██╗██╔══██╗██║ ██║ ██║██████╔╝██║ ██║▄▄ ██║██╔═══╝ ██║ ╚██████╔╝██║ ██║ ╚══▀▀═╝ ╚═╝ ╚═╝
QPI Python Client
Python client SDK for the QPI quantum computing platform. Includes both a low-level HTTP client and a Qiskit-compatible backend.
Install
pip install qpi-client
Requires Python ≥ 3.10.
Quick Start
Low-level client
from qpi_client import QPIClient
client = QPIClient("http://localhost:8090", api_token="my-token")
# Submit a job
job_id = client.submit_job([
{"circuit": 'OPENQASM 3.0; include "stdgates.inc"; qubit[2] q; bit[2] c; h q[0]; cx q[0], q[1]; c = measure q;'}
], shots=1024)
print("Job ID:", job_id)
# Wait for completion
job = client.job(job_id)
result = job.result(timeout=120)
print(result.get_counts())
Qiskit integration
from qiskit.circuit import QuantumCircuit
from qpi_client import QPIClient
client = QPIClient("http://localhost:8090", api_token="my-token")
# The name is the QPU's; its qubit count is read from the server.
backend = client.get_backend("mock")
qc = QuantumCircuit(2, 2)
qc.h(0)
qc.cx(0, 1)
qc.measure([0, 1], [0, 1])
job = backend.run(qc, shots=4096)
result = job.result(timeout=120)
print(result.get_counts())
Submit raw QASM with parameters
job = backend.run(
qasm='OPENQASM 3.0; include "stdgates.inc"; qubit[1] q; bit[1] c; rx({{theta}}) q[0]; c = measure q;',
parameter_values=[[0.5], [1.0]],
shots=1024
)
result = job.result()
API Overview
QPIClient
| Method | Description |
|---|---|
QPIClient(base_url, api_token) |
Create a new client |
submit_job(circuits, shots, ...) |
Submit a quantum job |
job(job_id) |
Retrieve a job by ID (returns QPIJob) |
list_jobs() |
List all jobs for the authenticated user |
cancel_job(job_id) |
Request job cancellation |
get_backend(name) |
Get a Qiskit-compatible backend |
QPIBackend (Qiskit)
| Method | Description |
|---|---|
backend.run(circuit, shots) |
Run a QuantumCircuit |
backend.run(qasm, parameter_values, shots) |
Run raw QASM with parameter bindings |
backend.job(job_id) |
Retrieve a past job |
Documentation
License
MIT — see the main repository for details.
Release files for qpi-client 0.4.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| qpi_client-0.4.2.tar.gz | 15.1 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| qpi_client-0.4.2-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 26.5 kB
Release files / qpi_client-0.4.2.tar.gz
| Download URL | qpi_client-0.4.2.tar.gz |
|---|---|
| Size | 15.1 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
4dc950c158c241eb0371be012b4866fd4133caf94e198ba5a75cc1e86038e686
|
|
BLAKE2b-256 checksum How to use checksums |
0c3bdaeee4b03a67df6104c3470383b493049c210a5b026c1d86f33bb7ef3767
|
| 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 Aug 16, 2026.
Transparency logRelease files / qpi_client-0.4.2-py3-none-any.whl
| Download URL | qpi_client-0.4.2-py3-none-any.whl |
|---|---|
| Size | 11.4 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
882d82e3ecf1c02e09d210b62720e19190634cc9bae3549d238f1bb3c72f71e7
|
|
BLAKE2b-256 checksum How to use checksums |
857473440479534e3ba66c4c4306bce537bb91b57dbf504096b59375251d87cb
|
| 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 Aug 16, 2026.
Transparency log