prepareCredentialRequests
Prepares the credential requests the access token of tokenResponse grants for the credentials of credentialFormats, each with the configuration its proof and response depend on, still without proofs and encryption. Create each request with its own c_nonce right before sending it with OpenId4VciProtocolClient.credentialRequest, which adds the access token from tokenResponse and, for DPoP-bound tokens, the DPoP proof, and parses the response.
Fails if the token grants none of credentialFormats.
Parameters
from the authorization server token endpoint
the issuer's metadata, see IssuerMetadata
which credentials to request, picked out of IssuerMetadata.supportedCredentialConfigurations
the scope value requested in the token request, since the authorization server may not set it in tokenResponse
Prepares the credential requests the access token of tokenResponse grants for all its credentials, each with the configuration its proof and response depend on, still without proofs and encryption. Create each request with its own c_nonce right before sending it with OpenId4VciProtocolClient.credentialRequest, which adds the access token from tokenResponse and, for DPoP-bound tokens, the DPoP proof, and parses the response.
Parameters
from the authorization server token endpoint
the issuer's metadata, see IssuerMetadata
the scope value requested in the token request, since the authorization server may not set it in tokenResponse
Prepares one credential request per entry of credentialConfigurationIds, each with its configuration from IssuerMetadata.supportedCredentialConfigurations of metadata, still without proofs and encryption, see createCredential.
Only use this when the token response contained no credential_identifiers in its authorization_details, because then the requests have to use those, and credential_configuration_id "MUST NOT be present" (OpenID4VCI 1.0, 8.2). Otherwise, use the overload accepting TokenResponseParameters.
Fails for an identifier that metadata does not list.
Parameters
the exact credential_configuration_ids to request, keys of IssuerMetadata.supportedCredentialConfigurations
the issuer's metadata, see IssuerMetadata