Class CredentialSingleIssueRequest
- java.lang.Object
-
- com.authlete.common.dto.CredentialSingleIssueRequest
-
- All Implemented Interfaces:
Serializable
public class CredentialSingleIssueRequest extends Object implements Serializable
A request to Authlete's/vci/single/issueAPI.The Authlete API is supposed to be called by the implementation of the credential endpoint. The endpoint is defined in the "OpenID for Verifiable Credential Issuance 1.0" (OID4VCI) specification.
The implementation of the credential endpoint is expected to call the following Authlete APIs in the order.
/auth/introspection/vci/single/parse/vci/single/issue
The role of the
/vci/single/issueAPI is to issue a credential or a transaction ID and to prepare a response that should be returned from the credential endpoint.- Since:
- 3.67, Authlete 3.0
- See Also:
- OpenID for Verifiable Credential Issuance 1.0, Serialized Form
-
-
Constructor Summary
Constructors Constructor Description CredentialSingleIssueRequest()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description StringgetAccessToken()Get the access token that was presented at the credential endpoint.intgetInterval()Get the minimum amount of time in seconds that the Wallet SHOULD wait after receiving the response before sending a new request to the Deferred Credential Endpoint.CredentialIssuanceOrdergetOrder()Get the credential order that provides an instruction for issuing a credential.booleanisDenied()Get the flag that indicates whether to deny the credential request.CredentialSingleIssueRequestsetAccessToken(String accessToken)Set the access token that was presented at the credential endpoint.CredentialSingleIssueRequestsetDenied(boolean denied)Set the flag that indicates whether to deny the credential request.CredentialSingleIssueRequestsetInterval(int interval)Set the minimum amount of time in seconds that the Wallet SHOULD wait after receiving the response before sending a new request to the Deferred Credential Endpoint.CredentialSingleIssueRequestsetOrder(CredentialIssuanceOrder order)Set the credential order that provides an instruction for issuing a credential.
-
-
-
Method Detail
-
getAccessToken
public String getAccessToken()
Get the access token that was presented at the credential endpoint.- Returns:
- The access token that was presented at the credential endpoint.
-
setAccessToken
public CredentialSingleIssueRequest setAccessToken(String accessToken)
Set the access token that was presented at the credential endpoint.- Parameters:
accessToken- The access token that was presented at the credential endpoint.- Returns:
thisobject.
-
getOrder
public CredentialIssuanceOrder getOrder()
Get the credential order that provides an instruction for issuing a credential.- Returns:
- The instruction for credential issuance.
-
setOrder
public CredentialSingleIssueRequest setOrder(CredentialIssuanceOrder order)
Set the credential order that provides an instruction for issuing a credential.- Parameters:
order- The instruction for credential issuance.- Returns:
thisobject.
-
isDenied
public boolean isDenied()
Get the flag that indicates whether to deny the credential request.If this parameter is set to
true, the response content prepared by Authlete will contain"error":"credential_request_denied"like below.{ "error": "credential_request_denied" }Note that the
credential_request_deniederror code does not exist in OID4VCI 1.0 ID1.- Returns:
truefor generating a response content containing"error":"credential_request_denied".- Since:
- 4.35, Authlete 3.0.25
-
setDenied
public CredentialSingleIssueRequest setDenied(boolean denied)
Set the flag that indicates whether to deny the credential request.If this parameter is set to
true, the response content prepared by Authlete will contain"error":"credential_request_denied"like below.{ "error": "credential_request_denied" }Note that the
credential_request_deniederror code does not exist in OID4VCI 1.0 ID1.- Parameters:
denied-truefor generating a response content containing"error":"credential_request_denied".- Returns:
thisobject.- Since:
- 4.35, Authlete 3.0.25
-
getInterval
public int getInterval()
Get the minimum amount of time in seconds that the Wallet SHOULD wait after receiving the response before sending a new request to the Deferred Credential Endpoint.The value of this parameter is used as the value of the
intervalparameter in the credential response. However, theintervalparameter is included in the credential response only when the following conditions are met:-
The value of the
order.issuanceDeferredrequest parameter istrue. -
The version of the OID4VCI specification is 1.0-Final or later (that is,
the
oid4vciVersionproperty ofServiceis set and its value is not"1.0-ID1").
- Returns:
- The minimum amount of time in seconds that the Wallet SHOULD wait after receiving the response before sending a new request to the Deferred Credential Endpoint.
- Since:
- 4.35, Authlete 3.0.25
-
The value of the
-
setInterval
public CredentialSingleIssueRequest setInterval(int interval)
Set the minimum amount of time in seconds that the Wallet SHOULD wait after receiving the response before sending a new request to the Deferred Credential Endpoint.The value of this parameter is used as the value of the
intervalparameter in the credential response. However, theintervalparameter is included in the credential response only when the following conditions are met:-
The value of the
order.issuanceDeferredrequest parameter istrue. -
The version of the OID4VCI specification is 1.0-Final or later (that is,
the
oid4vciVersionproperty ofServiceis set and its value is not"1.0-ID1").
- Parameters:
interval- The minimum amount of time in seconds that the Wallet SHOULD wait after receiving the response before sending a new request to the Deferred Credential Endpoint.- Returns:
thisobject.- Since:
- 4.35, Authlete 3.0.25
-
The value of the
-
-