Skip to content

Commit

Permalink
Added eID & Visa Credentials
Browse files Browse the repository at this point in the history
  • Loading branch information
dinkar-jain committed May 31, 2024
1 parent 02e3374 commit d9cf258
Show file tree
Hide file tree
Showing 2 changed files with 128 additions and 0 deletions.
69 changes: 69 additions & 0 deletions src/content/1.credentials/Visa.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,69 @@
# Visa

```json
{
"@context": ["https://www.w3.org/2018/credentials/v1"],
"type": ["VerifiableCredential", "VerifiableAttestation", "Visa"],
"id": "did:visa:987654321abcdef",
"credentialSubject": {
"id": "",
"firstName": "John",
"lastName": "Doe",
"passportNumber": "G7F2A04F7O",
"dateOfBirth": "1980-01-01",
"gender": "Male",
"nationality": "US",
"visaType": "Tourist",
"entryNumber": "Single",
"visaValidity": {
"start": "2024-01-01",
"end": "2024-06-30"
},
"purposeOfVisit": "Tourism"
},
"issuer": {
"id": "did:key:z3MkpTHsHjxvqq7TnqmBnYf6pWZpa27DqXx6Wp7dVPLm987X",
"name": "Embassy of Wonderland"
},
"issuanceDate": "2023-11-01T00:00:00Z",
"validFrom": "2024-01-01T00:00:00Z",
"expirationDate": "2024-06-30T00:00:00Z"
}
```

## Manifest

```json
{
"claims": {
"Passport Number": "$.credentialSubject.passportNumber",
"Name": "$.credentialSubject.firstName",
"Last Name": "$.credentialSubject.lastName",
"Date of Birth": "$.credentialSubject.dateOfBirth",
"Gender": "$.credentialSubject.gender",
"Nationality": "$.credentialSubject.nationality",
"Visa Type": "$.credentialSubject.visaType",
"Entry Number": "$.credentialSubject.entryNumber",
"Visa Issuance Date": "$.credentialSubject.visaValidity.start",
"Visa Expiration Date": "$.credentialSubject.visaValidity.end",
"Purpose of Visit": "$.credentialSubject.purposeOfVisit"
}
}
```

## Mapping example

```json
{
"id": "<uuid>",
"issuer": {
"id": "<issuerDid>"
},
"credentialSubject": {
"id": "<subjectDid>"
},
"issuanceDate": "<timestamp>",
"validFrom": "<timestamp>",
"expirationDate": "<timestamp-in:365d>",
}
```
59 changes: 59 additions & 0 deletions src/content/1.credentials/eID.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
# eID

```json
{
"@context": ["https://www.w3.org/2018/credentials/v1"],
"type": ["VerifiableCredential", "VerifiableAttestation", "eID"],
"id": "",
"credentialSubject": {
"id": "",
"firstName": "John",
"lastName": "Doe",
"dateOfBirth": "1980-01-01",
"gender": "Male",
"nationality": "US",
"address": "123 Main St, Anytown, USA",
"documentId": "G7F2A04F7O"
},
"issuer": {
"id": "did:key:z6MkrHKzgsahxBLyNAbLQyB1pcWNYC9GmywiWPgkrvntAZcj",
"name": "Government of Anytown"
},
"issuanceDate": "2021-08-31T00:00:00Z",
"validFrom": "2021-09-01T00:00:00Z",
"expirationDate": "2031-08-31T00:00:00Z"
}
```

## Manifest

```json
{
"claims": {
"Document ID": "$.credentialSubject.documentId",
"Name": "$.credentialSubject.firstName",
"Last Name": "$.credentialSubject.lastName",
"Date of Birth": "$.credentialSubject.dateOfBirth",
"Gender": "$.credentialSubject.gender",
"Nationality": "$.credentialSubject.nationality",
"Address": "$.credentialSubject.address",
}
}
```

## Mapping example

```json
{
"id": "<uuid>",
"issuer": {
"id": "<issuerDid>"
},
"credentialSubject": {
"id": "<subjectDid>"
},
"issuanceDate": "<timestamp>",
"validFrom": "<timestamp>",
"expirationDate": "<timestamp-in:365d>",
}
```

0 comments on commit d9cf258

Please sign in to comment.