Skip to content

Commit

Permalink
Merge pull request #156 from 0xPolygonID/format-docs
Browse files Browse the repository at this point in the history
Format docs
  • Loading branch information
amonsosanz authored May 13, 2024
2 parents 592fa76 + d9eef5d commit 47f0584
Show file tree
Hide file tree
Showing 19 changed files with 333 additions and 354 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ The error you're experiencing is typically due to an incorrect configuration of
To resolve this issue, check your `.env-issuer` file for the `ISSUER_CREDENTIAL_STATUS_RHS_MODE` value. If it is set to `OffChain`, you must specify a valid Reverse Hash Service Endpoint in `ISSUER_CREDENTIAL_STATUS_RHS_URL`. For example, you could use our staging RHS: `https://rhs-staging.polygonid.me/`.

If your `ISSUER_CREDENTIAL_STATUS_RHS_MODE` is configured for on-chain operation, ensure you have the correct smart contract information for your network, such as Amoy:

- `ISSUER_CREDENTIAL_STATUS_ONCHAIN_TREE_STORE_SUPPORTED_CONTRACT`=0x3d3763eC0a50CE1AdF83d0b5D99FBE0e3fEB43fb
- `ISSUER_CREDENTIAL_STATUS_RHS_CHAIN_ID`=80002

Expand All @@ -34,4 +35,5 @@ For a comprehensive understanding and configuration guidance, please review the
Wrong answer:

Simply replace the RHS URL with the Issuer Node URL or remove the `ISSUER_CREDENTIAL_STATUS_RHS_URL` from your .env-issuer file without adjusting the `ISSUER_CREDENTIAL_STATUS_RHS_MODE` setting or ensuring the RHS endpoint's validity.

</div>
1 change: 1 addition & 0 deletions docs/faqs/content/issuer-node-reusing-issuer-did.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,4 +22,5 @@ If you **have not deleted the database** and wish to reuse a previously configur
Wrong answer:

If you want to reuse a previously used DID, it's sufficient to manually edit the database entries to reflect the old DID, bypassing the need to update environment files or restart any services. This direct database manipulation ensures immediate reuse of the DID without considering system synchronization or security implications.

</div>
4 changes: 2 additions & 2 deletions docs/issuer-node/install-kubernetes.md
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ export ISSUERNAME="My Issuer"
export ISSUER_ETHERUM_URL="https://polygon-network.XXXX"
export INGRESS_ENABLED=true
export VAULT_PWD=password
export RHS_MODE=None
export RHS_MODE=None
export RHS_URL="https://reverse-hash-service.com"
```

Expand Down Expand Up @@ -142,7 +142,7 @@ export ISSUERNAME="My Issuer"
export ISSUER_ETHERUM_URL="https://polygon-network.XXXX"
export INGRESS_ENABLED=false
export VAULT_PWD=password
export RHS_MODE=None
export RHS_MODE=None
export RHS_URL="https://reverse-hash-service.com"
```

Expand Down
6 changes: 1 addition & 5 deletions docs/issuer/issuer-configuration.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ import TabItem from '@theme/TabItem';
This guide will show you how to configure your Issuer Node.

:::caution
*Polygon Mumbai testnet has been deprecated
\*Polygon Mumbai testnet has been deprecated
:::

## Revocation Status
Expand Down Expand Up @@ -89,7 +89,6 @@ ISSUER_CREDENTIAL_STATUS_RHS_CHAIN_ID=80002

</TabItem>


<TabItem value="Polygon Main">

```bash
Expand Down Expand Up @@ -173,7 +172,6 @@ ISSUER_API_IDENTITY_METHOD={polygonid | custom method}

</TabItem>


<TabItem value="Polygon Main">

```bash
Expand Down Expand Up @@ -237,7 +235,6 @@ Create Identity Payload example:

</TabItem>


<TabItem value="Polygon Main">

