From d1d8b2c84490f19c731eb4127b998eaad7d2eee1 Mon Sep 17 00:00:00 2001 From: huhn511 Date: Fri, 19 Feb 2021 16:57:20 +0100 Subject: [PATCH] add generated readme --- identity/README.md | 59 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 59 insertions(+) create mode 100644 identity/README.md diff --git a/identity/README.md b/identity/README.md new file mode 100644 index 0000000000..ea8146ba95 --- /dev/null +++ b/identity/README.md @@ -0,0 +1,59 @@ +# identity + +## IOTA Identity +IOTA Identity is a [Rust](https://www.rust-lang.org/) implementation of decentralized identity, also known as Self Sovereign Identity (SSI), through the [W3C Decentralized Identifiers (DID)](https://w3c.github.io/did-core/) and [Verifiable Credentials](https://www.w3.org/TR/vc-data-model/) standards alongside supporting methods, utilizing the [IOTA Distributed Ledger](https://www.iota.org). + + +## Example +```rust +use identity::iota::Client; +use identity::iota::IotaDocument; +use identity::crypto::KeyPair; +use identity::iota::Result; + +#[smol_potat::main] +async fn main() -> Result<()> { + + // Create a client to interact with the IOTA Tangle. + let client: Client = Client::new()?; + + // Create a DID Document (an identity). + let (mut document, keypair): (IotaDocument, KeyPair) = IotaDocument::builder() + .authentication_tag("key-1") + .did_network(client.network().as_str()) + .build()?; + + // Sign the DID Document with the default authentication key. + document.sign(keypair.secret())?; + + // Use the client to publish the DID Document to the IOTA Tangle. + let transaction: _ = client.publish_document(&document).await?; + + // Print the DID Document transaction link. + println!("DID Document Transaction > {}", client.transaction_url(&transaction)); + + Ok(()) +} + +``` + +**Output**: Example DID Document in the [Tangle Explorer](https://explorer.iota.org/mainnet/transaction/LESUXJUMJCOWGHU9CQQUIHCIPYELOBMHZT9CHCYHJPO9BONQ9IQIFJSREYNOCTYCTQYBHBMBBWJJZ9999). + +## Documentation & Community Resources +- [identity.rs](https://github.com/iotaledger/identity.rs): Rust source code of this library on GitHub. +- [Identity Documentation Pages](https://identity.docs.iota.org/welcome.html): Supplementing documentation with simple examples on library usage to get you started. +- [More Examples](https://github.com/iotaledger/identity.rs/tree/dev/examples): Practical examples to get started with the library. +- [IOTA Identity Experience Team Website](https://iota-community.github.io/X-Team_IOTA_Identity/): Website of aforementioned team. + +## Structure (Temporary) + +- Resources + - Docs Link (Website & User Guide) + - X-Team +- Simple Example +- Architecture/Overview +- Get + + + +License: Apache-2.0