Issue credential #569
-
Trying to issue a credential. https://github.com/BROKLab/auth-bot/blob/veramo/src/network/veramo.service.ts#L95 On agent.keyManagerSignJWT() i get Error thrown "credentialSubject must not be empty" but i dont see anything about crendentialSubject in the types. Am i doing this wrong? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
I suspect that the error is coming from the Using your example, perhaps the credentialSubject: {
id: subjectDidId,
...data
}, Take a look at the example in this other discussion: #571 (comment) too. Please note that |
Beta Was this translation helpful? Give feedback.
I suspect that the error is coming from the
createVerifiableCredential()
callIt is expecting that
credentialSubject
should have someclaims
(other properties besideid
)Using your example, perhaps the
data
parameter is intended to contain the claims, in which case it would look something like this:Take a look at the example in this other discussion: #571 (comment) too.
Please note that
createVerifiableCredential()
internally callskeyManagerSign
. You don't have to call it on your own unless you need a JWS signature for other purposes.