@wix/auto_sdk_identity_oauth 1.0.59 → 1.0.61
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/cjs/index.d.ts +1 -1
- package/build/cjs/index.js.map +1 -1
- package/build/cjs/index.typings.d.ts +152 -39
- package/build/cjs/index.typings.js.map +1 -1
- package/build/cjs/meta.d.ts +152 -39
- package/build/cjs/meta.js.map +1 -1
- package/build/es/index.d.mts +1 -1
- package/build/es/index.mjs.map +1 -1
- package/build/es/index.typings.d.mts +152 -39
- package/build/es/index.typings.mjs.map +1 -1
- package/build/es/meta.d.mts +152 -39
- package/build/es/meta.mjs.map +1 -1
- package/build/internal/cjs/index.d.ts +1 -1
- package/build/internal/cjs/index.typings.d.ts +166 -39
- package/build/internal/cjs/meta.d.ts +166 -39
- package/build/internal/es/index.d.mts +1 -1
- package/build/internal/es/index.typings.d.mts +166 -39
- package/build/internal/es/meta.d.mts +166 -39
- package/package.json +4 -4
|
@@ -4,6 +4,171 @@ import '@wix/sdk-types';
|
|
|
4
4
|
interface RefreshToken {
|
|
5
5
|
token?: string;
|
|
6
6
|
}
|
|
7
|
+
/**
|
|
8
|
+
* TokenRequest is sent by the client to the authorization server to request an
|
|
9
|
+
* access token.
|
|
10
|
+
*/
|
|
11
|
+
interface TokenRequest extends TokenRequestTenantOneOf {
|
|
12
|
+
/** supported tenant - specific site */
|
|
13
|
+
siteId?: string | null;
|
|
14
|
+
/** supported tenant - specific account */
|
|
15
|
+
accountId?: string | null;
|
|
16
|
+
/** The application id that want to obtain an access token. */
|
|
17
|
+
clientId?: string | null;
|
|
18
|
+
/**
|
|
19
|
+
* grant_type specifies the grant type being used. supported grant types are:
|
|
20
|
+
* `authorization_code`, `client_credentials`, `refresh_token`, `urn:ietf:params:oauth:grant-type:device_code`, `anonymous`,
|
|
21
|
+
* `urn:ietf:params:oauth:grant-type:token-exchange`
|
|
22
|
+
*/
|
|
23
|
+
grantType?: string;
|
|
24
|
+
/** Required for `refresh_token` grant type. */
|
|
25
|
+
refreshToken?: string | null;
|
|
26
|
+
/** Required for `client_credentials` grant type. */
|
|
27
|
+
clientSecret?: string | null;
|
|
28
|
+
/**
|
|
29
|
+
* Required for `urn:ietf:params:oauth:grant-type:device_code` grant type. The device verification code, "device_code" from the
|
|
30
|
+
* device authorization response
|
|
31
|
+
*/
|
|
32
|
+
deviceCode?: string | null;
|
|
33
|
+
/** Required for the `authorization_code` grant type. */
|
|
34
|
+
redirectUri?: string | null;
|
|
35
|
+
/** Required for `authorization_code` grant type. */
|
|
36
|
+
code?: string | null;
|
|
37
|
+
/** Optional, used if code challenge and code method were used in `authorization_code` grant type. */
|
|
38
|
+
codeVerifier?: string | null;
|
|
39
|
+
/** Required for `authorized_client` grant type - create tokens for a specific user. */
|
|
40
|
+
userId?: string | null;
|
|
41
|
+
/** Required for `authorized_client` grant type - create tokens for a specific member using api-key. */
|
|
42
|
+
memberId?: string | null;
|
|
43
|
+
/**
|
|
44
|
+
* Required for `client_credentials` grant type with clientId that represents an external app.
|
|
45
|
+
* An access token will be created based on the app installed version of an instance.
|
|
46
|
+
*/
|
|
47
|
+
instanceId?: string | null;
|
|
48
|
+
/** Required for `authorized_client` grant type for externalApp and must be bounded with client id, create access token to an app with a specific version. */
|
|
49
|
+
appVersion?: string | null;
|
|
50
|
+
/** Required for `strip_bound_session` grant type - create token without bound session. */
|
|
51
|
+
accessToken?: string | null;
|
|
52
|
+
/**
|
|
53
|
+
* Optional for `authorized_client` grant type - create tokens for a specific user.
|
|
54
|
+
* @format GUID
|
|
55
|
+
*/
|
|
56
|
+
userAccountId?: string | null;
|
|
57
|
+
/**
|
|
58
|
+
* Optional for `authorized_client` grant type - bind the issued tokens to a specific session (session-bound wixAT/wixRT).
|
|
59
|
+
* Internal-only: used by the server-to-server switchAccount flow via Oauth2NgInternal.
|
|
60
|
+
* @internal
|
|
61
|
+
* @format GUID
|
|
62
|
+
*/
|
|
63
|
+
sessionId?: string | null;
|
|
64
|
+
/**
|
|
65
|
+
* Optional for `authorized_client` grant type (member tokens) - a member session token that is opened server-side to
|
|
66
|
+
* extract the bound session id, producing session-bound wixAT/wixRT. Public: used by the member flow from public traffic.
|
|
67
|
+
*/
|
|
68
|
+
sessionToken?: string | null;
|
|
69
|
+
/**
|
|
70
|
+
* Optional for `authorized_client` grant type - attach an impersonating user id to the minted token.
|
|
71
|
+
* Internal-only: used by server-to-server flows where a service mints a token carrying impersonation context.
|
|
72
|
+
* @internal
|
|
73
|
+
* @format GUID
|
|
74
|
+
*/
|
|
75
|
+
impersonatingUserId?: string | null;
|
|
76
|
+
/**
|
|
77
|
+
* Required for the `urn:ietf:params:oauth:grant-type:token-exchange` grant - the account-level access token being
|
|
78
|
+
* exchanged for one scoped to the target named by the `tenant` oneof.
|
|
79
|
+
*/
|
|
80
|
+
subjectToken?: string | null;
|
|
81
|
+
/**
|
|
82
|
+
* Required for the `urn:ietf:params:oauth:grant-type:token-exchange` grant - identifies the type of `subject_token`.
|
|
83
|
+
* Only `urn:ietf:params:oauth:token-type:access_token` is supported.
|
|
84
|
+
* @maxLength 100
|
|
85
|
+
*/
|
|
86
|
+
subjectTokenType?: string | null;
|
|
87
|
+
}
|
|
88
|
+
/** @oneof */
|
|
89
|
+
interface TokenRequestTenantOneOf {
|
|
90
|
+
/** supported tenant - specific site */
|
|
91
|
+
siteId?: string | null;
|
|
92
|
+
/** supported tenant - specific account */
|
|
93
|
+
accountId?: string | null;
|
|
94
|
+
}
|
|
95
|
+
interface InternalTokenResponse extends InternalTokenResponseResultOneOf {
|
|
96
|
+
success?: TokenResponse;
|
|
97
|
+
failure?: TokenErrorResponse;
|
|
98
|
+
}
|
|
99
|
+
/** @oneof */
|
|
100
|
+
interface InternalTokenResponseResultOneOf {
|
|
101
|
+
success?: TokenResponse;
|
|
102
|
+
failure?: TokenErrorResponse;
|
|
103
|
+
}
|
|
104
|
+
interface TokenResponse {
|
|
105
|
+
/** The access token issued by the authorization server. */
|
|
106
|
+
accessToken?: string;
|
|
107
|
+
/** The type of the token issued as described in Section 7.1. of the oauth2 rfc. */
|
|
108
|
+
tokenType?: string;
|
|
109
|
+
/**
|
|
110
|
+
* The lifetime in seconds of the access token. For example, the value "3600" denotes that the access token will
|
|
111
|
+
* expire in one hour from the time the response was generated.
|
|
112
|
+
*/
|
|
113
|
+
expiresIn?: number;
|
|
114
|
+
/** The refresh token, which can be used to obtain new access tokens. */
|
|
115
|
+
refreshToken?: string | null;
|
|
116
|
+
/** OPTIONAL, if identical to the scope requested by the client; otherwise, will be sent. */
|
|
117
|
+
scope?: string | null;
|
|
118
|
+
idToken?: string | null;
|
|
119
|
+
/**
|
|
120
|
+
* Set only for the `urn:ietf:params:oauth:grant-type:token-exchange` grant, where it is always
|
|
121
|
+
* `urn:ietf:params:oauth:token-type:access_token`. Empty for every other grant.
|
|
122
|
+
* @maxLength 100
|
|
123
|
+
*/
|
|
124
|
+
issuedTokenType?: string | null;
|
|
125
|
+
}
|
|
126
|
+
interface TokenErrorResponse {
|
|
127
|
+
error?: string;
|
|
128
|
+
errorDescription?: string | null;
|
|
129
|
+
}
|
|
130
|
+
interface TokenInfoRequest {
|
|
131
|
+
/** The access token to introspect. */
|
|
132
|
+
token?: string;
|
|
133
|
+
}
|
|
134
|
+
interface TokenInfoResponse {
|
|
135
|
+
active?: boolean;
|
|
136
|
+
/** subject type. */
|
|
137
|
+
subjectType?: SubjectTypeWithLiterals;
|
|
138
|
+
/** subject id */
|
|
139
|
+
subjectId?: string;
|
|
140
|
+
/** Expiration time of the token */
|
|
141
|
+
exp?: string | null;
|
|
142
|
+
/** Issued time of the token */
|
|
143
|
+
iat?: string | null;
|
|
144
|
+
/** Client id */
|
|
145
|
+
clientId?: string;
|
|
146
|
+
/** Account id */
|
|
147
|
+
accountId?: string | null;
|
|
148
|
+
/** Site id */
|
|
149
|
+
siteId?: string | null;
|
|
150
|
+
/** Instance Id */
|
|
151
|
+
instanceId?: string | null;
|
|
152
|
+
/**
|
|
153
|
+
* Vendor Product Id
|
|
154
|
+
* @maxLength 100
|
|
155
|
+
*/
|
|
156
|
+
vendorProductId?: string | null;
|
|
157
|
+
}
|
|
158
|
+
declare enum SubjectType {
|
|
159
|
+
/** unknown subject type */
|
|
160
|
+
UNKNOWN = "UNKNOWN",
|
|
161
|
+
/** user subject type */
|
|
162
|
+
USER = "USER",
|
|
163
|
+
/** visitor subject type */
|
|
164
|
+
VISITOR = "VISITOR",
|
|
165
|
+
/** member subject type */
|
|
166
|
+
MEMBER = "MEMBER",
|
|
167
|
+
/** app subject type */
|
|
168
|
+
APP = "APP"
|
|
169
|
+
}
|
|
170
|
+
/** @enumType */
|
|
171
|
+
type SubjectTypeWithLiterals = SubjectType | 'UNKNOWN' | 'USER' | 'VISITOR' | 'MEMBER' | 'APP';
|
|
7
172
|
/**
|
|
8
173
|
* AuthorizeRequest is sent by the client to the authorization server to initiate
|
|
9
174
|
* the authorization process.
|
|
@@ -266,44 +431,6 @@ interface RevokeRefreshTokenRequest {
|
|
|
266
431
|
}
|
|
267
432
|
interface RevokeRefreshTokenResponse {
|
|
268
433
|
}
|
|
269
|
-
interface TokenInfoResponse {
|
|
270
|
-
active?: boolean;
|
|
271
|
-
/** subject type. */
|
|
272
|
-
subjectType?: SubjectTypeWithLiterals;
|
|
273
|
-
/** subject id */
|
|
274
|
-
subjectId?: string;
|
|
275
|
-
/** Expiration time of the token */
|
|
276
|
-
exp?: string | null;
|
|
277
|
-
/** Issued time of the token */
|
|
278
|
-
iat?: string | null;
|
|
279
|
-
/** Client id */
|
|
280
|
-
clientId?: string;
|
|
281
|
-
/** Account id */
|
|
282
|
-
accountId?: string | null;
|
|
283
|
-
/** Site id */
|
|
284
|
-
siteId?: string | null;
|
|
285
|
-
/** Instance Id */
|
|
286
|
-
instanceId?: string | null;
|
|
287
|
-
/**
|
|
288
|
-
* Vendor Product Id
|
|
289
|
-
* @maxLength 100
|
|
290
|
-
*/
|
|
291
|
-
vendorProductId?: string | null;
|
|
292
|
-
}
|
|
293
|
-
declare enum SubjectType {
|
|
294
|
-
/** unknown subject type */
|
|
295
|
-
UNKNOWN = "UNKNOWN",
|
|
296
|
-
/** user subject type */
|
|
297
|
-
USER = "USER",
|
|
298
|
-
/** visitor subject type */
|
|
299
|
-
VISITOR = "VISITOR",
|
|
300
|
-
/** member subject type */
|
|
301
|
-
MEMBER = "MEMBER",
|
|
302
|
-
/** app subject type */
|
|
303
|
-
APP = "APP"
|
|
304
|
-
}
|
|
305
|
-
/** @enumType */
|
|
306
|
-
type SubjectTypeWithLiterals = SubjectType | 'UNKNOWN' | 'USER' | 'VISITOR' | 'MEMBER' | 'APP';
|
|
307
434
|
interface Empty {
|
|
308
435
|
}
|
|
309
436
|
interface DomainEvent extends DomainEventBodyOneOf {
|
|
@@ -481,4 +608,4 @@ declare function jwks(): __PublicMethodMetaInfo<'GET', {}, JwksRequest$1, JwksRe
|
|
|
481
608
|
declare function tokenInfo(): __PublicMethodMetaInfo<'POST', {}, RawHttpRequest$1, RawHttpRequest, TokenInfoResponse$1, TokenInfoResponse>;
|
|
482
609
|
declare function userInfo(): __PublicMethodMetaInfo<'GET', {}, UserInfoRequest$1, UserInfoRequest, UserInfoResponse$1, UserInfoResponse>;
|
|
483
610
|
|
|
484
|
-
export { type ActionEvent as ActionEventOriginal, type AuthorizeRequest as AuthorizeRequestOriginal, type DeviceAuthorizationInfoRequest as DeviceAuthorizationInfoRequestOriginal, type DeviceAuthorizationInfoResponse as DeviceAuthorizationInfoResponseOriginal, type DeviceAuthorizeRequest as DeviceAuthorizeRequestOriginal, type DeviceAuthorizeResponse as DeviceAuthorizeResponseOriginal, type DeviceCodeRequest as DeviceCodeRequestOriginal, type DeviceCodeResponse as DeviceCodeResponseOriginal, type DeviceVerifyRequest as DeviceVerifyRequestOriginal, type DeviceVerifyResponse as DeviceVerifyResponseOriginal, type DeviceVerifyV2Request as DeviceVerifyV2RequestOriginal, type DeviceVerifyV2Response as DeviceVerifyV2ResponseOriginal, type DomainEventBodyOneOf as DomainEventBodyOneOfOriginal, type DomainEvent as DomainEventOriginal, type Empty as EmptyOriginal, type EntityCreatedEvent as EntityCreatedEventOriginal, type EntityDeletedEvent as EntityDeletedEventOriginal, type EntityUpdatedEvent as EntityUpdatedEventOriginal, type HeadersEntry as HeadersEntryOriginal, type InvalidateUserCodeRequest as InvalidateUserCodeRequestOriginal, type InvalidateUserCodeResponse as InvalidateUserCodeResponseOriginal, type JwksRequest as JwksRequestOriginal, type PathParametersEntry as PathParametersEntryOriginal, type QueryParametersEntry as QueryParametersEntryOriginal, type RawHttpRequest as RawHttpRequestOriginal, type RawHttpResponse as RawHttpResponseOriginal, type RefreshToken as RefreshTokenOriginal, type RestoreInfo as RestoreInfoOriginal, type RevokeRefreshTokenRequest as RevokeRefreshTokenRequestOriginal, type RevokeRefreshTokenResponse as RevokeRefreshTokenResponseOriginal, SubjectType as SubjectTypeOriginal, type SubjectTypeWithLiterals as SubjectTypeWithLiteralsOriginal, type TokenInfoResponse as TokenInfoResponseOriginal, type UserBlockedEvent as UserBlockedEventOriginal, type UserDeletedEvent as UserDeletedEventOriginal, type UserInfoRequest as UserInfoRequestOriginal, type UserInfoResponse as UserInfoResponseOriginal, type __PublicMethodMetaInfo, jwks, token, tokenInfo, userInfo };
|
|
611
|
+
export { type ActionEvent as ActionEventOriginal, type AuthorizeRequest as AuthorizeRequestOriginal, type DeviceAuthorizationInfoRequest as DeviceAuthorizationInfoRequestOriginal, type DeviceAuthorizationInfoResponse as DeviceAuthorizationInfoResponseOriginal, type DeviceAuthorizeRequest as DeviceAuthorizeRequestOriginal, type DeviceAuthorizeResponse as DeviceAuthorizeResponseOriginal, type DeviceCodeRequest as DeviceCodeRequestOriginal, type DeviceCodeResponse as DeviceCodeResponseOriginal, type DeviceVerifyRequest as DeviceVerifyRequestOriginal, type DeviceVerifyResponse as DeviceVerifyResponseOriginal, type DeviceVerifyV2Request as DeviceVerifyV2RequestOriginal, type DeviceVerifyV2Response as DeviceVerifyV2ResponseOriginal, type DomainEventBodyOneOf as DomainEventBodyOneOfOriginal, type DomainEvent as DomainEventOriginal, type Empty as EmptyOriginal, type EntityCreatedEvent as EntityCreatedEventOriginal, type EntityDeletedEvent as EntityDeletedEventOriginal, type EntityUpdatedEvent as EntityUpdatedEventOriginal, type HeadersEntry as HeadersEntryOriginal, type InternalTokenResponse as InternalTokenResponseOriginal, type InternalTokenResponseResultOneOf as InternalTokenResponseResultOneOfOriginal, type InvalidateUserCodeRequest as InvalidateUserCodeRequestOriginal, type InvalidateUserCodeResponse as InvalidateUserCodeResponseOriginal, type JwksRequest as JwksRequestOriginal, type PathParametersEntry as PathParametersEntryOriginal, type QueryParametersEntry as QueryParametersEntryOriginal, type RawHttpRequest as RawHttpRequestOriginal, type RawHttpResponse as RawHttpResponseOriginal, type RefreshToken as RefreshTokenOriginal, type RestoreInfo as RestoreInfoOriginal, type RevokeRefreshTokenRequest as RevokeRefreshTokenRequestOriginal, type RevokeRefreshTokenResponse as RevokeRefreshTokenResponseOriginal, SubjectType as SubjectTypeOriginal, type SubjectTypeWithLiterals as SubjectTypeWithLiteralsOriginal, type TokenErrorResponse as TokenErrorResponseOriginal, type TokenInfoRequest as TokenInfoRequestOriginal, type TokenInfoResponse as TokenInfoResponseOriginal, type TokenRequest as TokenRequestOriginal, type TokenRequestTenantOneOf as TokenRequestTenantOneOfOriginal, type TokenResponse as TokenResponseOriginal, type UserBlockedEvent as UserBlockedEventOriginal, type UserDeletedEvent as UserDeletedEventOriginal, type UserInfoRequest as UserInfoRequestOriginal, type UserInfoResponse as UserInfoResponseOriginal, type __PublicMethodMetaInfo, jwks, token, tokenInfo, userInfo };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { HttpClient, NonNullablePaths, MaybeContext, BuildRESTFunction } from '@wix/sdk-types';
|
|
2
2
|
import { TokenOptions, RawHttpResponse, TokenInfoOptions, TokenInfoResponse, UserInfoResponse } from './index.typings.mjs';
|
|
3
|
-
export { ActionEvent, AuthorizeRequest, DeviceAuthorizationInfoRequest, DeviceAuthorizationInfoResponse, DeviceAuthorizeRequest, DeviceAuthorizeResponse, DeviceCodeRequest, DeviceCodeResponse, DeviceVerifyRequest, DeviceVerifyResponse, DeviceVerifyV2Request, DeviceVerifyV2Response, DomainEvent, DomainEventBodyOneOf, Empty, EntityCreatedEvent, EntityDeletedEvent, EntityUpdatedEvent, HeadersEntry, InvalidateUserCodeRequest, InvalidateUserCodeResponse, JwksRequest, PathParametersEntry, QueryParametersEntry, RawHttpRequest, RefreshToken, RestoreInfo, RevokeRefreshTokenRequest, RevokeRefreshTokenResponse, SubjectType, SubjectTypeWithLiterals, UserBlockedEvent, UserDeletedEvent, UserInfoRequest } from './index.typings.mjs';
|
|
3
|
+
export { ActionEvent, AuthorizeRequest, DeviceAuthorizationInfoRequest, DeviceAuthorizationInfoResponse, DeviceAuthorizeRequest, DeviceAuthorizeResponse, DeviceCodeRequest, DeviceCodeResponse, DeviceVerifyRequest, DeviceVerifyResponse, DeviceVerifyV2Request, DeviceVerifyV2Response, DomainEvent, DomainEventBodyOneOf, Empty, EntityCreatedEvent, EntityDeletedEvent, EntityUpdatedEvent, HeadersEntry, InternalTokenResponse, InternalTokenResponseResultOneOf, InvalidateUserCodeRequest, InvalidateUserCodeResponse, JwksRequest, PathParametersEntry, QueryParametersEntry, RawHttpRequest, RefreshToken, RestoreInfo, RevokeRefreshTokenRequest, RevokeRefreshTokenResponse, SubjectType, SubjectTypeWithLiterals, TokenErrorResponse, TokenInfoRequest, TokenRequest, TokenRequestTenantOneOf, TokenResponse, UserBlockedEvent, UserDeletedEvent, UserInfoRequest } from './index.typings.mjs';
|
|
4
4
|
|
|
5
5
|
declare function token$1(httpClient: HttpClient): TokenSignature;
|
|
6
6
|
interface TokenSignature {
|
|
@@ -3,6 +3,171 @@ import { NonNullablePaths } from '@wix/sdk-types';
|
|
|
3
3
|
interface RefreshToken {
|
|
4
4
|
token?: string;
|
|
5
5
|
}
|
|
6
|
+
/**
|
|
7
|
+
* TokenRequest is sent by the client to the authorization server to request an
|
|
8
|
+
* access token.
|
|
9
|
+
*/
|
|
10
|
+
interface TokenRequest extends TokenRequestTenantOneOf {
|
|
11
|
+
/** supported tenant - specific site */
|
|
12
|
+
siteId?: string | null;
|
|
13
|
+
/** supported tenant - specific account */
|
|
14
|
+
accountId?: string | null;
|
|
15
|
+
/** The application id that want to obtain an access token. */
|
|
16
|
+
clientId?: string | null;
|
|
17
|
+
/**
|
|
18
|
+
* grant_type specifies the grant type being used. supported grant types are:
|
|
19
|
+
* `authorization_code`, `client_credentials`, `refresh_token`, `urn:ietf:params:oauth:grant-type:device_code`, `anonymous`,
|
|
20
|
+
* `urn:ietf:params:oauth:grant-type:token-exchange`
|
|
21
|
+
*/
|
|
22
|
+
grantType?: string;
|
|
23
|
+
/** Required for `refresh_token` grant type. */
|
|
24
|
+
refreshToken?: string | null;
|
|
25
|
+
/** Required for `client_credentials` grant type. */
|
|
26
|
+
clientSecret?: string | null;
|
|
27
|
+
/**
|
|
28
|
+
* Required for `urn:ietf:params:oauth:grant-type:device_code` grant type. The device verification code, "device_code" from the
|
|
29
|
+
* device authorization response
|
|
30
|
+
*/
|
|
31
|
+
deviceCode?: string | null;
|
|
32
|
+
/** Required for the `authorization_code` grant type. */
|
|
33
|
+
redirectUri?: string | null;
|
|
34
|
+
/** Required for `authorization_code` grant type. */
|
|
35
|
+
code?: string | null;
|
|
36
|
+
/** Optional, used if code challenge and code method were used in `authorization_code` grant type. */
|
|
37
|
+
codeVerifier?: string | null;
|
|
38
|
+
/** Required for `authorized_client` grant type - create tokens for a specific user. */
|
|
39
|
+
userId?: string | null;
|
|
40
|
+
/** Required for `authorized_client` grant type - create tokens for a specific member using api-key. */
|
|
41
|
+
memberId?: string | null;
|
|
42
|
+
/**
|
|
43
|
+
* Required for `client_credentials` grant type with clientId that represents an external app.
|
|
44
|
+
* An access token will be created based on the app installed version of an instance.
|
|
45
|
+
*/
|
|
46
|
+
instanceId?: string | null;
|
|
47
|
+
/** Required for `authorized_client` grant type for externalApp and must be bounded with client id, create access token to an app with a specific version. */
|
|
48
|
+
appVersion?: string | null;
|
|
49
|
+
/** Required for `strip_bound_session` grant type - create token without bound session. */
|
|
50
|
+
accessToken?: string | null;
|
|
51
|
+
/**
|
|
52
|
+
* Optional for `authorized_client` grant type - create tokens for a specific user.
|
|
53
|
+
* @format GUID
|
|
54
|
+
*/
|
|
55
|
+
userAccountId?: string | null;
|
|
56
|
+
/**
|
|
57
|
+
* Optional for `authorized_client` grant type - bind the issued tokens to a specific session (session-bound wixAT/wixRT).
|
|
58
|
+
* Internal-only: used by the server-to-server switchAccount flow via Oauth2NgInternal.
|
|
59
|
+
* @internal
|
|
60
|
+
* @format GUID
|
|
61
|
+
*/
|
|
62
|
+
sessionId?: string | null;
|
|
63
|
+
/**
|
|
64
|
+
* Optional for `authorized_client` grant type (member tokens) - a member session token that is opened server-side to
|
|
65
|
+
* extract the bound session id, producing session-bound wixAT/wixRT. Public: used by the member flow from public traffic.
|
|
66
|
+
*/
|
|
67
|
+
sessionToken?: string | null;
|
|
68
|
+
/**
|
|
69
|
+
* Optional for `authorized_client` grant type - attach an impersonating user id to the minted token.
|
|
70
|
+
* Internal-only: used by server-to-server flows where a service mints a token carrying impersonation context.
|
|
71
|
+
* @internal
|
|
72
|
+
* @format GUID
|
|
73
|
+
*/
|
|
74
|
+
impersonatingUserId?: string | null;
|
|
75
|
+
/**
|
|
76
|
+
* Required for the `urn:ietf:params:oauth:grant-type:token-exchange` grant - the account-level access token being
|
|
77
|
+
* exchanged for one scoped to the target named by the `tenant` oneof.
|
|
78
|
+
*/
|
|
79
|
+
subjectToken?: string | null;
|
|
80
|
+
/**
|
|
81
|
+
* Required for the `urn:ietf:params:oauth:grant-type:token-exchange` grant - identifies the type of `subject_token`.
|
|
82
|
+
* Only `urn:ietf:params:oauth:token-type:access_token` is supported.
|
|
83
|
+
* @maxLength 100
|
|
84
|
+
*/
|
|
85
|
+
subjectTokenType?: string | null;
|
|
86
|
+
}
|
|
87
|
+
/** @oneof */
|
|
88
|
+
interface TokenRequestTenantOneOf {
|
|
89
|
+
/** supported tenant - specific site */
|
|
90
|
+
siteId?: string | null;
|
|
91
|
+
/** supported tenant - specific account */
|
|
92
|
+
accountId?: string | null;
|
|
93
|
+
}
|
|
94
|
+
interface InternalTokenResponse extends InternalTokenResponseResultOneOf {
|
|
95
|
+
success?: TokenResponse;
|
|
96
|
+
failure?: TokenErrorResponse;
|
|
97
|
+
}
|
|
98
|
+
/** @oneof */
|
|
99
|
+
interface InternalTokenResponseResultOneOf {
|
|
100
|
+
success?: TokenResponse;
|
|
101
|
+
failure?: TokenErrorResponse;
|
|
102
|
+
}
|
|
103
|
+
interface TokenResponse {
|
|
104
|
+
/** The access token issued by the authorization server. */
|
|
105
|
+
accessToken?: string;
|
|
106
|
+
/** The type of the token issued as described in Section 7.1. of the oauth2 rfc. */
|
|
107
|
+
tokenType?: string;
|
|
108
|
+
/**
|
|
109
|
+
* The lifetime in seconds of the access token. For example, the value "3600" denotes that the access token will
|
|
110
|
+
* expire in one hour from the time the response was generated.
|
|
111
|
+
*/
|
|
112
|
+
expiresIn?: number;
|
|
113
|
+
/** The refresh token, which can be used to obtain new access tokens. */
|
|
114
|
+
refreshToken?: string | null;
|
|
115
|
+
/** OPTIONAL, if identical to the scope requested by the client; otherwise, will be sent. */
|
|
116
|
+
scope?: string | null;
|
|
117
|
+
idToken?: string | null;
|
|
118
|
+
/**
|
|
119
|
+
* Set only for the `urn:ietf:params:oauth:grant-type:token-exchange` grant, where it is always
|
|
120
|
+
* `urn:ietf:params:oauth:token-type:access_token`. Empty for every other grant.
|
|
121
|
+
* @maxLength 100
|
|
122
|
+
*/
|
|
123
|
+
issuedTokenType?: string | null;
|
|
124
|
+
}
|
|
125
|
+
interface TokenErrorResponse {
|
|
126
|
+
error?: string;
|
|
127
|
+
errorDescription?: string | null;
|
|
128
|
+
}
|
|
129
|
+
interface TokenInfoRequest {
|
|
130
|
+
/** The access token to introspect. */
|
|
131
|
+
token?: string;
|
|
132
|
+
}
|
|
133
|
+
interface TokenInfoResponse {
|
|
134
|
+
active?: boolean;
|
|
135
|
+
/** subject type. */
|
|
136
|
+
subjectType?: SubjectTypeWithLiterals;
|
|
137
|
+
/** subject id */
|
|
138
|
+
subjectId?: string;
|
|
139
|
+
/** Expiration time of the token */
|
|
140
|
+
exp?: string | null;
|
|
141
|
+
/** Issued time of the token */
|
|
142
|
+
iat?: string | null;
|
|
143
|
+
/** Client id */
|
|
144
|
+
clientId?: string;
|
|
145
|
+
/** Account id */
|
|
146
|
+
accountId?: string | null;
|
|
147
|
+
/** Site id */
|
|
148
|
+
siteId?: string | null;
|
|
149
|
+
/** Instance Id */
|
|
150
|
+
instanceId?: string | null;
|
|
151
|
+
/**
|
|
152
|
+
* Vendor Product Id
|
|
153
|
+
* @maxLength 100
|
|
154
|
+
*/
|
|
155
|
+
vendorProductId?: string | null;
|
|
156
|
+
}
|
|
157
|
+
declare enum SubjectType {
|
|
158
|
+
/** unknown subject type */
|
|
159
|
+
UNKNOWN = "UNKNOWN",
|
|
160
|
+
/** user subject type */
|
|
161
|
+
USER = "USER",
|
|
162
|
+
/** visitor subject type */
|
|
163
|
+
VISITOR = "VISITOR",
|
|
164
|
+
/** member subject type */
|
|
165
|
+
MEMBER = "MEMBER",
|
|
166
|
+
/** app subject type */
|
|
167
|
+
APP = "APP"
|
|
168
|
+
}
|
|
169
|
+
/** @enumType */
|
|
170
|
+
type SubjectTypeWithLiterals = SubjectType | 'UNKNOWN' | 'USER' | 'VISITOR' | 'MEMBER' | 'APP';
|
|
6
171
|
/**
|
|
7
172
|
* AuthorizeRequest is sent by the client to the authorization server to initiate
|
|
8
173
|
* the authorization process.
|
|
@@ -265,44 +430,6 @@ interface RevokeRefreshTokenRequest {
|
|
|
265
430
|
}
|
|
266
431
|
interface RevokeRefreshTokenResponse {
|
|
267
432
|
}
|
|
268
|
-
interface TokenInfoResponse {
|
|
269
|
-
active?: boolean;
|
|
270
|
-
/** subject type. */
|
|
271
|
-
subjectType?: SubjectTypeWithLiterals;
|
|
272
|
-
/** subject id */
|
|
273
|
-
subjectId?: string;
|
|
274
|
-
/** Expiration time of the token */
|
|
275
|
-
exp?: string | null;
|
|
276
|
-
/** Issued time of the token */
|
|
277
|
-
iat?: string | null;
|
|
278
|
-
/** Client id */
|
|
279
|
-
clientId?: string;
|
|
280
|
-
/** Account id */
|
|
281
|
-
accountId?: string | null;
|
|
282
|
-
/** Site id */
|
|
283
|
-
siteId?: string | null;
|
|
284
|
-
/** Instance Id */
|
|
285
|
-
instanceId?: string | null;
|
|
286
|
-
/**
|
|
287
|
-
* Vendor Product Id
|
|
288
|
-
* @maxLength 100
|
|
289
|
-
*/
|
|
290
|
-
vendorProductId?: string | null;
|
|
291
|
-
}
|
|
292
|
-
declare enum SubjectType {
|
|
293
|
-
/** unknown subject type */
|
|
294
|
-
UNKNOWN = "UNKNOWN",
|
|
295
|
-
/** user subject type */
|
|
296
|
-
USER = "USER",
|
|
297
|
-
/** visitor subject type */
|
|
298
|
-
VISITOR = "VISITOR",
|
|
299
|
-
/** member subject type */
|
|
300
|
-
MEMBER = "MEMBER",
|
|
301
|
-
/** app subject type */
|
|
302
|
-
APP = "APP"
|
|
303
|
-
}
|
|
304
|
-
/** @enumType */
|
|
305
|
-
type SubjectTypeWithLiterals = SubjectType | 'UNKNOWN' | 'USER' | 'VISITOR' | 'MEMBER' | 'APP';
|
|
306
433
|
interface Empty {
|
|
307
434
|
}
|
|
308
435
|
interface DomainEvent extends DomainEventBodyOneOf {
|
|
@@ -483,4 +610,4 @@ interface TokenInfoOptions {
|
|
|
483
610
|
*/
|
|
484
611
|
declare function userInfo(): Promise<NonNullablePaths<UserInfoResponse, `sub`, 0>>;
|
|
485
612
|
|
|
486
|
-
export { type ActionEvent, type AuthorizeRequest, type DeviceAuthorizationInfoRequest, type DeviceAuthorizationInfoResponse, type DeviceAuthorizeRequest, type DeviceAuthorizeResponse, type DeviceCodeRequest, type DeviceCodeResponse, type DeviceVerifyRequest, type DeviceVerifyResponse, type DeviceVerifyV2Request, type DeviceVerifyV2Response, type DomainEvent, type DomainEventBodyOneOf, type Empty, type EntityCreatedEvent, type EntityDeletedEvent, type EntityUpdatedEvent, type HeadersEntry, type InvalidateUserCodeRequest, type InvalidateUserCodeResponse, type JwksRequest, type PathParametersEntry, type QueryParametersEntry, type RawHttpRequest, type RawHttpResponse, type RefreshToken, type RestoreInfo, type RevokeRefreshTokenRequest, type RevokeRefreshTokenResponse, SubjectType, type SubjectTypeWithLiterals, type TokenInfoOptions, type TokenInfoResponse, type TokenOptions, type UserBlockedEvent, type UserDeletedEvent, type UserInfoRequest, type UserInfoResponse, jwks, token, tokenInfo, userInfo };
|
|
613
|
+
export { type ActionEvent, type AuthorizeRequest, type DeviceAuthorizationInfoRequest, type DeviceAuthorizationInfoResponse, type DeviceAuthorizeRequest, type DeviceAuthorizeResponse, type DeviceCodeRequest, type DeviceCodeResponse, type DeviceVerifyRequest, type DeviceVerifyResponse, type DeviceVerifyV2Request, type DeviceVerifyV2Response, type DomainEvent, type DomainEventBodyOneOf, type Empty, type EntityCreatedEvent, type EntityDeletedEvent, type EntityUpdatedEvent, type HeadersEntry, type InternalTokenResponse, type InternalTokenResponseResultOneOf, type InvalidateUserCodeRequest, type InvalidateUserCodeResponse, type JwksRequest, type PathParametersEntry, type QueryParametersEntry, type RawHttpRequest, type RawHttpResponse, type RefreshToken, type RestoreInfo, type RevokeRefreshTokenRequest, type RevokeRefreshTokenResponse, SubjectType, type SubjectTypeWithLiterals, type TokenErrorResponse, type TokenInfoOptions, type TokenInfoRequest, type TokenInfoResponse, type TokenOptions, type TokenRequest, type TokenRequestTenantOneOf, type TokenResponse, type UserBlockedEvent, type UserDeletedEvent, type UserInfoRequest, type UserInfoResponse, jwks, token, tokenInfo, userInfo };
|