-
Notifications
You must be signed in to change notification settings - Fork 166
Expand file tree
/
Copy pathauthorization_request.d.ts
More file actions
46 lines (46 loc) · 1.41 KB
/
authorization_request.d.ts
File metadata and controls
46 lines (46 loc) · 1.41 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
import { AuthorizationManagementRequest } from './authorization_management_request';
import { Crypto } from './crypto_utils';
import { StringMap } from './types';
export declare const BUILT_IN_PARAMETERS: string[];
/**
* Represents an AuthorizationRequest as JSON.
*/
export interface AuthorizationRequestJson {
response_type: string;
client_id: string;
redirect_uri: string;
scope: string;
state?: string;
extras?: StringMap;
internal?: StringMap;
}
/**
* Represents the AuthorizationRequest.
* For more information look at
* https://tools.ietf.org/html/rfc6749#section-4.1.1
*/
export declare class AuthorizationRequest extends AuthorizationManagementRequest {
private crypto;
private usePkce;
static RESPONSE_TYPE_TOKEN: string;
static RESPONSE_TYPE_CODE: string;
clientId: string;
redirectUri: string;
scope: string;
responseType: string;
state: string;
extras?: StringMap;
internal?: StringMap;
/**
* Constructs a new AuthorizationRequest.
* Use a `undefined` value for the `state` parameter, to generate a random
* state for CSRF protection.
*/
constructor(request: AuthorizationRequestJson, crypto?: Crypto, usePkce?: boolean);
setupCodeVerifier(): Promise<void>;
/**
* Serializes the AuthorizationRequest to a JavaScript Object.
*/
toJson(): Promise<AuthorizationRequestJson>;
toRequestMap(): StringMap;
}