Skip to content

Command-line tool

The @halvorai/ingest package includes a command-line tool. Run it with npx, or install the package and use the halvorai-ingest binary.

Terminal window
npx @halvorai/ingest help

Sets up a source for an application in one step.

Terminal window
npx @halvorai/ingest init --api-key hk_test_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx

What it does:

  1. Generates an Ed25519 key pair on your machine.
  2. Registers the public key as a source with POST /v1/sources. The private key never leaves your machine.
  3. Writes HALVOR_API_KEY and HALVOR_SOURCE_KEY to .env.local, keeping other lines in the file.
  4. Sends one signed test event and waits for it to be accepted.
  5. Prints the dashboard link where the event appears.
OptionPurpose
--api-keyThe key to use. If omitted it reads HALVOR_API_KEY, or asks in an interactive terminal.
--endpointOverride the API URL. The default follows the key prefix.
--nameA name for the source. Defaults to the machine’s host name.
--cwdThe folder for .env.local. Defaults to the current folder.

Add .env.local to your .gitignore. It holds a private key. Run init once per environment, because a source belongs to one environment: the sandbox needs a test key and production needs a live key.

Checks an evidence pack on your own machine, with no upload and no HalvorAI account.

Terminal window
npx @halvorai/ingest verify-pack ./pck_01JA8R2M7D0F3G6H9J2K5L8N1P.zip
OptionPurpose
--jwksA file or URL of a pinned public key or key set. Without it the tool fetches the key set named in the signed manifest.

It prints a pass or fail report for the manifest signature, every file digest, every event signature, the hash chain and the daily anchors, and exits non-zero on failure. The full list of checks is on the verify an evidence pack page. A browser version that also uploads nothing is available in the dashboard at /verify.

CodeMeaning
0The command succeeded, or the pack verified.
1The command failed, or the pack did not verify.
2The arguments were not understood.