```json
Expand All @@ -253,7 +250,6 @@ Create Identity Payload example:

</TabItem>


<TabItem value="Polygon Mumbai*">

```json
Expand Down
41 changes: 18 additions & 23 deletions docs/issuer/on-chain-issuer/on-chain-tutorial.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,30 +55,25 @@ There are two main components in this application:
1. Deploy an on-chain merklized issuer contract. You can use [this sample](https://github.com/0xPolygonID/contracts/blob/main/contracts/examples/IdentityExample.sol) or create your own smart contract with custom logic.

Clone smart contracts repository:

```bash
git clone https://github.com/0xPolygonID/contracts.git
```

Deploy Identity Example contract:

```bash
export AMOY_PRIVATE_KEY={private_key} && \
export AMOY_RPC_URL={rpc_url} && \
npx hardhat run scripts/deployIdentityExample.ts --network amoy
```



:::note

You can find more information on how to deploy a smart contract using Hardhat [<ins>in this readme</ins>](https://github.com/iden3/contracts#readme).

:::







1. Use the utility to calculate the issuerDID from the smart contract address:

```bash
Expand All @@ -97,23 +92,23 @@ You can find more information on how to deploy a smart contract using Hardhat [<

<TabItem value="Polygon Amoy">

```bash
SUPPORTED_RPC="80002=<RPC_POLYGON_AMOY>"
ISSUERS_PRIVATE_KEY="<ISSUER_DID>=<PRIVATE_KEY_OF_THE_CONTRACT_DEPLOYER>"
EXTERNAL_HOST="<NGROK_URL>"
SUPPORTED_STATE_CONTRACTS="80002=0x1a4cC30f2aA0377b0c3bc9848766D90cb4404124"
```
```bash
SUPPORTED_RPC="80002=<RPC_POLYGON_AMOY>"
ISSUERS_PRIVATE_KEY="<ISSUER_DID>=<PRIVATE_KEY_OF_THE_CONTRACT_DEPLOYER>"
EXTERNAL_HOST="<NGROK_URL>"
SUPPORTED_STATE_CONTRACTS="80002=0x1a4cC30f2aA0377b0c3bc9848766D90cb4404124"
```

</TabItem>

<TabItem value="Polygon Main">

```bash
SUPPORTED_RPC="137=<RPC_POLYGON_MAIN>"
ISSUERS_PRIVATE_KEY="<ISSUER_DID>=<PRIVATE_KEY_OF_THE_CONTRACT_DEPLOYER>"
EXTERNAL_HOST="<NGROK_URL>"
SUPPORTED_STATE_CONTRACTS="137=0x624ce98D2d27b20b8f8d521723Df8fC4db71D79D"
```
```bash
SUPPORTED_RPC="137=<RPC_POLYGON_MAIN>"
ISSUERS_PRIVATE_KEY="<ISSUER_DID>=<PRIVATE_KEY_OF_THE_CONTRACT_DEPLOYER>"
EXTERNAL_HOST="<NGROK_URL>"
SUPPORTED_STATE_CONTRACTS="137=0x624ce98D2d27b20b8f8d521723Df8fC4db71D79D"
```

</TabItem>
</Tabs>
Expand Down Expand Up @@ -192,7 +187,7 @@ You can use already deployed demo: https://onchain-merklized-issuer-demo.polygon
1. Visit the [Query builder website](https://schema-builder.polygonid.me/query-builder/).
2. You now need to define the query.
2. You now need to define the query.
- **URL**: https://gist.githubusercontent.com/ilya-korotya/b06baa37453ed9aedfcb79100b84d51f/raw/balance-v1.jsonld
- **Schema type**: BalanceCredential
Expand All @@ -211,14 +206,14 @@ You can use already deployed demo: https://onchain-merklized-issuer-demo.polygon
<img width="300" src="/img/onchain-issuer-12.jpg"></img>
</div>
4. Click on Approve. After which, the process of generating the proof is starts:
<div align="center">
<img width="300" src="/img/onchain-issuer-13.jpg"></img>
</div>
5.Finally, the proof is generated. The verifier will check the revocation status and some additional information. The proof is then sent and validated by the verifier. You will receive the following response on the Query builder website
<div align="center">
<img width="600" src="/img/onchain-issuer-14.png"></img>
</div>
</div>
1 change: 1 addition & 0 deletions docs/issuer/refresh-service/customization.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ import useBaseUrl from '@docusaurus/useBaseUrl';

Extend customization by incorporating custom providers and integrating them into the refresh flow.
This is the easiest way to add custom business logic to retrieve data from a data provider. Go to [setup guide](/docs/issuer/refresh-service/setup-guide/#setup-with-custom-data-provider) for more information

## 2. Flexible HTTP package

Utilize the [flexible HTTP package](https://github.com/0xPolygonID/refresh-service/blob/main/providers/flexiblehttp/http.go) to configure HTTP requests to a data provider. Refer to the [configuration guide](https://github.com/0xPolygonID/refresh-service/blob/main/README.md) for instructions on how to set this up.
Expand Down
Loading

0 comments on commit 47f0584

Please sign in to comment.