Skip to main content

gdformat

Parser and builder for the Geometry Dash 2.2 server protocol. It covers the wire objects, the full endpoint response envelopes and typed parsing of every endpoint's form parameters, so a server never handles the raw format itself.

Only the latest game version is supported. Python 3.14, managed with uv, no runtime dependencies.

Layout

Module Contents
gdformat.objects Frozen dataclasses for each wire object (Level, User, Comment, Song, ...) with serialise_* / parse_* functions.
gdformat.responses One serialise_* per endpoint response, producing the exact string to send, plus parse_level_download for reading an official level download.
gdformat.requests One *Request dataclass and parse_* per endpoint, taking the POST form. verify_* helpers check the client integrity values.
gdformat.crypto XOR keys and salts, gjp2, chk generation, response hashes, level passwords, leaderboard seeds.
gdformat.encoding Base64, XOR, level string compression, URL quoting, relative age strings.
gdformat.enums Every discriminant the protocol uses.
gdformat.codes Documented numeric response codes.

Usage

from gdformat import is_error, objects, requests, responses


def download_level(form: dict[str, str]) -> str:
    request = requests.parse_download_level(form)
    if is_error(request):
        return "-1"

    level = objects.Level(...)  # Built from your storage.
    return responses.serialise_level_download(level, songs)

Failures are values: every parser returns T | ParseError, narrowed with is_error / is_success. Nothing in the library raises.

Metadata

Release files for gdformat 0.2.3

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

Source distribution (sdist)

Source distribution for gdformat 0.2.3
File Size Uploaded Provenance Actions
gdformat-0.2.3.tar.gz 30.3 kB Without provenance Details for gdformat-0.2.3.tar.gz

Built distribution (wheel)

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

Total release size: 77.7 kB

Release files / gdformat-0.2.3.tar.gz

Download URL gdformat-0.2.3.tar.gz
Size 30.3 kB
Tags Source
SHA-256 checksum
How to use checksums
1c7d3d099926574b6cfbb00bf156fd5471716595ef3b9f27caaef6735d44c004
BLAKE2b-256 checksum
How to use checksums
38626209c56074143150c0d3c003cc160c230540479b58537e75feef06e42e51
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.12.22 {"installer":{"name":"uv","version":"0.12.22","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Release files / gdformat-0.2.3-py3-none-any.whl

Download URL gdformat-0.2.3-py3-none-any.whl
Size 47.4 kB
Tags Python 3
SHA-256 checksum
How to use checksums
37bee5dcd306fd94469dcc59a0cb418fbb69641c0e2efc4480715b3aae8dadb9
BLAKE2b-256 checksum
How to use checksums
784619a5843e1c7f2c40a016dec6c1fe262902649457d897ba3d1c3304ee342c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.12.22 {"installer":{"name":"uv","version":"0.12.22","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Security for gdformat 0.2.3

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