BC-Provenance-Mark-CLI TypeScript Library - v1.0.0-alpha.16
    Preparing search index...

    BC-Provenance-Mark-CLI TypeScript Library - v1.0.0-alpha.16

    Blockchain Commons Provenance Mark CLI (TypeScript)

    Disclaimer: This package is under active development and APIs may change.

    @bcts/provenance-mark-cli is a command line tool for creating and managing Provenance Mark chains.

    Provenance Marks are cryptographically-secured markers that establish authenticity and provenance of digital works. They form chains where each mark references the previous one, creating an unforgeable timeline.

    Features:

    • Create new provenance mark chains with a genesis mark
    • Add new marks to existing chains
    • Print marks in publishable formats (Markdown, UR, JSON)
    • Validate provenance mark chains for integrity
    • Support for multiple resolution levels (low, medium, quartile, high)

    This TypeScript implementation is based on provenance-mark-cli-rust v0.6.0 (commit).

    # Install globally
    bun add -g @bcts/provenance-mark-cli

    # Or run directly with bunx
    bunx @bcts/provenance-mark-cli --help
    # Create a new provenance mark chain
    provenance new mychain

    # Create with a specific resolution
    provenance new mychain --resolution high

    # Create with a custom comment
    provenance new mychain --comment "Genesis mark for my project"

    # Create with a specific seed (base64)
    provenance new mychain --seed "base64encodedSeed=="

    Output:

    Provenance mark chain created at: /path/to/mychain

    Mark 0 written to: /path/to/mychain/marks/mark-0.json

    ---

    2025-01-27T21:59:52Z

    #### ur:provenance/lfaohdft...

    #### `๐Ÿ…Ÿ PLAY WASP FLUX SWAN`

    ๐Ÿ…Ÿ ๐Ÿ’Ž ๐Ÿฆ„ ๐Ÿ“ ๐Ÿงข

    Genesis mark.
    # Add next mark to the chain
    provenance next mychain --comment "New release v1.0"

    # Output as UR only
    provenance next mychain --format ur --quiet

    # Output as JSON
    provenance next mychain --format json
    # Print all marks in the chain
    provenance print mychain

    # Print specific range
    provenance print mychain --start 0 --end 5

    # Print only the genesis mark
    provenance print mychain --start 0 --end 0
    # Validate a chain directory
    provenance validate --dir mychain

    # Validate specific URs
    provenance validate ur:provenance/... ur:provenance/...

    # Validate with warnings instead of errors
    provenance validate --warn --dir mychain

    When you create a new chain, the following structure is created:

    mychain/
    โ”œโ”€โ”€ generator.json # Chain state (KEEP SECRET!)
    โ””โ”€โ”€ marks/
    โ”œโ”€โ”€ mark-0.json # Genesis mark
    โ”œโ”€โ”€ mark-1.json # Second mark
    โ””โ”€โ”€ ...

    Important: The generator.json file contains the seed and must be kept secret. If compromised, an attacker could forge marks in your chain.

    Usage: provenance [options] [command]

    Commands:
    new <dir> Create a new provenance mark chain
    next <dir> Generate the next mark in a chain
    print <dir> Print marks from a chain
    validate Validate provenance marks

    new Options:
    --seed <base64> Seed for the chain (default: random)
    --resolution <level> Resolution: low, medium, quartile, high (default: quartile)
    --comment <text> Comment for genesis mark

    next Options:
    --comment <text> Comment for the new mark
    --format <fmt> Output format: markdown, ur, json (default: markdown)
    --quiet Suppress status messages

    print Options:
    --start <n> First mark to print (default: 0)
    --end <n> Last mark to print (default: last)

    validate Options:
    --dir <path> Validate all marks in directory
    --warn Warn instead of error on issues

    Global Options:
    -h, --help Display help
    -V, --version Display version

    Each mark includes:

    • UR: Complete data structure in Uniform Resource format
    • Bytewords: Human-readable identifier (e.g., ๐Ÿ…Ÿ PLAY WASP FLUX SWAN)
    • Bytemoji: Emoji identifier (e.g., ๐Ÿ…Ÿ ๐Ÿ’Ž ๐Ÿฆ„ ๐Ÿ“ ๐Ÿงข)
    • Comment: Optional descriptive text