Skip to main content

QSPyLib

Python Package Build Action Status Documentation Status PyPI - Python Version PyPI - Version PyPI - Wheel PyPI - License

QSPyLib is a bundle of API wrappers for various amateur radio-related sites, including QRZ, LOTW, eQSL, and ClubLog.

QSPyLib is in active development; that said, major version numbers should maintain API stability. If you need absolute stability of the API, fix your version against the major.

Issues and pull requests are welcome, and should be made on the GitHub repository.

How do I install it?

The latest stable* version of QSPyLib is available on PyPI, and can be installed by just running

py -m pip install qspylib

This release should match what is on the GitHub repository under a corresponding tagged release.

To build the most recent source code (which isn’t necessarily stable – see the build test status), you can download the source code from GitHub, navigate to the directory, and run:

py -m build

This will generate a .whl and tar.gz, which you can then install locally.

What works right now?

As of v1.0.0:

  • The LotW module is, in theory, finished -- you can download QSOs in bulk or by criteria, check DXCC credit, get a list of users and their date of last upload, and upload a log.
  • The eQSL module has most of the functionality of eQSL's API, but is a bit unpolished -- at present, you can fetch inboxes and outboxes, get AG lists, get member lists, get last upload data for users, verify an eQSL, and retrieve the eQSL card graphic for a QSL.
  • The QRZ module is done; for logs, we support fetching logbooks, checking logbook statuses, and inserting and deleting records. For the XML API, we support looking up a callsign's data and looking up a DXCC's data.
  • The ClubLog module only supports grabbing logbooks from ClubLog at the moment.

Everything has been tested to work when done "correctly" and simply; no doubt some edge case will pop up, or some failure state won't throw a good error. Please open an issue for any problems you come across, no matter how minor, even if it's just an exception that isn't descriptive.

How do I use it?

Documentation of all functions and classes, including examples, is available at the ReadTheDocs listing for this project:

http://qspylib.readthedocs.io/

A quick example of pulling a Logbook from LOTW:

from qspylib import lotw
LOTWAccount = lotw.LOTWClient("callsign", "password")
logbook = LOTWClient.fetch_logbook()

This will give you a Logbook object, which contains a list of QSO objects and a parsed, usable adif_io log. The adif_io log property contains all the ADIF info that LOTW outputs (and likewise for other logging sites). The built-in log property of a Logbook object contains only some limited information, like callsign, band, mode, date, time, and QSL status from the originating site (which is a little handy as a single-reference for if a QSO is a QSL, since different sites use different, extra ADIF fields to express being QSL'd on their platform.)

Other functions of APIs are generally available, like checking if an eQSL is verified:

from qspylib import eqsl
confirmed, raw_result = eqsl.eQSLClient.verify_eqsl('N5UP', 'TEST', '160m', 'SSB', '01/01/2000')

This will return a tuple; here, confirmed will be False, since this QSO is not verified on eQSL, and raw_result will contain any extra information eQSL provides, for instance, if it's Authenticity Guaranteed. Note that verify_eqsl is a static method of the eQSLClient class, and can be called either from an eQSLClient object, or directly from the class.

Modules, functions, and classes are documented in-code via docstrings, and you can learn more by reading those docstrings; you can also read the Read the Docs listings for a visually pleasing guide on what the docstrings say.

Metadata

Release files for qspylib 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 qspylib 1.0.0
File Size Uploaded
qspylib-1.0.0.tar.gz 35.6 kB Details

Built distribution (wheel)

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

Total release size: 62.2 kB

Release files / qspylib-1.0.0.tar.gz

Download URL qspylib-1.0.0.tar.gz
Size 35.6 kB
Tags Source
SHA-256 checksum
How to use checksums
f251fb58301bd107fe1b4d8644c1fc40f281cc7aaf5224bfd7d4f38edbbe5055
BLAKE2b-256 checksum
How to use checksums
772fbad2a2e33571b29d51fc33f8c24bbdb70f629db09851ecaf7e62235d4813
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.1.1 CPython/3.12.6

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

Download URL qspylib-1.0.0-py3-none-any.whl
Size 26.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
48ca1a028608f345cac667649caeaf216f221f890237d04095aab8f10069ddc3
BLAKE2b-256 checksum
How to use checksums
897b8623e95255559851bb813f4031684b8f930017f83231c69a409150ff7207
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.1.1 CPython/3.12.6

Release history Release notifications | RSS feed

This release

1.0.0 This release

2 release files

0.0.1

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