Skip to content

Commit

Permalink
docs: add basics
Browse files Browse the repository at this point in the history
  • Loading branch information
andrea-dintino committed Dec 12, 2024
1 parent 18bbd3c commit a501ebf
Show file tree
Hide file tree
Showing 2 changed files with 55 additions and 9 deletions.
64 changes: 55 additions & 9 deletions docs/guides/Flows/basics.md
Original file line number Diff line number Diff line change
@@ -1,26 +1,72 @@
---
title: 🧩 Basics
title: Basics
order: 10
---

# The basics

Here we explain the *Basics* on how the Credential Issuance and Verification flow, defining the basic concepts and components you will work with.

# Templates
## Templates

The templates contain the core logic that govern the issuance and verification flows.

# Microservices
- **What is a template?**
> [!IMPORTANT]
> Templates contain (re-usable) business logic for issuance and verification flow. Templates are scripted in *Zencode* executed by Zenroom and Slangroom, check the [🏗️ Core Technologies](/core-technologies) to know more.
- **Where and how do I use a template?**

Templates are used in *issuance Flows* and *Verification Flows*. When editing a flow, you can select the desired template from a dropdown.

# Flows
- **How do edit a template?**
Inside the Template editor, in the DIDroom Dashboard. If you want to test the code, you may want to use the [Slangroom editor](https://dyne.org/slangroom/) or [Apiroom](https://apiroom.net/).

- **Where are templates executed?**
Depending if it's an *Authorization*, *Issuance* or *Verification*, the templates are executed inside a Microservice, inside the Wallet or inside the Verifier App [more about this later].


# Toolchains
## Issuance and Verification Flows

## Zenroom
Flows define the full behaviour of credential issuance and verification. While the Template define the Flow's core business logic, you define in the Flow parameters such as the duration of a credential, the cryptography and protocols to be used, the Microservices it should run on, as well as the data that is visible by the user (name, description, logo) as well as the machine-readable data used in the communication protocols (e.g. OpenID4VCI and OpenID4VP).

## Slangroom
- **TLDR: what is actually Flow in DIDroom?**
> [!NOTE]
> Imagine a Flow as a shell of extra parameters that surround a template. Imagine that you are offering the same credentials, once with a 1 day expiration and once with a 1 month expiration: the templates used will typically be the same, while the Flow configurations will change.

# Extendability

## Microservices

Credential Issuance and Verification are (partly) executed in Microservices. The Microservices are configured in the Dashboard, the Dashboard also provides you with the actuall Microservices code, with different deployment possibilities.


## Toolchain and components

The Issuance and Verification is implemented using our in-house built components, including:

- NCR (no-code room): REST API server for Zencode scripts, single binary, doesn't require su privildges, includes OpenAPI and automagic GUI for REST APIs see

-> Repo: https://github.com/ForkbombEu/ncr

- DIDroom Microservices: OpenID4VCI and OpenID4VP compatible Microservices, highly customizable, implemented in Zencode (with some JS). This is where the server-side of new protocols and new cryptography is implemented.

-> Repo: https://github.com/ForkbombEu/DIDroom_microservices

- Zencode client: all the Zencode needed in the Wallet, Verifier and in the Dashboard. This is where the client-side of new protocols and new cryptography is implemented.

-> Repo: https://github.com/ForkbombEu/client_zencode

- Ghisa: minimalist 0-security proxy, saves you from (some) CORS errors.

-> Repo: https://github.com/ForkbombEu/ghisa


- Zenroom: Cryptographic virtual machine, powers all (almost) the cryptogrphy in DIDroom. Ultra portable, runs on server/mobile/browser/IoT.

-> Repo: https://dev.zenroom.org/

- Slangroom: Extension to Zenroom, for networking, database, file management. See:

-> Repo: https://dyne.org/slangroom/


Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit a501ebf

Please sign in to comment.