parseDiscoveryResponse
parseDiscoveryResponse(
data,expectedIssuer):OidcDiscovery
Defined in: packages/core/src/discovery.ts:47
Validates and parses a raw OpenID Provider Configuration response into an OidcDiscovery object.
Checks that all required string and array fields are present, and that the returned issuer
exactly matches expectedIssuer (after trailing-slash normalization).
Parameters
Section titled “Parameters”unknown
The raw JSON-parsed discovery response body.
expectedIssuer
Section titled “expectedIssuer”string
The issuer identifier the caller originally requested.
Returns
Section titled “Returns”A validated OidcDiscovery object.
Throws
Section titled “Throws”DISCOVERY_INVALID if required fields are missing or the response is not an object.
Throws
Section titled “Throws”DISCOVERY_ISSUER_MISMATCH if the returned issuer does not match expectedIssuer.
OpenID Connect Discovery 1.0 §4.3 — OpenID Provider Configuration Response