Add proof to verifiable credential
Create an HTTP endpoint that will accept Verifiable Credential and will add Proof signature value.
The request may optionally include which key must be used for signing; if a key is missing, then a default pre-configured one should be used by the signer service.
Example request:
POST /v1/credential/proof?key=key1
{
"@context": [
"https://www.w3.org/2018/credentials/v1",
],
"type": ["VerifiableCredential"],
"issuer": "DID of the OCM",
"issuanceDate": "2010-01-01T19:23:24Z",
"credentialSubject": {
"hello":"world"
}
}
Example response:
{
"@context": [
"https://www.w3.org/2018/credentials/v1",
],
"type": ["VerifiableCredential"],
"issuer": "DID of the OCM",
"issuanceDate": "2010-01-01T19:23:24Z",
"credentialSubject": {
"hello":"world"
},
"proof": [
{
"type": "Ed25519Signature2018",
"created": "2020-04-10T21:35:35Z",
"verificationMethod": "https://address.com/key1",
"proofValue": "..."
}
]
}
Edited by Lyuben Penkovski