diff --git a/cli/src/cli.yaml b/cli/src/cli.yaml index e1483ed1c..9c5182e20 100644 --- a/cli/src/cli.yaml +++ b/cli/src/cli.yaml @@ -346,10 +346,10 @@ subcommands: - invitation_status: about: "Check invitation status" version: "0.1" - - create_credential_template: + - create-credential-template: about: "Create credential template" version: "0.1" - - list_credential_templates: + - list-credential-templates: about: "List credential templates" version: "0.1" - trust-registry: diff --git a/docs/_static/extra.css b/docs/_static/extra.css index 7d4499612..6cfd93894 100644 --- a/docs/_static/extra.css +++ b/docs/_static/extra.css @@ -1,3 +1,7 @@ +h1, h2, h3 { + font-weight: 800; +} + .md-header { /* background-color: #333; */ box-shadow: none !important; diff --git a/docs/_static/images/trust-triangle.png b/docs/_static/images/trust-triangle.png new file mode 100644 index 000000000..eea4882f0 Binary files /dev/null and b/docs/_static/images/trust-triangle.png differ diff --git a/docs/android/index.md b/docs/android/index.md new file mode 100644 index 000000000..4670ff5dc --- /dev/null +++ b/docs/android/index.md @@ -0,0 +1,13 @@ +# The Trinsic Java / Android SDK + +The Trinsic Java / Android SDK makes it easy to interact with the Trinsic API from any Java application. The most recent version of the library can be found on ____. You can find the SDKs source on [Github](https://github.com/trinsic-id/sdk/java). + +## Installation +TODO + +## Configuration +TODO + +## Next Steps +TODO + diff --git a/docs/cli/index.md b/docs/cli/index.md new file mode 100644 index 000000000..e85047be1 --- /dev/null +++ b/docs/cli/index.md @@ -0,0 +1,82 @@ +# The Trinsic CLI + +The Trinsic CLI makes it easy to interact with the Trinsic API from your terminal. You can get the CLI on homebrew or build the CLI from source on [Github](https://github.com/trinsic-id/sdk/cli. It contains all the commands of Trinsic's SDKs and makes them interactive. + +## Installation + +The CLI can be installed directly as binary or built from source. +### Using Homebrew for MacOS and Linux + +``` +brew tap trinsic-id/trinsic +brew install trinsic +``` + +### From source using the Rust toolchain + +This requires the [Rustup toolchain :material-open-in-new:](https://www.rust-lang.org/tools/install){target=_blank} installed on your system. + +Once installed, run this command in terminal: + +```bash +cargo +nightly install --git https://github.com/trinsic-id/sdk trinsic +``` + +To verify that the CLI has been installed successfully, try running: + +```bash +trinsic --help +``` + +## Configuration + +The CLI stores its configuration in the user's home directory in `~/.trinsic/`. This directory contains the main configuration file `config.toml` and all the profile data. + +### Show Configuration + +To print the current configuration file in the terminal use: + +```bash +trinsic config --show +``` + +Typical configuration file may look like this: + +```toml +[server] +address = "http://localhost:5000/" + +[profile] +default = "my_profile" +``` + +### Update Configuration Entry + +To change the configuration values, use the `config` subcommand with the attribute and it's value. + +```bash +trinsic config +``` + +The following attributes are currently supported: + +`server-address` +: Updates the default server address the CLI communicates + + ```bash + trinsic config --server-address https://example.com/ + ``` + +`profile-default` +: Updates the default profile used with the CLI + + ```bash + trinsic config --profile-default alice + ``` + +## Next Steps + +Once the CLI is installed and configured, you're ready to start building! We recommend going through the [walkthrough](./vaccination-cli.md) next. If you're ready to dive into building your ecosystem, check out our [API Reference](/reference/index.md) + +[Start Walkthrough](./vaccination-cli.md){ .md-button .md-button--primary } [Explore API](/reference/index.md){ .md-button } + diff --git a/docs/walkthrough/vaccination-cli.md b/docs/cli/vaccination-cli.md similarity index 84% rename from docs/walkthrough/vaccination-cli.md rename to docs/cli/vaccination-cli.md index 8b46fe810..f3d8fd078 100644 --- a/docs/walkthrough/vaccination-cli.md +++ b/docs/cli/vaccination-cli.md @@ -3,35 +3,10 @@ It can be challenging to understand how verifiable credentials work until you see some examples. This walkthrough will show how a vaccination card might be issued, held, and proven using verifiable credentials with the Trinsic CLI. It assumes no prior knowledge to decentralized identity. --8<---- -walkthrough/snippets/intro-infrastructure.md -walkthrough/snippets/intro-use-case.md +/snippets/intro-infrastructure.md +/snippets/intro-use-case.md --8<---- -## Install Trinsic CLI - ---8<-- "setup/installation/install-cli.md" - -If you're here to just go through the walkthrough, check out our [Gitpod cloud environment](https://gitpod.io/#https://github.com/trinsic-id/sdk) for easy installation (You'll have to create a free account with gitpod). - -To install the CLI locally, clone our sdk github repo and compile the SDK -```bash -git clone https://github.com/trinsic-id/sdk.git - -cd sdk/cli - -cargo install --path . -``` - -Once installed, configure the CLI's server address to your Ecosystem: - -=== "Trinsic CLI" - - ```bash - trinsic config --server-address https://example.com - ``` - -!!! note - Reference: [Configuration with CLI](../reference/setup/index.md#configuration-with-cli) ## Meet Allison diff --git a/docs/concepts/index.md b/docs/concepts/index.md deleted file mode 100644 index 912268e5c..000000000 --- a/docs/concepts/index.md +++ /dev/null @@ -1,61 +0,0 @@ -# Concepts -Trinsic is a set of tools and infrastructure that enables decentralized identity for individuals and organizations. - -There are many ways that decentralized identity can be used beyond just customer login. This enables digital identity verification anywhere. In person, online, even offline. - -## Wallets -Wallets can be thought of a little like an email inbox. Wallets exist to send, receive and store credentials. Wallets can be hosted by anyone. Each wallet can only be accessed by a set of keys stored on devices. - -## Credentials -Organizations and governments across the world have converged on a digital identity document standard called Verifiable Credentials. - -Trinsic's platform covers the full credential lifecycle. Our tools help you create, issue, verify, revoke, and store these credentials. These pieces are meant to be modular and interoperable. - -Verifiable Credentials are a way of representing documents online that make them interoperable and instantly verifiable. In its technical sense, a credential is a set of one or more cryptographically verifiable assertions about a subject made by an entity. - -Just like passports and drivers licenses today have interoperability components like their barcode, credentials have the same feature but are built into the internet itself, and can be used anywhere it is supported. Our tools let you choose to support the standard. By following the verifiable credential standard, your organization can issue digital documents that can be verified anywhere. - -For a technical deep dive, refer to the [Verifiable Credentials Data Model](https://w3c.github.io/vc-data-model) - -## Passes -Passes are documents generated from one or more credentials that contain only the information required to be verified. They can be generated in advance or in real-time. Passes minimize the information about you that is shared with third parties. - -## Underlying Tech - -### Linked Data -When we consider credentials getting exchanged online far and wide, a problem starts to occur - how does everyone know what every else means when they show a credential? To the rescue comes Linked Data, a format for representing structured data with self-contained descriptors of that data. - -"Linked data is to spreadsheets and databases what the web of hypertext documents is to word processor files" - [W3C Wiki on Linked Data](https://www.w3.org/wiki/LinkedData) - -### Decentralized Identifiers -Taken from the [Verifiable Credential Data Model](https://w3c.github.io/vc-data-model/#dfn-decentralized-identifiers), a decentralized identifier is "a portable URL-based identifier, also known as a DID, associated with an entity. These identifiers are most often used in a verifiable credential and are associated with subjects such that a verifiable credential itself can be easily ported from one repository to another without the need to reissue the credential. An example of a DID is `did:example:123456abcdef`" - -### Zero Knowledge Proofs -One of the most exciting qualities of verifiable credentials are their ability to minimize the data shared about you when you prove who you are. The classic example is showing your driver's license in a bar. While a human bouncer may forget all the revealing information on your driver's license, a computerized bouncer that scans your driver's license never forgets any information. With zero knowledge proofs, you can choose specific information from your credentials to share with verifiers. - -These are enabled through a [BBS+ Signature specification](https://w3c-ccg.github.io/ldp-bbs2020/). - -Next: Choose your language - - - [CLI](../walkthrough/vaccination-cli.md) - - [Node](../walkthrough/vaccination-node.md) - - [C#](../walkthrough/vaccination-net.md) - - [Python](../walkthrough/vaccination-python.md) - - [Browser](../walkthrough/vaccination-browser.md) - -## Available SDKs - -- [x] [C#](./walkthrough/vaccination-net.md) - - [x] Xamarin (iOS, Android) - - [x] .NET Core (MacOS, Windows, Linux) -- [x] TypeScript/JS - - [x] [Node.js](./walkthrough/vaccination-node.md) - - [x] [Browser](./walkthrough/vaccination-browser.md) -- [x] Python - -## Up Next -- [ ] Objective C (iOS) -- [ ] Java/Kotlin (Android) -- [ ] React Native -- [ ] Rust -- [ ] Go \ No newline at end of file diff --git a/docs/dotnet/index.md b/docs/dotnet/index.md new file mode 100644 index 000000000..8f4981827 --- /dev/null +++ b/docs/dotnet/index.md @@ -0,0 +1,40 @@ +# The Trinsic C# / .NET SDK +The Trinsic C# / .NET SDK makes it easy to interact with the Trinsic API from your .NET application. The most recent version of the library can be found on NuGet. The Trinsic SDK supports .NET applications written in C#, VB.NET, and F# that utilize any supported version of .NET Core. You can also find the SDKs source on [Github](https://github.com/trinsic-id/sdk/dotnet). + +## Installation +Install the packages directly from [Nuget.org :material-open-in-new:](https://www.nuget.org/packages/Trinsic){target=_blank} + +=== "Package Manager" + ``` + PM> Install-Package Trinsic + ``` +=== ".NET CLI" + ``` + > dotnet add package Trinsic + ``` +=== "PackageReference" + ``` + + ``` + +## Configuration + +```csharp +using Trinsic; + +// Set the server address +var service = new WalletService("https://example.com"); + +// Create new profile or import an existing one +var myProfile = await service.CreateWallet(); + +// Set the profile to be used with authorization pipeline +service.SetProfile(myProfile); +``` + +## Next Steps + +Once the CLI is installed and configured, you're ready to start building! We recommend going through the [walkthrough](./vaccination-net.md) next. If you're ready to dive into building your ecosystem, check out our [API Reference](/reference/index.md) + +[Start Walkthrough](./vaccination-net.md){ .md-button .md-button--primary } [Explore API](/reference/index.md){ .md-button } + diff --git a/docs/walkthrough/vaccination-net.md b/docs/dotnet/vaccination-net.md similarity index 97% rename from docs/walkthrough/vaccination-net.md rename to docs/dotnet/vaccination-net.md index 2b7597d1d..d896d8092 100644 --- a/docs/walkthrough/vaccination-net.md +++ b/docs/dotnet/vaccination-net.md @@ -1,8 +1,8 @@ # Vaccination Use Case for .NET Core --8<---- -walkthrough/snippets/intro-infrastructure.md -walkthrough/snippets/intro-use-case.md +/snippets/intro-infrastructure.md +/snippets/intro-use-case.md --8<---- ## Technical requirements @@ -65,7 +65,7 @@ File.WriteAllBytes("allison.bin", allison.ToByteString().ToByteArray()); var allison = WalletProfile.Parser.ParseFrom(File.ReadAllBytes("allison.bin")); ``` -Read more about [security profiles](/reference/setup/#authorization) and authentication. +Read more about [security profiles](/reference/#authorization) and authentication. ## Certificate issuance diff --git a/docs/early-adopter.md b/docs/early-adopter.md index 99643f7ec..50d3d7258 100644 --- a/docs/early-adopter.md +++ b/docs/early-adopter.md @@ -1,9 +1,8 @@ -# Introducing Trinsic Ecosystems +# Introducing Trinsic v2 +For development teams ready to integrate verifiable credentials for an industry or use case, Trinsic v2 has been built specifically for you. We're currently in beta with a small group of customers. -For organizations ready to deploy verifiable credentials into a complex industry or use case, Trinsic has prepared tools to help you do so. +If you'd like to experiment with our SDKs, please reach out! Simply fill out the form below, and we'll get in touch. -To learn more about Trinsic Ecosystems, read our announcement about it: +
-[Announcing Trinsic Ecosystems](https://trinsic.id/introducing-trinsic-ecosystems/) - -
\ No newline at end of file +To learn more about Trinsic v2, read our [announcement](https://trinsic.id/introducing-trinsic-ecosystems/), and continue exploring our docs. \ No newline at end of file diff --git a/docs/go/index.md b/docs/go/index.md new file mode 100644 index 000000000..2c2278445 --- /dev/null +++ b/docs/go/index.md @@ -0,0 +1,13 @@ +# The Trinsic Go SDK + +The Trinsic Go SDK makes it easy to interact with the Trinsic API from any Go application. The most recent version of the library can be found on ____. You can find the SDKs source on [Github](https://github.com/trinsic-id/sdk/go). + +## Installation +TODO + +## Configuration +TODO + +## Next Steps +TODO + diff --git a/docs/index.md b/docs/index.md index 1bed235f7..e80b513cb 100644 --- a/docs/index.md +++ b/docs/index.md @@ -1,31 +1,40 @@ -# Introduction +--- +hide: + - toc +--- +# Trinsic Documentation +## Issue and verify universally-accepted digital credentials. +Learn how to issue and verify universally-accepted digital credentials so that anywhere people go online or in-person, they can simply tap their phone, prove who they are, and get what they need. -## Welcome to Trinsic -Trinsic is a developer platform to exchange verifiable credentials. +[**Get started with Trinsic**](learn/index.md) - Learn about Trinsic, work through a basic implementation, plan a full implementation and learn about our tools you can use. -Verifiable Credentials transform credentials, licenses, passes, and certificates into a W3C standard format that can be exchanged digitally and verified instantly. Unlike a paper document or html form, when information from a verifiable credential is shared, it can be instantly proven to be authentic. +[**Join the Beta**](early-adopter.md) - Our platform is still in beta. While our docs are public, you'll need a special environment to start using Trinsic at this time. We're excited to help you! Please contact us and we'll help you get started. +## Connect your app to Trinsic +Get up and running in the language of your choice or interact with Trinsic through your terminal. -They require no centralized authority or proprietary technology to use - verifiable credentials are built on interoperable standards designed to be open, privacy-preserving, and distributed like the internet itself. +[:octicons-terminal-16: **Use the CLI**](cli/index.md) +### Server-side SDKs +[:material-nodejs: Node](node/index.md){ .md-button .md-button--primary } +[:material-language-python: Python](python/index.md){ .md-button .md-button--primary } +[:material-microsoft: .NET](dotnet/index.md){ .md-button .md-button--primary } +### Client-side SDKs -Hundreds of organizations of all sizes and industries use Trinsic’s infrastructure and tools to instantly verify information about individuals with technology instead of paper. +[:fontawesome-brands-js-square: Web](web/index.md){ .md-button .md-button--primary } -## Available SDKs +### Coming Soon -- [x] [C#](./walkthrough/vaccination-net.md) - - [x] Mobile (Xamarin, MAUI) - - [x] .NET Core (MacOS, Windows, Linux) - - [ ] Web Assembly (Blazor) -- [x] TypeScript/JS - - [x] [Node.js](./walkthrough/vaccination-node.md) - - [x] [Browser](./walkthrough/vaccination-browser.md) -- [x] Python -- [x] Go -- [x] Rust -- [x] Swift (iOS) -- [x] Java/Kotlin (Android) +[:material-menu: Go](#){ .md-button } +[:material-language-ruby: Ruby](#){ .md-button } +[:material-language-java: Java](#){ .md-button } +[:material-android: Android](#){ .md-button } +[:material-apple: iOS](#){ .md-button } -## Up Next -- [ ] React Native -Next: [Learn the Concepts](./concepts/index.md) + + +## Additional Resources +[**Join the Community**](https://join.slack.com/t/trinsiccommunity/shared_invite/zt-pcsdy7kn-h4vtdPEpqQUlmirU8FFzSQ) - We have a growing community on Slack of people who are building with Trinsic. Join to ask questions and participate in our community events. + +[**Follow our progress on Github**](https://github.com/trinsic-id) - Most of our work is done in the open. We love to collaborate with developers and are always open to feedback. + diff --git a/docs/ios/index.md b/docs/ios/index.md new file mode 100644 index 000000000..95cc97de2 --- /dev/null +++ b/docs/ios/index.md @@ -0,0 +1,13 @@ +# The Trinsic Swift SDK + +The Trinsic Swift SDK makes it easy to interact with the Trinsic API from any iOS application. The most recent version of the library can be found on ____. You can find the SDKs source on [Github](https://github.com/trinsic-id/sdk/swift). + +## Installation +TODO + +## Configuration +TODO + +## Next Steps +TODO + diff --git a/docs/java/index.md b/docs/java/index.md new file mode 100644 index 000000000..a42983064 --- /dev/null +++ b/docs/java/index.md @@ -0,0 +1,13 @@ +# The Trinsic Java SDK + +The Trinsic Java SDK makes it easy to interact with the Trinsic API from any Java application. The most recent version of the library can be found on ____. You can find the SDKs source on [Github](https://github.com/trinsic-id/sdk/java). + +## Installation +TODO + +## Configuration +TODO + +## Next Steps +TODO + diff --git a/docs/learn/credentials.md b/docs/learn/credentials.md new file mode 100644 index 000000000..8bd677319 --- /dev/null +++ b/docs/learn/credentials.md @@ -0,0 +1,11 @@ +# Credentials +Organizations and governments across the world have converged on a digital identity document standard called Verifiable Credentials. + +Trinsic's platform covers the full credential lifecycle. Our tools help you create, issue, verify, revoke, and store these credentials. These pieces are meant to be modular and interoperable. + +Verifiable Credentials are a way of representing documents online that make them interoperable and instantly verifiable. In its technical sense, a credential is a set of one or more cryptographically verifiable assertions about a subject made by an entity. + +Just like passports and drivers licenses today have interoperability components like their barcode, credentials have the same feature but are built into the internet itself, and can be used anywhere it is supported. Our tools let you choose to support the standard. By following the verifiable credential standard, your organization can issue digital documents that can be verified anywhere. + +For a technical deep dive, refer to the [Verifiable Credentials Data Model](https://w3c.github.io/vc-data-model) + diff --git a/docs/learn/ecosystems.md b/docs/learn/ecosystems.md new file mode 100644 index 000000000..0ece8ed2c --- /dev/null +++ b/docs/learn/ecosystems.md @@ -0,0 +1,10 @@ +# Ecosystems + +Exchanging credentials often requires many different participants to all communicate and collaborate. Aligning standards and incentives is challenging. + +We've made it simple to create an ecosystem of participants to all exchange credentials. + +## Ecosystem Governance Framework + +## Potential Scenarios + diff --git a/docs/learn/index.md b/docs/learn/index.md new file mode 100644 index 000000000..c99bf6ac5 --- /dev/null +++ b/docs/learn/index.md @@ -0,0 +1,14 @@ +# What is Trinsic? +![Trust Triangle](/_static/images/trust-triangle.png) + +Trinsic is a developer platform to exchange verifiable credentials. + +Verifiable Credentials transform credentials, licenses, passes, and certificates into a W3C standard format that can be exchanged digitally and verified instantly. Unlike a paper document or html form, when information from a verifiable credential is shared, it can be instantly proven to be authentic. + +They require no centralized authority or proprietary technology to use - verifiable credentials are built on interoperable standards designed to be open, privacy-preserving, and distributed like the internet itself. + +Hundreds of organizations of all sizes and industries use Trinsic’s infrastructure and tools to instantly verify information about individuals with technology instead of paper. + +Trinsic is a set of tools and infrastructure that enables decentralized identity for individuals and organizations. + +There are many ways that decentralized identity can be used beyond just customer login. This enables digital identity verification anywhere. In person, online, even offline. \ No newline at end of file diff --git a/docs/learn/passes.md b/docs/learn/passes.md new file mode 100644 index 000000000..a96fe3278 --- /dev/null +++ b/docs/learn/passes.md @@ -0,0 +1,3 @@ +# Passes +Passes are documents generated from one or more credentials that contain only the information required to be verified. They can be generated in advance or in real-time. Passes minimize the information about you that is shared with third parties. + diff --git a/docs/learn/security.md b/docs/learn/security.md new file mode 100644 index 000000000..e4bc6712b --- /dev/null +++ b/docs/learn/security.md @@ -0,0 +1,7 @@ +# Trinsic's Security + +TODO + +All keys kept in HSMs. + +Authorization done with blinded secrets \ No newline at end of file diff --git a/docs/learn/tech.md b/docs/learn/tech.md new file mode 100644 index 000000000..1c1a95bfb --- /dev/null +++ b/docs/learn/tech.md @@ -0,0 +1,14 @@ +# Underlying Tech + +## Linked Data +When we consider credentials getting exchanged online far and wide, a problem starts to occur - how does everyone know what every else means when they show a credential? To the rescue comes Linked Data, a format for representing structured data with self-contained descriptors of that data. + +"Linked data is to spreadsheets and databases what the web of hypertext documents is to word processor files" - [W3C Wiki on Linked Data](https://www.w3.org/wiki/LinkedData) + +## Decentralized Identifiers +Taken from the [Verifiable Credential Data Model](https://w3c.github.io/vc-data-model/#dfn-decentralized-identifiers), a decentralized identifier is "a portable URL-based identifier, also known as a DID, associated with an entity. These identifiers are most often used in a verifiable credential and are associated with subjects such that a verifiable credential itself can be easily ported from one repository to another without the need to reissue the credential. An example of a DID is `did:example:123456abcdef`" + +## Zero Knowledge Proofs +One of the most exciting qualities of verifiable credentials are their ability to minimize the data shared about you when you prove who you are. The classic example is showing your driver's license in a bar. While a human bouncer may forget all the revealing information on your driver's license, a computerized bouncer that scans your driver's license never forgets any information. With zero knowledge proofs, you can choose specific information from your credentials to share with verifiers. + +These are enabled through a [BBS+ Signature specification](https://w3c-ccg.github.io/ldp-bbs2020/). \ No newline at end of file diff --git a/docs/learn/trinsic.md b/docs/learn/trinsic.md new file mode 100644 index 000000000..e6c740e19 --- /dev/null +++ b/docs/learn/trinsic.md @@ -0,0 +1,9 @@ +# What is Trinsic? + +Trinsic is a developer platform to exchange verifiable credentials. + +Verifiable Credentials transform credentials, licenses, passes, and certificates into a W3C standard format that can be exchanged digitally and verified instantly. Unlike a paper document or html form, when information from a verifiable credential is shared, it can be instantly proven to be authentic. + +They require no centralized authority or proprietary technology to use - verifiable credentials are built on interoperable standards designed to be open, privacy-preserving, and distributed like the internet itself. + +Hundreds of organizations of all sizes and industries use Trinsic’s infrastructure and tools to instantly verify information about individuals with technology instead of paper. \ No newline at end of file diff --git a/docs/learn/wallets.md b/docs/learn/wallets.md new file mode 100644 index 000000000..5b1c61df4 --- /dev/null +++ b/docs/learn/wallets.md @@ -0,0 +1,5 @@ +# Wallets + +Wallets can be thought of a little like an email inbox. Wallets exist to send, receive and store credentials. Wallets can be hosted by anyone. Each wallet can only be accessed by a set of keys stored on devices. +Wallets represent a user's identity. They manage an identity for an individual. +Trinsic has a wallet that is built to be eventually interoperable with other identity wallets that exist. \ No newline at end of file diff --git a/docs/node/index.md b/docs/node/index.md new file mode 100644 index 000000000..6c1fa1341 --- /dev/null +++ b/docs/node/index.md @@ -0,0 +1,35 @@ +# The Trinsic Javascript / Node SDK + +The Trinsic Node SDK makes it easy to interact with the Trinsic API from any backend javascript application. The most recent version of the library can be found on npm. You can find the SDKs source on [Github](https://github.com/trinsic-id/sdk/java). +## Installation +Install the package for Node from [npmjs.com :material-open-in-new:](https://www.npmjs.com/package/@trinsic/trinsic){target=_blank} + +=== "Install" + ```bash + npm i @trinsic/trinsic + ``` + +## Configuration + +When using the SDK in your code, you can pass parameters to the default service constructors and use the provided methods to set different active profiles. + +```typescript +import { WalletService } from '@trinsic/trinsic'; + +// Set the server address +const service = new WalletService("https://example.com"); + +// Create new profile or import an existing one +const myProfile = await service.createWallet(); + +// Set the profile to be used with authorization pipeline +service.setProfile(myProfile); +``` + +## Next Steps + +Once the SDK is installed and configured, you're ready to start building! We recommend going through the [walkthrough](./vaccination-node.md) next. If you're ready to dive into building your ecosystem, check out our [API Reference](/reference/index.md) + +[Start Walkthrough](./vaccination-node.md){ .md-button .md-button--primary } [Explore API](/reference/index.md){ .md-button } + + diff --git a/docs/walkthrough/vaccination-node.md b/docs/node/vaccination-node.md similarity index 97% rename from docs/walkthrough/vaccination-node.md rename to docs/node/vaccination-node.md index e9878e812..690ebd53e 100644 --- a/docs/walkthrough/vaccination-node.md +++ b/docs/node/vaccination-node.md @@ -1,8 +1,8 @@ # Vaccination Use Case for Node.js --8<---- -walkthrough/snippets/intro-infrastructure.md -walkthrough/snippets/intro-use-case.md +snippets/intro-infrastructure.md +snippets/intro-use-case.md --8<---- ## Technical requirements @@ -63,7 +63,7 @@ let allison = WalletProfile.deserializeBinary(profile); !!! note "Loading Profiles" In order to load a profile from a saved file you'll need to install google-protobuf with `npm i google-protobuf` in order to use the Struct class and convert the DID Document from JavaScript to the protobuf form. -Read more about [security profiles](../reference/setup/index.md#authorization) and authentication. +Read more about [security profiles](/reference/index.md#authorization) and authentication. ## Certificate issuance diff --git a/docs/python/index.md b/docs/python/index.md new file mode 100644 index 000000000..d1fbe7852 --- /dev/null +++ b/docs/python/index.md @@ -0,0 +1,25 @@ +# The Trinsic Python SDK + +The Trinsic Python SDK makes it easy to interact with the Trinsic API from any Python application. The most recent version of the library can be found on PyPi. You can find the SDKs source on [Github](https://github.com/trinsic-id/sdk/python). + +## Installation +```bash +pip install trinsic-sdk +``` + +## Configuration + +Create a reference to the wallet service that points to your ecosystem service. You should have received this URL with your ecosystem setup. + +```python +from trinsic.services import WalletService, create_channel_if_needed, ProviderService + +server_address = '' +wallet_service = WalletService(server_address) +``` + +## Next Steps + +Once the SDK is installed and configured, you're ready to start building! We recommend going through the [walkthrough](./vaccination-python.md) next. If you're ready to dive into building your ecosystem, check out our [API Reference](/reference/index.md) + +[Start Walkthrough](./vaccination-python.md){ .md-button .md-button--primary } [Explore API](/reference/index.md){ .md-button } diff --git a/docs/walkthrough/vaccination-python.md b/docs/python/vaccination-python.md similarity index 87% rename from docs/walkthrough/vaccination-python.md rename to docs/python/vaccination-python.md index 3ea266926..34bf71e73 100644 --- a/docs/walkthrough/vaccination-python.md +++ b/docs/python/vaccination-python.md @@ -1,8 +1,8 @@ # Walkthrough for Python --8<---- -walkthrough/snippets/intro-infrastructure.md -walkthrough/snippets/intro-use-case.md +/snippets/intro-infrastructure.md +/snippets/intro-use-case.md --8<---- ## Technical requirements @@ -13,7 +13,7 @@ You can run this example on your local machine, or you can use our Gitpod setup Clone this sdk repository: -In this project, we'll be following along the `trinsic_service_demo` +In this project, we'll be following along the `test_trinsic_services` ## Configure services @@ -28,7 +28,7 @@ wallet_service = WalletService(server_address) ## Setup wallet profiles Let's create three different profiles, each pointing to a separate wallet. Since we are using a single console app for this demo, we will simply set the active profile before each interaction to designate which actor is currently taking action. -To create a new wallet profile, we use the [Create Wallet](/reference/services/wallet-service/#create-wallet) feature. +To create a new wallet profile, we use the [Create Wallet](../reference/services/wallet-service/#create-wallet) feature. ```python allison = await wallet_service.create_wallet() @@ -42,7 +42,7 @@ If you would like to save the profile for future use, you can simply export the File.WriteAllBytes("allison.bin", allison.ToByteString().ToByteArray()); ``` -Read more about [security profiles](../reference/setup/index.md#authorization) and authentication. +Read more about [security profiles](../reference/index.md#authorization) and authentication. ## Certificate issuance @@ -93,7 +93,7 @@ At this point, the clinic can send the signed credential to Allison using any av ## Store certificate in personal wallet -Allison can store this credential in her cloud wallet, simply by calling the [Insert Item](/reference/services/wallet-service/#insert-record) function. +Allison can store this credential in her cloud wallet, simply by calling the [Insert Item](../reference/services/wallet-service/#insert-record) function. ```python wallet_service.set_profile(allison) @@ -132,7 +132,7 @@ Let's save this request in a file named `vaccination-certificate-frame.jsonld` This request asks Allison to provide proof of valid vaccination certificate, including the `issuer`, `batchNumber`and `countryOfVaccination` fields. -Allison can use the [Create Proof](/reference/services/wallet-service/#create-proof) functions to build a proof that will share only the requested fields. +Allison can use the [Create Proof](../reference/services/wallet-service/#create-proof) functions to build a proof that will share only the requested fields. ```python def vaccine_cert_frame_path(self) -> str: @@ -146,7 +146,7 @@ credential_proof = await wallet_service.create_proof(document_id=item_id, reveal ## Verification -Allison shares the proof of credential she created with the airline. The airline can now use [Verify Proof](/reference/services/wallet-service/#verify-proof) functions to check the validity of the proof. +Allison shares the proof of credential she created with the airline. The airline can now use [Verify Proof](../reference/services/wallet-service/#verify-proof) functions to check the validity of the proof. ```python wallet_service.set_profile(airline) diff --git a/docs/reference/setup/profiles.md b/docs/reference/index.md similarity index 83% rename from docs/reference/setup/profiles.md rename to docs/reference/index.md index 7771a8630..8fe91d071 100644 --- a/docs/reference/setup/profiles.md +++ b/docs/reference/index.md @@ -1,9 +1,14 @@ +# Overview -# Security Profiles / Authorization +If you are ready to begin integrating the SDK, make sure you have an SDK installed and configured. You can install each SDK by following the instructions in each page under **Build** in the sidebar. + +When using the SDK, you can pass parameters to the default service constructors and use the provided methods to set different active profiles. + +## Authorization Trinsic Ecosystems uses authenticated access for accessing personal data. This is implemented using [Authorization Capabilities for Linked Data :material-open-in-new:](https://w3c-ccg.github.io/zcap-ld/){target=_blank} (ZCAP-LD for short). Zcaps provide a secure way for linked data systems to grant and express authority utilizing the object capability model. Our wallet capabilities are represented as linked data objects which are signed with Linked Data Proofs. LD Proofs represent the core technology of the way we share and exchange authentic data with others. -## Profile Data Format +### Profile Data Format Security Profiles are represented as a protobuf message that contains details about the connecting device to the remote cloud wallet. These are sensitive details that contain private key data, and must always be stored in a secure storage. The details of this data contract are expressed with this proto message. @@ -36,3 +41,5 @@ message WalletProfile { This profile is always stored in its binary form using the protobuf native serialization. A profile is created by using the [Create Wallet](/reference/services/wallet-service/#create-wallet) functionality in the SDK. + + diff --git a/docs/reference/services/provider-service.md b/docs/reference/services/provider-service.md index c20ded18e..9807ad8a0 100644 --- a/docs/reference/services/provider-service.md +++ b/docs/reference/services/provider-service.md @@ -9,7 +9,7 @@ This service helps ecosystem providers with data management and onboarding. This Users can be onboarded as participants in the ecosystem by sending an invitation and a security code. This code can be sent directly through them using existing platforms or via email, SMS, etc. When users accept this invitation, they should do so using the service methods as described in [creating wallet with provider invitation](/reference/services/wallet-service/#create-wallet-with-provider-invitation) -In Trinsic Ecosystems, participants can be Individuals or Organizations. This distinction is important, as providers have the ability to apply restrictions on what functionalities can be invoked by these participants. Additonally, Organizations have the ability to write their DID Document to a public ledger. Currently, the supported ledger is Sovrin, with ION and Element still in development. +In Trinsic Ecosystems, participants can be Individuals or Organizations. This distinction is important, as providers have the ability to apply restrictions on what functionalities can be invoked by these participants. Additionally, Organizations have the ability to write their DID Document to a public ledger. Currently, the supported ledger is Sovrin, with ION and Element still in development. === "Trinsic CLI" ```bash @@ -60,3 +60,142 @@ In Trinsic Ecosystems, participants can be Individuals or Organizations. This di ``` The `invitationId` in the response contains the security code that users must supply when creating their wallet. If using email method in onboarding, they will receive this code in their email. + +## Credential Templates + +Credential Templates are json templates that help issuers save context when issuing credentials. + +When issuing a credential through Trinsic, it's as simple as adding the attributes to the credential template and then issuing it. + +These credential templates can be shared between issuers in an ecosystem. + +A template is a saved JSON-LD schema that is used to define/create credentials and verification. + +### Get + +=== "Trinsic CLI" + ```bash + + ``` +=== "TypeScript" + ```typescript + + ``` +=== "C#" + ```csharp + + ``` + +=== "Python" + ```python + + ``` + +=== "Go" + ```golang + + ``` +=== "Java" + ```java + + ``` +=== "Ruby" + ```ruby + + ``` + +### Search + +=== "Trinsic CLI" + ```bash + + ``` +=== "TypeScript" + ```typescript + + ``` +=== "C#" + ```csharp + + ``` + +=== "Python" + ```python + + ``` + +=== "Go" + ```golang + + ``` +=== "Java" + ```java + + ``` + +=== "Ruby" + ```ruby + + ``` + +### Update + +=== "Trinsic CLI" + ```bash + + ``` +=== "TypeScript" + ```typescript + + ``` +=== "C#" + ```csharp + + ``` + +=== "Python" + ```python + + ``` + +=== "Go" + ```golang + + ``` +=== "Java" + ```java + + ``` +=== "Ruby" + ```ruby + + ``` + +### Delete + +=== "Trinsic CLI" + ```bash + + ``` +=== "TypeScript" + ```typescript + + ``` +=== "C#" + ```csharp + + ``` + +=== "Python" + ```python + + ``` + +=== "Go" + ```golang + + ``` +=== "Java" + ```java + + ``` diff --git a/docs/reference/services/trust-registry.md b/docs/reference/services/trust-registry.md index 2b374d833..16d0a4dd2 100644 --- a/docs/reference/services/trust-registry.md +++ b/docs/reference/services/trust-registry.md @@ -1,15 +1,227 @@ # Trust Registry -## Overview +In many real-world credential exchange scenarios, a credential holder or verifier has the question “How do I know the issuer of this credential is trustworthy?” + +Credential holders may also be uneasy about sharing information with a verifier if trust in the verifier has not been established. + +These problems can be solved by having a trusted third party vouch for the trustworthiness of a credential exchange participant. + +A trust registry is a list of authorized issuers and verifiers in the ecosystem and the types of credentials and passes they are authorized to issue and verify. + + ## Specification +The Trust over IP Foundation has a specification for a interoperable trust registry. +This defined an API interface so that trust registries can be queried in the same way. +Our implementation is based off of this [trust registry spec](https://github.com/trustoverip/tswg-trust-registry-tf). ## API Reference +### Create a Ecosystem Governance Framework +An ecosystem governance framework is useful because it provides a good basis for verifying issuers and verifiers. It's a json-ld document that lists the issuers and verifiers. These issuers and verifiers are identified by a decentralized identifier. The governance framework is signified by an identifier as well. This can be used to represent the governance framework outside in the credential that it comes in. + +=== "Trinsic CLI" + ```bash + trinsic trust-registry register-efg + ``` +=== "TypeScript" + ```typescript + + ``` +=== "C#" + ```csharp + + ``` -### Ecosystem Governance Framework +=== "Python" + ```python + + ``` +=== "Go" + ```golang + + ``` +=== "Java" + ```java + + ``` +=== "Ruby" + ```ruby + + ``` ### Register Issuers and Verifiers +Each entity on the governance framework, whether an issuer or a verifier, is represented by a decentralized identifier. These entities are registered to either issue or verify specific credential types. A credential type is represented as a fully qualified `type` URI, of the kind found in a JSON-LD Verifiable Credential. +Finally, each entity must be registered on a specific governance framework. + +=== "Trinsic CLI" + ```bash + trinsic trust-registry register-issuer \ + --egf http://hl7.org/fhir \ + --credential-type https://w3id.org/vaccination#VaccinationCertificate \ + --did did:example:fabre + ``` +=== "TypeScript" + ```typescript + + ``` +=== "C#" + ```csharp + + ``` + +=== "Python" + ```python + + ``` + +=== "Go" + ```golang + + ``` +=== "Java" + ```java + + ``` +=== "Ruby" + ```ruby + + ``` + +### Unregister Issuers and Verifiers +To unregister an entity, include the credential type, the did, and the ecosystem governance framework. The credential type will be unregistered from that issuer. + +=== "Trinsic CLI" + ```bash + trinsic trust-registry unregister-issuer \ + --egf http://hl7.org/fhir \ + --credential-type https://w3id.org/vaccination#VaccinationCertificate \ + --did did:example:fabre + ``` +=== "TypeScript" + ```typescript + + ``` +=== "C#" + ```csharp + + ``` +=== "Python" + ```python + + ``` + +=== "Go" + ```golang + + ``` +=== "Java" + ```java + + ``` +=== "Ruby" + ```ruby + + ``` ### Check Authoritative Status +Check the status of an issuer for a credential type within a given governance framework. Returns all historical data for the given input parameter. + +=== "Trinsic CLI" + ```bash + trinsic trust-registry check-issuer \ + --egf http://hl7.org/fhir \ + --credential-type https://w3id.org/vaccination#VaccinationCertificate \ + --did did:example:fabre + ``` +=== "TypeScript" + ```typescript + + ``` +=== "C#" + ```csharp + + ``` + +=== "Python" + ```python + + ``` + +=== "Go" + ```golang + + ``` +=== "Java" + ```java + + ``` +=== "Ruby" + ```ruby + + ``` + +### Search +Search the registry for authoritative issuer and verifiers using a custom query in a SQL format. + +=== "Trinsic CLI" + ```bash + trinsic trust-registry search --query + ``` +=== "TypeScript" + ```typescript + + ``` +=== "C#" + ```csharp + + ``` + +=== "Python" + ```python + + ``` + +=== "Go" + ```golang + + ``` +=== "Java" + ```java + + ``` +=== "Ruby" + ```ruby + + ``` +### Cache Offline Registry File + +=== "Trinsic CLI" + ```bash + trinsic trust-registry download + ``` +=== "TypeScript" + ```typescript + + ``` +=== "C#" + ```csharp + + ``` + +=== "Python" + ```python + + ``` -### Offline Registry File \ No newline at end of file +=== "Go" + ```golang + + ``` +=== "Java" + ```java + + ``` +=== "Ruby" + ```ruby + + ``` \ No newline at end of file diff --git a/docs/reference/services/wallet-service.md b/docs/reference/services/wallet-service.md index 6ba830a95..b127fb672 100644 --- a/docs/reference/services/wallet-service.md +++ b/docs/reference/services/wallet-service.md @@ -1,6 +1,6 @@ # Wallet Service -The wallet service is the main interface for interacting with a cloud wallet. The service endpoints are designed to closely match the recommendations of the [Universal Wallet 2020 :material-open-in-new:](https://w3c-ccg.github.io/universal-wallet-interop-spec/){target=_blank} specficiation by W3C CCG. The service exposes a gRPC interface and a set of data contracts as described in the specification. Our intention with this design is to bring it closer to interoperability as more implementations of this wallet appear in production. +The wallet service is the main interface for interacting with a cloud wallet. The service endpoints are designed to closely match the recommendations of the [Universal Wallet 2020 :material-open-in-new:](https://w3c-ccg.github.io/universal-wallet-interop-spec/){target=_blank} specification by W3C Community Credentials Group. The service exposes a gRPC interface and a set of data contracts as described in the specification. Our intention with this design is to bring it closer to interoperability as more implementations of this wallet appear in production. ## Create Wallet @@ -8,7 +8,7 @@ Wallets can be created directly by the user or through an invitation by the ecos ### Create wallet directly -To create a wallet directly without invitation, use the following methods. These methods return secure profile data that should be stored in a safe place. The profile is used to authenticate the wallet service with the cloud provider. Read more details and recommendations in the [Security Profiles](/reference/setup/#authorization) page. +To create a wallet directly without an invitation, use the following methods. These methods return secure profile data that should be stored in a safe place. The profile is used to authenticate the wallet service with the cloud provider. Read more details and recommendations in the [Security Profiles](/reference/#authorization) page. === "Trinsic CLI" ```bash @@ -218,6 +218,39 @@ The wallet service supports signing data using [BBS+ Signatures :material-open-i The output of this method will be a signed JSON document using BBS+ Signature Suite 2020. This document is not automatically stored in the wallet when issued. You need to call the [insert record](#insert-record) separately if you'd like to store a copy of this document. +## Issue Credential from Template + + +=== "Trinsic CLI" + ```bash + + ``` +=== "TypeScript" + ```typescript + + ``` +=== "C#" + ```csharp + + ``` + +=== "Python" + ```python + + ``` + +=== "Go" + ```golang + + ``` +=== "Java" + ```java + + ``` +=== "Ruby" + ```ruby + + ``` ## Create Proof Wallets allow data to be shared between parties in a secure manner, using a technique called [Zero Knowledge Proofs](/faq/#what-are-zero-knowledge-proofs). Trinsic Ecosystems uses the BBS+ Signature Proof scheme to allow data to be selectively disclosed to the requesting party. This allows users to share only the requested subset of data, instead the entire document. diff --git a/docs/reference/setup/configuration.md b/docs/reference/setup/configuration.md deleted file mode 100644 index 4a63a2797..000000000 --- a/docs/reference/setup/configuration.md +++ /dev/null @@ -1,83 +0,0 @@ -## Configuration - -Trinsic SDK contains minimal configuration. This configuration is stored differently, depending on what package is used. - -### Configuration with CLI - -The CLI stores it's configuration in the user's home directory, typically in `~/.trinsic/`. This directory contains the main configuration file `config.toml` and all the profile data. - -### Show Configuration - -To print the current configuration file in the terminal use: - -```bash -trinsic config --show -``` - -Typical configuration file may look like this: - -```toml -[server] -address = "http://localhost:5000/" - -[profile] -default = "my_profile" -``` - -### Update Configuration Entry - -To change the configuration values, use the `config` subcommand with the attribute and it's value. - -```bash -trinsic config -``` - -The following attributes are currently supported: - -`server-address` -: Updates the default server address the CLI communicates - - ```bash - trinsic config --server-address https://example.com/ - ``` - -`profile-default` -: Updates the default profile used with the CLI - - ```bash - trinsic config --profile-default alice - ``` - -### Configuration with SDK - -When using the SDK in your code, you can pass parameters to the default service constructors and use the provided methods to set different active profiles. - -=== "TypeScript" - - ```typescript - import { WalletService } from '@trinsic/trinsic'; - - // Set the server address - const service = new WalletService("https://example.com"); - - // Create new profile or import an existing one - const myProfile = await service.createWallet(); - - // Set the profile to be used with authorization pipeline - service.setProfile(myProfile); - ``` - -=== "C#" - - ```csharp - using Trinsic; - - // Set the server address - var service = new WalletService("https://example.com"); - - // Create new profile or import an existing one - var myProfile = await service.CreateWallet(); - - // Set the profile to be used with authorization pipeline - service.SetProfile(myProfile); - ``` \ No newline at end of file diff --git a/docs/reference/setup/index.md b/docs/reference/setup/index.md deleted file mode 100644 index b4fccff3d..000000000 --- a/docs/reference/setup/index.md +++ /dev/null @@ -1,143 +0,0 @@ -# Setup -## Installation - -If you are ready to begin integrating the SDK into an existing project, make sure you have an SDK installed. -We currently provide a CLI, TypeScript, and C# SDKs for local development. - -If you're here to just go through the walkthrough, check out our [Gitpod cloud environment](https://gitpod.io/#https://github.com/trinsic-id/sdk) for easy installation (You'll have to create a free account with gitpod). - -=== "Trinsic CLI" - - --8<-- "setup/installation/install-cli.md" - -=== "TypeScript" - - --8<-- "setup/installation/install-node.md" - -=== "C#" - - --8<-- "setup/installation/install-net.md" - -## Authorization - -Trinsic Ecosystems uses authenticated access for accessing personal data. This is implemented using [Authorization Capabilities for Linked Data :material-open-in-new:](https://w3c-ccg.github.io/zcap-ld/){target=_blank} (ZCAP-LD for short). Zcaps provide a secure way for linked data systems to grant and express authority utilizing the object capability model. Our wallet capabilities are represented as linked data objects which are signed with Linked Data Proofs. LD Proofs represent the core technology of the way we share and exchange authentic data with others. - -### Profile Data Format - -Security Profiles are represented as a protobuf message that contains details about the connecting device to the remote cloud wallet. These are sensitive details that contain private key data, and must always be stored in a secure storage. The details of this data contract are expressed with this proto message. - -```proto -message WalletProfile { - google.protobuf.Struct did_document = 1; - string wallet_id = 2; - string invoker = 3; - string capability = 4; - bytes invoker_jwk = 5; -} -``` - -`did_document` -: contains the DID Document generated by the device that will be used to access the remote wallet. Each device/profile will have a unique DID Document. The DID method used in this document is `did:key`. - -`wallet_id` -: represents the remote wallet identifier that this profile has been granted access. - -`invoker` -: represents the specific key in the DID Document that was granted capability authorization. - -`capability` -: represents the unique identifier of the z-cap that the `invoker` is allowed to access. - -`invoker_jwk` -: represents the key of the invoker in JWK format. This key is already present in the DID Document, we simply store it here in JWK format for convenience. - ---- - -This profile is always stored in its binary form using the protobuf native serialization. A profile is created by using the [Create Wallet](/reference/services/wallet-service/#create-wallet) functionality in the SDK. - - - -## Configuration - -Trinsic SDK contains minimal configuration. This configuration is stored differently, depending on what package is used. - -### Configuration with CLI - -The CLI stores it's configuration in the user's home directory, typically in `~/.trinsic/`. This directory contains the main configuration file `config.toml` and all the profile data. - -### Show Configuration - -To print the current configuration file in the terminal use: - -```bash -trinsic config --show -``` - -Typical configuration file may look like this: - -```toml -[server] -address = "http://localhost:5000/" - -[profile] -default = "my_profile" -``` - -### Update Configuration Entry - -To change the configuration values, use the `config` subcommand with the attribute and it's value. - -```bash -trinsic config -``` - -The following attributes are currently supported: - -`server-address` -: Updates the default server address the CLI communicates - - ```bash - trinsic config --server-address https://example.com/ - ``` - -`profile-default` -: Updates the default profile used with the CLI - - ```bash - trinsic config --profile-default alice - ``` - -### Configuration with SDK - -When using the SDK in your code, you can pass parameters to the default service constructors and use the provided methods to set different active profiles. - -=== "TypeScript" - - ```typescript - import { WalletService } from '@trinsic/trinsic'; - - // Set the server address - const service = new WalletService("https://example.com"); - - // Create new profile or import an existing one - const myProfile = await service.createWallet(); - - // Set the profile to be used with authorization pipeline - service.setProfile(myProfile); - ``` - -=== "C#" - - ```csharp - using Trinsic; - - // Set the server address - var service = new WalletService("https://example.com"); - - // Create new profile or import an existing one - var myProfile = await service.CreateWallet(); - - // Set the profile to be used with authorization pipeline - service.SetProfile(myProfile); - ``` - diff --git a/docs/reference/setup/installation/install-net.md b/docs/reference/setup/installation/install-net.md deleted file mode 100644 index 0d1054813..000000000 --- a/docs/reference/setup/installation/install-net.md +++ /dev/null @@ -1,14 +0,0 @@ -Install the packages directly from [Nuget.org :material-open-in-new:](https://www.nuget.org/packages/Trinsic){target=_blank} - -=== "Package Manager" - ``` - PM> Install-Package Trinsic - ``` -=== ".NET CLI" - ``` - > dotnet add package Trinsic - ``` -=== "PackageReference" - ``` - - ``` diff --git a/docs/reference/setup/installation/install-node.md b/docs/reference/setup/installation/install-node.md deleted file mode 100644 index c3d00977d..000000000 --- a/docs/reference/setup/installation/install-node.md +++ /dev/null @@ -1,6 +0,0 @@ -Install the package for Node or Browser from [npmjs.com :material-open-in-new:](https://www.npmjs.com/package/@trinsic/trinsic){target=_blank} - -=== "Install" - ```bash - npm i @trinsic/trinsic - ``` \ No newline at end of file diff --git a/docs/ruby/index.md b/docs/ruby/index.md new file mode 100644 index 000000000..8baf6fe81 --- /dev/null +++ b/docs/ruby/index.md @@ -0,0 +1,13 @@ +# The Trinsic Ruby SDK + +The Trinsic Ruby SDK makes it easy to interact with the Trinsic API from any Ruby application. The most recent version of the library can be found on ____. You can find the SDKs source on [Github](https://github.com/trinsic-id/sdk/ruby). + +## Installation +TODO + +## Configuration +TODO + +## Next Steps +TODO + diff --git a/docs/snippets/buttons.md b/docs/snippets/buttons.md new file mode 100644 index 000000000..b7831ed99 --- /dev/null +++ b/docs/snippets/buttons.md @@ -0,0 +1 @@ +[:octicons-info-24: Learn More](#) \ No newline at end of file diff --git a/docs/walkthrough/snippets/intro-infrastructure.md b/docs/snippets/intro-infrastructure.md similarity index 100% rename from docs/walkthrough/snippets/intro-infrastructure.md rename to docs/snippets/intro-infrastructure.md diff --git a/docs/walkthrough/snippets/intro-use-case.md b/docs/snippets/intro-use-case.md similarity index 100% rename from docs/walkthrough/snippets/intro-use-case.md rename to docs/snippets/intro-use-case.md diff --git a/docs/support.md b/docs/support.md new file mode 100644 index 000000000..5228ca99a --- /dev/null +++ b/docs/support.md @@ -0,0 +1,7 @@ +# Have a Question? + +Normally, the best way to ask quick questions is through the [Trinsic Community slack channel](https://join.slack.com/t/trinsiccommunity/shared_invite/zt-pcsdy7kn-h4vtdPEpqQUlmirU8FFzSQ). + +If you have a bug to report, please report it on the Github issues on our SDK. Contributions and additions to this docs site are always welcome. + +Finally, if you're interested in getting in touch with the team for any other reason, contact us at [support@trinsic.id](mailto:support@trinsic.id). We treat any feedback as gold. diff --git a/docs/web/index.md b/docs/web/index.md new file mode 100644 index 000000000..6ec373ecd --- /dev/null +++ b/docs/web/index.md @@ -0,0 +1,23 @@ +# The Trinsic Javascript / Web SDK + +The Trinsic Web SDK makes it easy to interact with the Trinsic API from any client-side web application. The most recent version of the library can be found on ____. You can find the SDKs source on [Github](https://github.com/trinsic-id/sdk/web). + +## Installation +Install the package for Node or Browser from [npmjs.com :material-open-in-new:](https://www.npmjs.com/package/@trinsic/trinsic){target=_blank} + +=== "Install" + ```bash + npm i @trinsic/trinsic + ``` + +## Configuration +TODO + +## Next Steps + +Once the SDK is installed and configured, you're ready to start building! We recommend going through the [walkthrough](./vaccination-web.md) next. If you're ready to dive into building your ecosystem, check out our [API Reference](reference/index.md) + +[Start Walkthrough](./vaccination-web.md){ .md-button .md-button--primary } [Explore API](reference/index.md){ .md-button } + + + diff --git a/docs/walkthrough/vaccination-browser.md b/docs/web/vaccination-web.md similarity index 98% rename from docs/walkthrough/vaccination-browser.md rename to docs/web/vaccination-web.md index dde5bf97f..87b074b6c 100644 --- a/docs/walkthrough/vaccination-browser.md +++ b/docs/web/vaccination-web.md @@ -114,7 +114,7 @@ let allison = WalletProfile.deserializeBinary(localStorage.getItem("allison.bin" !!! note "Loading Profiles" In order to load a profile from a saved file you'll need to install google-protobuf with `npm i google-protobuf` in order to use the Struct class and convert the DID Document from JavaScript to the protobuf form. -Read more about [security profiles](../reference/setup/index.md/profiles) and authentication. +Read more about [security profiles](../reference/index.md/profiles) and authentication. ## Certificate issuance diff --git a/dotnet/Trinsic.Tests/Tests.cs b/dotnet/Trinsic.Tests/Tests.cs index 5efe9d786..3c64f7458 100644 --- a/dotnet/Trinsic.Tests/Tests.cs +++ b/dotnet/Trinsic.Tests/Tests.cs @@ -46,7 +46,7 @@ public void TestParseURL(string url, bool isValid) else Assert.NotNull(ServiceBase.CreateChannelIfNeeded(url)); } - + [Fact] public async Task TestWalletService() { @@ -102,5 +102,17 @@ public async Task TestWalletService() _testOutputHelper.WriteLine($"Verification result: {valid}"); Assert.True(valid); } + + // TODO - Create trust registry unit test and then add commands to documentation reference + [Fact] + public void TestTrustRegistry() + { + //Given + + //When + + //Then + } + } } \ No newline at end of file diff --git a/mkdocs.yml b/mkdocs.yml index f8408085e..fa15f1456 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -5,25 +5,38 @@ edit_uri: edit/main/docs/ repo_name: trinsic-id/sdk site_url: https://ecosystems-docs-alpha.trinsic.id nav: - - Overview: index.md - - Concepts: concepts/index.md - - Start Building: - - CLI: walkthrough/vaccination-cli.md - - Node: walkthrough/vaccination-node.md - - Web: walkthrough/vaccination-browser.md - - C#: walkthrough/vaccination-net.md - - Python: walkthrough/vaccination-python.md + - Welcome!: index.md + - Join the Beta: early-adopter.md + - Ask a Question: support.md + - Learn: + - Introduction: learn/index.md + - Wallets: learn/wallets.md + - Credentials: learn/credentials.md + - Passes: learn/passes.md + - Ecosystems: learn/ecosystems.md + # - Security: learn/security.md TODO + - Underlying Tech: learn/tech.md + - Build: + - Trinsic CLI: cli/index.md + - Node: node/index.md + - C#: dotnet/index.md + - Python: python/index.md + # - Ruby: ruby/index.md + # - Go: go/index.md + # - Java: java/index.md + # - Web: web/index.md + # - iOS: ios/index.md + # - Android: android/index.md - Reference: - - Setup: reference/setup/index.md + - Overview: reference/index.md - Wallet Service: reference/services/wallet-service.md - Provider Service: reference/services/provider-service.md - - Trust Registry: reference/services/trust-registry.md - - Support: - - Join Slack Community: https://join.slack.com/t/trinsiccommunity/shared_invite/zt-pcsdy7kn-h4vtdPEpqQUlmirU8FFzSQ - - Contribute on Github: https://github.com/trinsic-id - - Email us: mailto:support@trinsic.id - - What's Next: - - Join Trinsic Ecosystems: early-adopter.md + - Trust Registry Service: reference/services/trust-registry.md + - External Resources: + - Join the Community: https://join.slack.com/t/trinsiccommunity/shared_invite/zt-pcsdy7kn-h4vtdPEpqQUlmirU8FFzSQ + # - Roadmap: roadmap.md TODO + # - Changelog: changelog.md TODO + - Github: https://github.com/trinsic-id theme: name: material logo: _static/logo-title.svg @@ -72,7 +85,7 @@ markdown_extensions: - pymdownx.details - toc: permalink: true - toc_depth: 2 + toc_depth: 3 - abbr extra_javascript: