harrecon
Turn a HAR capture into a private API's inventory, response schemas and a typed Python client — offline, stdlib only.
$ harrecon inventory capture.har
captured 5 entries, 2 JSON endpoints
auth mechanisms:
authorization: Bearer: [redacted] (32 chars)
GET /v1/health [api.example.com] 200
GET /v1/lots/{id} [api.example.com] 200/200
$ harrecon schema capture.har "GET /v1/lots/{id}"
object
id: int
title: string
price: number
$ harrecon diff worked.har broken.har
+ GET /v1/search [api.example.com]
~ GET /v1/lots/{id} [api.example.com] schema changed:
$.currency: added (string)
$ harrecon gen capture.har "GET /v1/lots/{id}" --out client.py
Commands
harrecon inventory <har> [--host H] [--json] # endpoints + auth mechanisms (redacted)
harrecon schema <har> "<METHOD> /path" [--json] # merged schema across samples, optional-fields aware
harrecon diff <har_a> <har_b> [--json] [--fail-on-change] # endpoints and field-level schema changes
harrecon gen <har> "<METHOD> /path" [--out f.py] # typed dataclass client skeleton (urllib, review before use)
Numeric path segments collapse to {id} so repeated calls count as one endpoint. Static assets, HTML and tracking noise are excluded. Auth samples are redacted in all output. Python 3.11+, stdlib only.
Field-level diffs (0.2.0)
Nested fields use paths such as $.items[].price. Keys containing dots, quotes or spaces use bracket notation, e.g. $["unit.price"]. Changes report added/removed fields, changed types and optionality. Renames are not inferred.
diff --json retains added, removed, and full before/after schemas. Changed endpoints now also include host and changes: records containing path, kind (field_added, field_removed, type_changed, optional_changed), before, and after. Field additions/removals carry schema objects and null for the absent side; type changes carry strings; optionality changes carry booleans. added_details and removed_details provide endpoint/host objects without changing the original string arrays.
--fail-on-change returns 1 on any observed endpoint/schema difference, 0 on no difference, and 2 on input/usage errors. Default behavior remains report-only (exit 0). Compare equivalent flows: capture differences are not proof of an API breaking change. Values, HTTP status changes and authentication changes are outside this schema diff.
Inventory auth values now show only [redacted] and their length, never credential prefixes. The input HAR and generated client are not sanitized by this output masking.
Install: pip install harrecon — or from this repo:
pip install "git+https://github.com/juzorei/harrecon#subdirectory=tools/harrecon"
The companion agent skill lives in skills/har-to-api-client: capture hygiene, auth identification, schema caveats (inference from samples ≠ documentation), diff-based scraper debugging, and the ToS boundaries. Skills: npx skills add juzorei/harrecon.
Metadata
Release files for harrecon 0.2.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| harrecon-0.2.0.tar.gz | 13.5 kB | With provenance | Details for harrecon-0.2.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| harrecon-0.2.0-py3-none-any.whl | Python 3 | none | any | Details for harrecon-0.2.0-py3-none-any.whl |
Total release size: 24.7 kB
Release files / harrecon-0.2.0.tar.gz
| Download URL | harrecon-0.2.0.tar.gz |
|---|---|
| Size | 13.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
654a5fef7834ea033721e486adc8541e3af76b25bbc71f198193cc19b52c4e95
|
|
BLAKE2b-256 checksum How to use checksums |
cdb6466c1fd1e59e8aa74a5d0e802c4a5e888d0336d37013f9a0cd8be074c379
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
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 31, 2026.
Transparency logRelease files / harrecon-0.2.0-py3-none-any.whl
| Download URL | harrecon-0.2.0-py3-none-any.whl |
|---|---|
| Size | 11.1 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
6c71ea435e4fb102d1f8330be17328ba989a26c7a9ff66101898c6f3e10868dc
|
|
BLAKE2b-256 checksum How to use checksums |
85779be333523e6355f9b58393166d4bc634e4a22d382441d0af5686c733f8db
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
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 31, 2026.
Transparency logSecurity for harrecon 0.2.0
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.
Full provenance
All 2 files in this release have been uploaded with provenance metadata.
Attestation for harrecon-0.2.0.tar.gz
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 31, 2026.
Transparency logA 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.