IO Wallet SDK
    Preparing search index...
    • Resolves a credential offer from a URI or inline JSON string.

      This function handles multiple input formats:

      • URI with inline offer (by value): The credential offer JSON is embedded in the URI as a URL-encoded parameter
      • URI with reference (by reference): The URI points to a remote endpoint where the credential offer can be fetched
      • Direct JSON string: The credential offer is provided as a plain JSON string

      Supported URI schemes:

      • openid-credential-offer:// - Standard OpenID scheme
      • haip-vci:// - High Assurance Interoperability Profile scheme
      • https:// - HTTPS Universal Links (preferred)

      The configured IT-Wallet version selects the schema used to parse the offer:

      • v1.3 requires scope within the authorization_code grant
      • v1.4 no longer carries scope

      Parameters

      Returns Promise<
          {
              credential_configuration_ids: string[];
              credential_issuer: string;
              grants: {
                  authorization_code: {
                      authorization_server?: string;
                      issuer_state?: string;
                      scope: string;
                  };
              };
          },
      >

      Resolved and validated credential offer object

      If parsing fails, HTTP request fails, or validation fails

      If the configured version does not support credential offers

      const offer = await resolveCredentialOffer({
      config,
      credentialOffer: "openid-credential-offer://?credential_offer=%7B%22credential_issuer%22%3A...",
      callbacks: { fetch }
      });
      console.log(offer.credential_issuer);
      const offer = await resolveCredentialOffer({
      config,
      credentialOffer: "openid-credential-offer://?credential_offer_uri=https://issuer.example.com/offers/123",
      callbacks: { fetch }
      });
      console.log(offer.grants.authorization_code.issuer_state);
      const offerJson = '{"credential_issuer":"https://issuer.example.com","credential_configuration_ids":["UniversityDegree"],"grants":{"authorization_code":{"scope":"openid"}}}';
      const offer = await resolveCredentialOffer({
      config,
      credentialOffer: offerJson,
      callbacks: { fetch }
      });
    • Resolves a credential offer from a URI or inline JSON string.

      This function handles multiple input formats:

      • URI with inline offer (by value): The credential offer JSON is embedded in the URI as a URL-encoded parameter
      • URI with reference (by reference): The URI points to a remote endpoint where the credential offer can be fetched
      • Direct JSON string: The credential offer is provided as a plain JSON string

      Supported URI schemes:

      • openid-credential-offer:// - Standard OpenID scheme
      • haip-vci:// - High Assurance Interoperability Profile scheme
      • https:// - HTTPS Universal Links (preferred)

      The configured IT-Wallet version selects the schema used to parse the offer:

      • v1.3 requires scope within the authorization_code grant
      • v1.4 no longer carries scope

      Parameters

      Returns Promise<
          {
              credential_configuration_ids: string[];
              credential_issuer: string;
              grants: {
                  authorization_code: {
                      authorization_server?: string;
                      issuer_state?: string;
                  };
              };
          },
      >

      Resolved and validated credential offer object

      If parsing fails, HTTP request fails, or validation fails

      If the configured version does not support credential offers

      const offer = await resolveCredentialOffer({
      config,
      credentialOffer: "openid-credential-offer://?credential_offer=%7B%22credential_issuer%22%3A...",
      callbacks: { fetch }
      });
      console.log(offer.credential_issuer);
      const offer = await resolveCredentialOffer({
      config,
      credentialOffer: "openid-credential-offer://?credential_offer_uri=https://issuer.example.com/offers/123",
      callbacks: { fetch }
      });
      console.log(offer.grants.authorization_code.issuer_state);
      const offerJson = '{"credential_issuer":"https://issuer.example.com","credential_configuration_ids":["UniversityDegree"],"grants":{"authorization_code":{"scope":"openid"}}}';
      const offer = await resolveCredentialOffer({
      config,
      credentialOffer: offerJson,
      callbacks: { fetch }
      });
    • Resolves a credential offer from a URI or inline JSON string.

      This function handles multiple input formats:

      • URI with inline offer (by value): The credential offer JSON is embedded in the URI as a URL-encoded parameter
      • URI with reference (by reference): The URI points to a remote endpoint where the credential offer can be fetched
      • Direct JSON string: The credential offer is provided as a plain JSON string

      Supported URI schemes:

      • openid-credential-offer:// - Standard OpenID scheme
      • haip-vci:// - High Assurance Interoperability Profile scheme
      • https:// - HTTPS Universal Links (preferred)

      The configured IT-Wallet version selects the schema used to parse the offer:

      • v1.3 requires scope within the authorization_code grant
      • v1.4 no longer carries scope

      Parameters

      Returns Promise<CredentialOffer>

      Resolved and validated credential offer object

      If parsing fails, HTTP request fails, or validation fails

      If the configured version does not support credential offers

      const offer = await resolveCredentialOffer({
      config,
      credentialOffer: "openid-credential-offer://?credential_offer=%7B%22credential_issuer%22%3A...",
      callbacks: { fetch }
      });
      console.log(offer.credential_issuer);
      const offer = await resolveCredentialOffer({
      config,
      credentialOffer: "openid-credential-offer://?credential_offer_uri=https://issuer.example.com/offers/123",
      callbacks: { fetch }
      });
      console.log(offer.grants.authorization_code.issuer_state);
      const offerJson = '{"credential_issuer":"https://issuer.example.com","credential_configuration_ids":["UniversityDegree"],"grants":{"authorization_code":{"scope":"openid"}}}';
      const offer = await resolveCredentialOffer({
      config,
      credentialOffer: offerJson,
      callbacks: { fetch }
      });