CLI helper: sign any event into your Etch audit chain from the command line.
Project description
etch-record
Small CLI helper. Signs any event into your Etch audit chain from the command line.
Built for the marketing-agent workflow: every research call, draft generation, review decision, and outreach send emits a signed event. Also usable standalone for any local activity you want notarized.
Latest: v0.2.0 — Wave 1 #1 governance flags (--policy-hash, --authority-file, --assumptions-file, --uncertainty, --uncertainty-file, --invalidation-file) attach a signed governance sub-record on the Etch parallel chain. See CHANGELOG.md.
Install
pip install etch-record
Or from a local checkout during development:
cd ~/etch-marketing/etch-record
pip install -e .
Configure
Set three env vars in your shell rc (~/.zshrc or ~/.bashrc):
export ETCH_PROJECT_ID="your_project_id"
export ETCH_APP_TOKEN="wm_your_app_token"
export ETCH_BASE_URL="https://etch.systems" # default; override for local dev
Get project_id + app_token from your Etch signup provisioning page. ETCH_BASE_URL defaults to https://etch.systems if unset.
Use
# Simple event
etch-record "posted X thread about Etch's audit chain"
# With tags + evidence
etch-record "researched contact via Gemini" \
--tags research,marketing \
--evidence-json '{"contact":"...","dossier_lines":247}'
# Load evidence from a file
etch-record "drafted 3 message variants" \
--tags draft,claude \
--evidence-file drafts_evidence.json
# Group events under a session (default = today's ISO date)
etch-record "approved draft v2" --session-id outreach-2026-07-26 --tags review,approved
# Print what would be sent without hitting the API
etch-record "dry run test" --dry-run
Event shape
Every call becomes a signed record_event MCP tool call on your Etch chain:
event_type:"tool_call"(only enum value that works for arbitrary marketing events)session_id:--session-idOR auto-generated asetch-record-YYYY-MM-DDentities: derived from--tagsdescription: your quoted string (positional arg)evidence: from--evidence-jsonor--evidence-filesuccess:trueunless--failed
The Etch server appends to the SHA-256 Merkle chain, closes epochs at threshold (default 1024 events), hybrid-signs (Ed25519 + SLH-DSA-SHA2-128f), and optionally anchors to Sigstore Rekor + Bitcoin OpenTimestamps.
Verify
Every event is verifiable offline forever:
etch-verify \
--base-url https://etch.systems \
--project-id your_project_id
Governance metadata (Wave 1 #1, v0.2.0)
Attach a signed governance sub-record to any event. Any of the five flags below triggers a second call to POST /v1/etch-chain/governance-record on your Etch base URL, which hashes the governance object canonically and signs it into the Etch parallel chain.
etch-record "KYC decision on customer ABC" \
--tags kyc,fintech,decision \
--policy-hash sha256:9f8c... \
--authority-file authority.json \
--uncertainty '0.87:hash-lookup-match-rate' \
--invalidation-file invalidation_conditions.json
authority.json:
{
"identity": "compliance-officer@acme.example",
"scope": ["fintech-kyc-decisions"],
"expires_at": "2026-12-31T23:59:59Z"
}
invalidation_conditions.json:
[
{"if": "SOP hash changes", "then": "re-approve required"}
]
Assumptions file uses the same shape:
[
{"claim": "SOP v3.2 is current", "source_ref": "doc_hash:xyz"}
]
Output when both calls succeed:
OK session=etch-record-2026-08-01 event_id=abc-def-123
OK governance_seq=1 governance_hash=sha256:xyz...
The base event was recorded via the OSS chain; the governance sub-record was signed into the Etch parallel chain and cross-references the event by ID. Both chains verify offline via etch-verify (OSS) and etch-chain-verify (Etch).
Exit codes
0success (including two-call success when governance flags were set)1config error (missing env vars)2MCPrecord_eventerror3unexpected exception4rate limit (client-side sliding window)5governance sub-record failed — the base event was recorded successfully; use the printedevent_idto retry the governance call
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file etch_record-0.5.0.tar.gz.
File metadata
- Download URL: etch_record-0.5.0.tar.gz
- Upload date:
- Size: 43.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/7.0.0 CPython/3.13.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f6b71a9425975d6cf9e84ea38e4b278775ee287fc31a94e620f206396dc9671a
|
|
| MD5 |
330bf47fd279eca9b23df5dfa849b484
|
|
| BLAKE2b-256 |
0847c0f0444169fb77d716df002b84c06f869fd33c668f424ae053dc6ea48425
|
Provenance
The following attestation bundles were made for etch_record-0.5.0.tar.gz:
Publisher:
release.yml on SaravananJaichandar/etch-record
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
etch_record-0.5.0.tar.gz -
Subject digest:
f6b71a9425975d6cf9e84ea38e4b278775ee287fc31a94e620f206396dc9671a - Sigstore transparency entry: 2313556916
- Sigstore integration time:
-
Permalink:
SaravananJaichandar/etch-record@0b7545af88e7857314d2c5dda8df31c6ac8b0972 -
Branch / Tag:
refs/tags/v0.5.0 - Owner: https://github.com/SaravananJaichandar
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@0b7545af88e7857314d2c5dda8df31c6ac8b0972 -
Trigger Event:
push
-
Statement type:
File details
Details for the file etch_record-0.5.0-py3-none-any.whl.
File metadata
- Download URL: etch_record-0.5.0-py3-none-any.whl
- Upload date:
- Size: 28.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/7.0.0 CPython/3.13.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
32d9217bb4a3a4f2951dab7b0b85c584a2d1c36393329504d9ce85f424b4b45f
|
|
| MD5 |
a4895882c19a7d2233f9919c443fa6d2
|
|
| BLAKE2b-256 |
4116dfc6de954771c29745ba707c18177851af18d4fad9d2cb5320a88c548999
|
Provenance
The following attestation bundles were made for etch_record-0.5.0-py3-none-any.whl:
Publisher:
release.yml on SaravananJaichandar/etch-record
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
etch_record-0.5.0-py3-none-any.whl -
Subject digest:
32d9217bb4a3a4f2951dab7b0b85c584a2d1c36393329504d9ce85f424b4b45f - Sigstore transparency entry: 2313556928
- Sigstore integration time:
-
Permalink:
SaravananJaichandar/etch-record@0b7545af88e7857314d2c5dda8df31c6ac8b0972 -
Branch / Tag:
refs/tags/v0.5.0 - Owner: https://github.com/SaravananJaichandar
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@0b7545af88e7857314d2c5dda8df31c6ac8b0972 -
Trigger Event:
push
-
Statement type: