UMIS SDK
    Preparing search index...

    Function resolveOffer

    • Reads what the holder is shown about an offer and what is needed to redeem it, from the text of a QR code or a link (openid-credential-offer://?credential_offer=..., or ?credential_offer_uri=... for an offer held by the issuer).

      The offer must carry a pre-authorized-code grant. The metadata of the issuer is read from its well-known address and must name the issuer of the offer; the token endpoint comes from the metadata of its authorization server (the first of authorization_servers, else the issuer itself). An offer address to fetch must be https, or http on the local machine, and so must every endpoint. A text that is not an offer is UNSUPPORTED_FORMAT, a damaged offer in the address MALFORMED; the metadata and offers fetched from a server are PROTOCOL when they do not fit, and NETWORK when the server cannot be reached. opts.fetch is the global fetch by default. Every request asks not to follow redirects (redirect: 'error'): the global fetch then fails on a redirect (NETWORK); a fetch passed in decides for itself.

      Parameters

      • uri: string
      • opts: { fetch?: FetchLike } = {}

      Returns Promise<OfferView>