Skip to main content

Create a Locked Notarization

Create a Locked Notarization

This guide will walk you through the process of creating a Locked Notarization and publishing it to an IOTA network. Locked notarizations are immutable and non-transferable, making them ideal for permanent records and compliance scenarios.

Key Characteristics of Locked Notarizations

  • Immutable: State and metadata cannot be changed after creation
  • Non-transferable: Cannot be transferred to other addresses
  • Delete locks: Support time-based destruction controls
  • Permanent record: Provides immutable document notarization

1. Get Funds to cover the gas costs

To create a Locked Notarization, you will need to have an IOTA network node running. You will also need an address with enough funds to cover the gas cost of the whole procedure.

In test networks as well as local ones, you can use a faucet to request funds.

tip

If you want to use the main IOTA network, you will need an address with actual IOTA funds to create a new Locked Notarization.

examples/utils/utils.rs
loading...

2. Create a Locked Notarization with Delete Lock

The Notarization uses builder pattern to create a new Locked Notarization object with delete lock controls.

examples/01_create_locked_notarization.rs
loading...

3. Publish the Locked Notarization

To publish the Locked Notarization, you will need to call the build_and_execute method.

examples/01_create_locked_notarization.rs
loading...

End Result

The end result will be a Locked Notarization object that is published to the IOTA network with the following characteristics:

  • Immutable content: State and metadata cannot be modified
  • Non-transferable: Ownership cannot be changed
  • Delete protection: Controlled by the specified delete lock
  • Permanent record: Ideal for compliance and audit requirements

Delete Lock Types

Locked notarizations support different delete lock options:

  • None: Can be destroyed immediately after creation
  • UnlockAt(timestamp): Cannot be destroyed until specified timestamp
  • UntilDestroyed: Cannot be destroyed (permanent record)

Use Cases for Locked Notarizations

  • Regulatory compliance: Documents that must remain unchanged
  • Legal records: Court documents, contracts, certifications
  • Audit trails: Immutable records for compliance purposes

Long-term Archival

  • Historical records: Documents of historical significance
  • Academic research: Research data that must remain unaltered
  • Digital preservation: Long-term storage of important documents

Trust and Verification

  • Certificates: Educational or professional certifications
  • Attestations: Third-party verifications
  • Timestamps: Proof of existence at specific times

Full Example Code

examples/01_create_locked_notarization.rs
loading...

Running Examples Locally

In order to run the examples, you will need to run an IOTA network locally.

If you want to use something different, you will need to modify the API and faucet endpoints in the examples to match your setup.