Skip to content
Rust implementation of the ISCC specification
Branch: master
Clone or download
Latest commit f9f04f9 Jul 28, 2019
Type Name Latest commit message Commit time
Failed to load latest commit information.
benches Add benchmarks Jul 15, 2019
src Move doc-test back normal dependencies Jul 28, 2019
tests Rename lib to iscc Jul 13, 2019
.gitignore Initial commit Jul 7, 2019
Cargo.toml Set version to 0.2.0 Jul 28, 2019
LICENSE Add license file Jul 13, 2019 Set version to 0.2.0 Jul 28, 2019


Rust implementation of the ISCC specification



Add this to your Cargo.toml:

iscc-rs = "0.2"


This example shows how to create an ISCC Code.

use std::error::Error;

use iscc::{content_id_text, data_id, instance_id, meta_id};

fn main() -> Result<(), Box<dyn Error>> {
    // Generate ISCC Component Codes
    let (mid, _title, _extra) = meta_id("Title of Content", "");
    let cid = content_id_text("some text", false);
    let did = data_id("tests/test_data/mediafile.html")?;
    let (iid, _tophash) = instance_id("tests/test_data/mediafile.html")?;

    // Join ISCC Components to fully qualified ISCC Code
    let iscc_code = [mid, cid, did, iid].join("-");
    println!("ISCC: {}", iscc_code);

You can’t perform that action at this time.