|  | 
|  | 1 | +# Interface: DynamicClientRegistrationRequestOptions | 
|  | 2 | + | 
|  | 3 | +[💗 Help the project](https://github.com/sponsors/panva) | 
|  | 4 | + | 
|  | 5 | +Support from the community to continue maintaining and improving this module is welcome. If you find the module useful, please consider supporting the project by [becoming a sponsor](https://github.com/sponsors/panva). | 
|  | 6 | + | 
|  | 7 | +*** | 
|  | 8 | + | 
|  | 9 | +## Properties | 
|  | 10 | + | 
|  | 11 | +### \[customFetch\]? | 
|  | 12 | + | 
|  | 13 | +• `optional` **\[customFetch\]**: [`CustomFetch`](../type-aliases/CustomFetch.md) | 
|  | 14 | + | 
|  | 15 | +Custom [Fetch API](https://developer.mozilla.org/docs/Web/API/Window/fetch) implementation to use for the HTTP Requests | 
|  | 16 | +the client will be making. If this option is used, then the customFetch | 
|  | 17 | +value will be assigned to the resolved [Configuration](../classes/Configuration.md) instance for | 
|  | 18 | +use with all its future individual HTTP requests. | 
|  | 19 | + | 
|  | 20 | +#### See | 
|  | 21 | + | 
|  | 22 | +[customFetch](../variables/customFetch.md) | 
|  | 23 | + | 
|  | 24 | +*** | 
|  | 25 | + | 
|  | 26 | +### algorithm? | 
|  | 27 | + | 
|  | 28 | +• `optional` **algorithm**: `"oidc"` \| `"oauth2"` | 
|  | 29 | + | 
|  | 30 | +The issuer transformation algorithm to use. Default is `oidc`. | 
|  | 31 | + | 
|  | 32 | +#### Example | 
|  | 33 | + | 
|  | 34 | +```txt | 
|  | 35 | +Given the Issuer Identifier is https://example.com | 
|  | 36 | +  oidc  => https://example.com/.well-known/openid-configuration | 
|  | 37 | +  oauth => https://example.com/.well-known/oauth-authorization-server | 
|  | 38 | +
 | 
|  | 39 | +Given the Issuer Identifier is https://example.com/pathname | 
|  | 40 | +  oidc  => https://example.com/pathname/.well-known/openid-configuration | 
|  | 41 | +  oauth => https://example.com/.well-known/oauth-authorization-server/pathname | 
|  | 42 | +``` | 
|  | 43 | + | 
|  | 44 | +#### See | 
|  | 45 | + | 
|  | 46 | + - [OpenID Connect Discovery 1.0 (oidc)](https://openid.net/specs/openid-connect-discovery-1_0.html) | 
|  | 47 | + - [RFC8414 - OAuth 2.0 Authorization Server Metadata (oauth)](https://www.rfc-editor.org/rfc/rfc8414.html) | 
|  | 48 | + | 
|  | 49 | +*** | 
|  | 50 | + | 
|  | 51 | +### DPoP? | 
|  | 52 | + | 
|  | 53 | +• `optional` **DPoP**: [`DPoPHandle`](DPoPHandle.md) | 
|  | 54 | + | 
|  | 55 | +DPoP handle to use for requesting a sender-constrained access token. | 
|  | 56 | +Usually obtained from [getDPoPHandle](../functions/getDPoPHandle.md) | 
|  | 57 | + | 
|  | 58 | +#### See | 
|  | 59 | + | 
|  | 60 | +[RFC 9449 - OAuth 2.0 Demonstrating Proof of Possession (DPoP)](https://www.rfc-editor.org/rfc/rfc9449.html) | 
|  | 61 | + | 
|  | 62 | +*** | 
|  | 63 | + | 
|  | 64 | +### execute? | 
|  | 65 | + | 
|  | 66 | +• `optional` **execute**: (`config`) => `void`[] | 
|  | 67 | + | 
|  | 68 | +Methods (available list linked below) to execute with the | 
|  | 69 | +[Configuration](../classes/Configuration.md) instance as argument after it is instantiated | 
|  | 70 | + | 
|  | 71 | +Note: Presence of [allowInsecureRequests](../functions/allowInsecureRequests.md) in this option also enables | 
|  | 72 | +the use of insecure HTTP requests for the Authorization Server Metadata | 
|  | 73 | +discovery request itself. | 
|  | 74 | + | 
|  | 75 | +#### Parameters | 
|  | 76 | + | 
|  | 77 | +| Parameter | Type | | 
|  | 78 | +| ------ | ------ | | 
|  | 79 | +| `config` | [`Configuration`](../classes/Configuration.md) | | 
|  | 80 | + | 
|  | 81 | +#### Returns | 
|  | 82 | + | 
|  | 83 | +`void` | 
|  | 84 | + | 
|  | 85 | +#### Example | 
|  | 86 | + | 
|  | 87 | +Disable the HTTPS-only restriction for the discovery call and subsequently | 
|  | 88 | +for all requests made with the resulting [Configuration](../classes/Configuration.md) instance. | 
|  | 89 | + | 
|  | 90 | +```ts | 
|  | 91 | +let server!: URL | 
|  | 92 | +let clientId!: string | 
|  | 93 | +let clientMetadata!: | 
|  | 94 | +  | Partial<client.ClientMetadata> | 
|  | 95 | +  | undefined | 
|  | 96 | +  | string | 
|  | 97 | +let clientAuth!: client.ClientAuth | undefined | 
|  | 98 | + | 
|  | 99 | +let config = await client.discovery( | 
|  | 100 | +  server, | 
|  | 101 | +  clientId, | 
|  | 102 | +  clientMetadata, | 
|  | 103 | +  clientAuth, | 
|  | 104 | +  { | 
|  | 105 | +    execute: [client.allowInsecureRequests], | 
|  | 106 | +  }, | 
|  | 107 | +) | 
|  | 108 | +``` | 
|  | 109 | + | 
|  | 110 | +#### See | 
|  | 111 | + | 
|  | 112 | + - [allowInsecureRequests](../functions/allowInsecureRequests.md) | 
|  | 113 | + - [enableNonRepudiationChecks](../functions/enableNonRepudiationChecks.md) | 
|  | 114 | + - [useCodeIdTokenResponseType](../functions/useCodeIdTokenResponseType.md) | 
|  | 115 | + - [enableDetachedSignatureResponseChecks](../functions/enableDetachedSignatureResponseChecks.md) | 
|  | 116 | + - [useJwtResponseMode](../functions/useJwtResponseMode.md) | 
|  | 117 | + | 
|  | 118 | +*** | 
|  | 119 | + | 
|  | 120 | +### initialAccessToken? | 
|  | 121 | + | 
|  | 122 | +• `optional` **initialAccessToken**: `string` | 
|  | 123 | + | 
|  | 124 | +Access token optionally issued by an authorization server used to authorize | 
|  | 125 | +calls to the client registration endpoint. | 
|  | 126 | + | 
|  | 127 | +*** | 
|  | 128 | + | 
|  | 129 | +### timeout? | 
|  | 130 | + | 
|  | 131 | +• `optional` **timeout**: `number` | 
|  | 132 | + | 
|  | 133 | +Timeout (in seconds) for the Authorization Server Metadata discovery. If | 
|  | 134 | +this option is used, then the same timeout value will be assigned to the | 
|  | 135 | +resolved [Configuration](../classes/Configuration.md) instance for use with all its future | 
|  | 136 | +individual HTTP requests. Default is `30` (seconds) | 
0 commit comments