Claim specific credential. User has to pass authorization token in header and data in request body.authorization
header has to contain Bearer
and token returned from previous token endpoint.
In request body user has to pass types
array with type of credential being claimed, format
string with format of the credential,
and proof
object with proof_type
string and jwt
string. proof_type
is a string that represents the type of the proof, which is in our case jwt
.jwt
is a string that represents the JWT token which is generated by wallet and acts as a proof of posession JWT. If successful, the server returns
an object with credential
, format
, c_nonce
and c_nonce_expires_in
properties. credential
is a string that represents the JWT token which contains
all the details about the claimed credential. format
is a string that represents the format of the credential. c_nonce
is a string that
represents c-nonce and c_nonce_expires_in
is a number that represents the expiration time of the c-nonce in seconds.
If the API is NOT running in DEMO MODE, note that the resources must be creating using POST /private/credential-offers otherwise it will return errors
Defines a organisation which is defined as a correlationId. Must be a value the Issuer is working with!
nchain
Authorization retrieved from token endpoint
The format of the credential we choose when issuing.
jwt_vc_json
Credential definition metadata
Credential proof
Before claiming the credential, the user has to get an access token. This endpoint facilitates the retrieval
of an access token with the provided client_id
, grant_type
and pre-authorized_code
. The client_id
is
a string that represents the client ID. The grant_type
is a string that represents the grant type, which is in our caseurn:ietf:params:oauth:grant-type:pre-authorized_code
. The pre-authorized_code
is a string that represents the pre-authorized code,
which is generated by the web client when creating an offer. If successful, the server returns an object with access_token
, token_type
,expires_in
, c_nonce
, c_nonce_expires_in
, authorization_pending
and interval
properties. access_token
is a string that represents
the access token. token_type
is a string that represents the token type (bearer in our case). expires_in
is a number that represents the
expiration time of the token in seconds. c_nonce
is a string that represents the c-nonce. c_nonce_expires_in
is a number that represents
the expiration time of the c-nonce in seconds. authorization_pending
is a boolean that indicates if the authorization is pending
(not used in our case). interval
is a number that represents the interval in milliseconds.
If the API is NOT running in DEMO MODE, note that the resources must be creating using POST /private/credential-offers otherwise it will return errors
Defines a organisation which is defined as a correlationId. Must be a value the Issuer is working with!
nchain
The client ID.
nChain:vc-wallet
The grant type to use
urn:ietf:params:oauth:grant-type:pre-authorized_code
Pre Authorized code that references the credential to start token fetching
ab407be3-d18f-4508-837e-6286329c1da2