Skip to content

Commit 6d1568e

Browse files
[INJIMOB-3694] docs: clarify claim169 qr data is from credential (#2242)
Signed-off-by: KiruthikaJeyashankar <kiruthikavjshankar@gmail.com>
1 parent 024f667 commit 6d1568e

1 file changed

Lines changed: 21 additions & 12 deletions

File tree

docs/claim-169-support.md

Lines changed: 21 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -12,23 +12,23 @@
1212

1313
## Pre-requisites
1414

15-
- VC should be valid and should contain claim 169 QR code data in the expected format. For e.g. for JSON-LD VC, claim 169 QR code data should be present in the `credentialSubject` section of the VC with the key `claim169`.
15+
- VC should be valid and should contain Claim 169 QR code data in the binary format. For e.g. for JSON-LD VC, Claim 169 QR code data should be present in the `credentialSubject` section of the VC with the key `claim169`.
1616

1717
```json
18-
"claim169": {
18+
"claim169" : {
1919
"identityQRCode": "NCF4:OCFBI%S:2EQ7NMC2558J6HW8VDQ0DW8V27MMSLYG%8WTGTEF9-8G7K6A5S+ORSWH4%F12802...",
2020
"faceQRCode": "NCF4:OCFBI%S:2EQ7NMC2558J6HW8VDQ0DW8V27MMSLYG%8WTSJSJGTEF9-8G7K6A5S+ORSWH4%F12802..."
2121
}
2222
```
2323

24-
- The claim 169 QR code data should be in the expected format as per the requirements of the application consuming it. Refer [Claim 169 QR Code specification](https://docs.mosip.io/1.2.0/readme/standards-and-specifications/mosip-standards/169-qr-code-specification) for further details.
24+
- The Claim 169 QR code data should be in the expected format as per the requirements of the application consuming it. Refer [Claim 169 QR Code specification](https://docs.mosip.io/1.2.0/readme/standards-and-specifications/mosip-standards/169-qr-code-specification) for further details.
2525

2626
## Credential Detail view - with Claim 169 QR code support
2727

2828
### Actors Involved
2929

3030
- **User**: The individual who holds the Verifiable Credential and interacts with the Inji Wallet to view the credential details.
31-
- **Wallet**: The application that displays the credential details to the user, including the claim 169 QR code if present.
31+
- **Wallet**: The application that displays the credential details to the user, including the Claim 169 QR code if present.
3232

3333
```mermaid
3434
sequenceDiagram
@@ -38,12 +38,21 @@ sequenceDiagram
3838
Note over user,wallet: Credential already downloaded and stored in wallet
3939
4040
user->>wallet: Opens credential detail view
41-
wallet->>wallet: Retrieves credential from local storage
42-
wallet->>wallet: Checks for claim 169 QR code data
43-
alt claim 169 QR code data is present
44-
wallet->>user: Displays credential with claim 169 QR code
45-
else claim 169 QR code data is not present
46-
wallet->>wallet: Generates QR code using Pixelpass library
47-
wallet->>user: Displays credential with Pixelpass QR code
48-
end
41+
wallet->>wallet: Retrieves credential from app storage
42+
wallet->>wallet: Checks for Claim 169 QR code data<br/>Is `claim169` key present in `credentialSubject` of credential data?
43+
alt Claim 169 QR code data is present
44+
wallet->>wallet: Create QR code using Claim 169 QR code data<br/> in the credential
45+
wallet->>user: Displays credential with Claim 169 QR code
46+
else Claim 169 QR code data is not present
47+
wallet->>wallet: Generates QR code using Pixelpass library
48+
wallet->>user: Displays credential with Pixelpass QR code
49+
end
4950
```
51+
52+
**Detailed Flow:**
53+
54+
- The Wallet checks if the `claim169` key is present in the `credentialSubject` of the credential data
55+
- If present, the Wallet validates that the Claim 169 data is a non-empty string
56+
- The Wallet selects the first QR code data available in the `claim169` object by using the first key (e.g., `identityQRCode`)
57+
- The QR data is converted to QR format and displayed to the user in the credential detail view
58+
- If the `claim169` key is not present, the wallet falls back to generating a QR code using the Pixelpass library and displays it to the user

0 commit comments

Comments
 (0)