@flipdish/authorization 0.2.52 → 0.2.53
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/api.ts +86 -1
- package/configuration.ts +1 -1
- package/dist/api.d.ts +47 -1
- package/dist/api.js +88 -2
- package/dist/configuration.js +1 -1
- package/package.json +1 -1
package/api.ts
CHANGED
|
@@ -422,6 +422,26 @@ export interface AuthenticateAndCheckIsInRoleResponseAuthentication {
|
|
|
422
422
|
*/
|
|
423
423
|
'reason'?: string;
|
|
424
424
|
}
|
|
425
|
+
/**
|
|
426
|
+
*
|
|
427
|
+
* @export
|
|
428
|
+
* @interface AuthenticateApiKey200Response
|
|
429
|
+
*/
|
|
430
|
+
export interface AuthenticateApiKey200Response {
|
|
431
|
+
/**
|
|
432
|
+
*
|
|
433
|
+
* @type {boolean}
|
|
434
|
+
* @memberof AuthenticateApiKey200Response
|
|
435
|
+
*/
|
|
436
|
+
'ok': AuthenticateApiKey200ResponseOkEnum;
|
|
437
|
+
}
|
|
438
|
+
|
|
439
|
+
export const AuthenticateApiKey200ResponseOkEnum = {
|
|
440
|
+
True: true
|
|
441
|
+
} as const;
|
|
442
|
+
|
|
443
|
+
export type AuthenticateApiKey200ResponseOkEnum = typeof AuthenticateApiKey200ResponseOkEnum[keyof typeof AuthenticateApiKey200ResponseOkEnum];
|
|
444
|
+
|
|
425
445
|
/**
|
|
426
446
|
*
|
|
427
447
|
* @export
|
|
@@ -574,7 +594,7 @@ export type AuthorizationBatchResponseAllowedResourcesInnerResource = Authorizat
|
|
|
574
594
|
*/
|
|
575
595
|
export interface AuthorizationChecksBatchRequest {
|
|
576
596
|
/**
|
|
577
|
-
* Principal/resource/action tuples to check authorisation for
|
|
597
|
+
* Principal/resource/action tuples to check authorisation for. Checks that share a principal or a resource are evaluated most efficiently; batches spanning too many distinct combinations are rejected with a 400.
|
|
578
598
|
* @type {Array<AuthorizationChecksBatchRequestChecksInner>}
|
|
579
599
|
* @memberof AuthorizationChecksBatchRequest
|
|
580
600
|
*/
|
|
@@ -3010,6 +3030,39 @@ export interface UpdateGlobalApiKeyRequest {
|
|
|
3010
3030
|
*/
|
|
3011
3031
|
export const APIKeysApiAxiosParamCreator = function (configuration?: Configuration) {
|
|
3012
3032
|
return {
|
|
3033
|
+
/**
|
|
3034
|
+
* Authenticates the presented Automation API key (x-api-key or Authorization: ApiKey <key>) and returns status only: 200 when the key is active and not expired, 401 otherwise. Not authenticated by cookie/JWT sessions.
|
|
3035
|
+
* @summary Authenticate API key
|
|
3036
|
+
* @param {*} [options] Override http request option.
|
|
3037
|
+
* @throws {RequiredError}
|
|
3038
|
+
*/
|
|
3039
|
+
authenticateApiKey: async (options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
|
|
3040
|
+
const localVarPath = `/apiKey/authenticate`;
|
|
3041
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
3042
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
3043
|
+
let baseOptions;
|
|
3044
|
+
if (configuration) {
|
|
3045
|
+
baseOptions = configuration.baseOptions;
|
|
3046
|
+
}
|
|
3047
|
+
|
|
3048
|
+
const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};
|
|
3049
|
+
const localVarHeaderParameter = {} as any;
|
|
3050
|
+
const localVarQueryParameter = {} as any;
|
|
3051
|
+
|
|
3052
|
+
// authentication ApiKeyAuth required
|
|
3053
|
+
await setApiKeyToObject(localVarHeaderParameter, "Authorization", configuration)
|
|
3054
|
+
|
|
3055
|
+
|
|
3056
|
+
|
|
3057
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
3058
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
3059
|
+
localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
|
|
3060
|
+
|
|
3061
|
+
return {
|
|
3062
|
+
url: toPathString(localVarUrlObj),
|
|
3063
|
+
options: localVarRequestOptions,
|
|
3064
|
+
};
|
|
3065
|
+
},
|
|
3013
3066
|
/**
|
|
3014
3067
|
* Create an Automation API key (optional org association). Requires CreateGlobalAPIKey. Raw secret is returned once.
|
|
3015
3068
|
* @summary Create global API key
|
|
@@ -3206,6 +3259,18 @@ export const APIKeysApiAxiosParamCreator = function (configuration?: Configurati
|
|
|
3206
3259
|
export const APIKeysApiFp = function(configuration?: Configuration) {
|
|
3207
3260
|
const localVarAxiosParamCreator = APIKeysApiAxiosParamCreator(configuration)
|
|
3208
3261
|
return {
|
|
3262
|
+
/**
|
|
3263
|
+
* Authenticates the presented Automation API key (x-api-key or Authorization: ApiKey <key>) and returns status only: 200 when the key is active and not expired, 401 otherwise. Not authenticated by cookie/JWT sessions.
|
|
3264
|
+
* @summary Authenticate API key
|
|
3265
|
+
* @param {*} [options] Override http request option.
|
|
3266
|
+
* @throws {RequiredError}
|
|
3267
|
+
*/
|
|
3268
|
+
async authenticateApiKey(options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<AuthenticateApiKey200Response>> {
|
|
3269
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.authenticateApiKey(options);
|
|
3270
|
+
const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
|
|
3271
|
+
const localVarOperationServerBasePath = operationServerMap['APIKeysApi.authenticateApiKey']?.[localVarOperationServerIndex]?.url;
|
|
3272
|
+
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
3273
|
+
},
|
|
3209
3274
|
/**
|
|
3210
3275
|
* Create an Automation API key (optional org association). Requires CreateGlobalAPIKey. Raw secret is returned once.
|
|
3211
3276
|
* @summary Create global API key
|
|
@@ -3281,6 +3346,15 @@ export const APIKeysApiFp = function(configuration?: Configuration) {
|
|
|
3281
3346
|
export const APIKeysApiFactory = function (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) {
|
|
3282
3347
|
const localVarFp = APIKeysApiFp(configuration)
|
|
3283
3348
|
return {
|
|
3349
|
+
/**
|
|
3350
|
+
* Authenticates the presented Automation API key (x-api-key or Authorization: ApiKey <key>) and returns status only: 200 when the key is active and not expired, 401 otherwise. Not authenticated by cookie/JWT sessions.
|
|
3351
|
+
* @summary Authenticate API key
|
|
3352
|
+
* @param {*} [options] Override http request option.
|
|
3353
|
+
* @throws {RequiredError}
|
|
3354
|
+
*/
|
|
3355
|
+
authenticateApiKey(options?: RawAxiosRequestConfig): AxiosPromise<AuthenticateApiKey200Response> {
|
|
3356
|
+
return localVarFp.authenticateApiKey(options).then((request) => request(axios, basePath));
|
|
3357
|
+
},
|
|
3284
3358
|
/**
|
|
3285
3359
|
* Create an Automation API key (optional org association). Requires CreateGlobalAPIKey. Raw secret is returned once.
|
|
3286
3360
|
* @summary Create global API key
|
|
@@ -3341,6 +3415,17 @@ export const APIKeysApiFactory = function (configuration?: Configuration, basePa
|
|
|
3341
3415
|
* @extends {BaseAPI}
|
|
3342
3416
|
*/
|
|
3343
3417
|
export class APIKeysApi extends BaseAPI {
|
|
3418
|
+
/**
|
|
3419
|
+
* Authenticates the presented Automation API key (x-api-key or Authorization: ApiKey <key>) and returns status only: 200 when the key is active and not expired, 401 otherwise. Not authenticated by cookie/JWT sessions.
|
|
3420
|
+
* @summary Authenticate API key
|
|
3421
|
+
* @param {*} [options] Override http request option.
|
|
3422
|
+
* @throws {RequiredError}
|
|
3423
|
+
* @memberof APIKeysApi
|
|
3424
|
+
*/
|
|
3425
|
+
public authenticateApiKey(options?: RawAxiosRequestConfig) {
|
|
3426
|
+
return APIKeysApiFp(this.configuration).authenticateApiKey(options).then((request) => request(this.axios, this.basePath));
|
|
3427
|
+
}
|
|
3428
|
+
|
|
3344
3429
|
/**
|
|
3345
3430
|
* Create an Automation API key (optional org association). Requires CreateGlobalAPIKey. Raw secret is returned once.
|
|
3346
3431
|
* @summary Create global API key
|
package/configuration.ts
CHANGED
|
@@ -100,7 +100,7 @@ export class Configuration {
|
|
|
100
100
|
|
|
101
101
|
const extraHeaders = param.useDefaultUserAgent ? {} : {
|
|
102
102
|
headers: {
|
|
103
|
-
"user-agent": "Flipdish authorization typescript SDK / 0.2.
|
|
103
|
+
"user-agent": "Flipdish authorization typescript SDK / 0.2.53"
|
|
104
104
|
}
|
|
105
105
|
};
|
|
106
106
|
|
package/dist/api.d.ts
CHANGED
|
@@ -400,6 +400,23 @@ export interface AuthenticateAndCheckIsInRoleResponseAuthentication {
|
|
|
400
400
|
*/
|
|
401
401
|
'reason'?: string;
|
|
402
402
|
}
|
|
403
|
+
/**
|
|
404
|
+
*
|
|
405
|
+
* @export
|
|
406
|
+
* @interface AuthenticateApiKey200Response
|
|
407
|
+
*/
|
|
408
|
+
export interface AuthenticateApiKey200Response {
|
|
409
|
+
/**
|
|
410
|
+
*
|
|
411
|
+
* @type {boolean}
|
|
412
|
+
* @memberof AuthenticateApiKey200Response
|
|
413
|
+
*/
|
|
414
|
+
'ok': AuthenticateApiKey200ResponseOkEnum;
|
|
415
|
+
}
|
|
416
|
+
export declare const AuthenticateApiKey200ResponseOkEnum: {
|
|
417
|
+
readonly True: true;
|
|
418
|
+
};
|
|
419
|
+
export type AuthenticateApiKey200ResponseOkEnum = typeof AuthenticateApiKey200ResponseOkEnum[keyof typeof AuthenticateApiKey200ResponseOkEnum];
|
|
403
420
|
/**
|
|
404
421
|
*
|
|
405
422
|
* @export
|
|
@@ -544,7 +561,7 @@ export type AuthorizationBatchResponseAllowedResourcesInnerResource = Authorizat
|
|
|
544
561
|
*/
|
|
545
562
|
export interface AuthorizationChecksBatchRequest {
|
|
546
563
|
/**
|
|
547
|
-
* Principal/resource/action tuples to check authorisation for
|
|
564
|
+
* Principal/resource/action tuples to check authorisation for. Checks that share a principal or a resource are evaluated most efficiently; batches spanning too many distinct combinations are rejected with a 400.
|
|
548
565
|
* @type {Array<AuthorizationChecksBatchRequestChecksInner>}
|
|
549
566
|
* @memberof AuthorizationChecksBatchRequest
|
|
550
567
|
*/
|
|
@@ -2888,6 +2905,13 @@ export interface UpdateGlobalApiKeyRequest {
|
|
|
2888
2905
|
* @export
|
|
2889
2906
|
*/
|
|
2890
2907
|
export declare const APIKeysApiAxiosParamCreator: (configuration?: Configuration) => {
|
|
2908
|
+
/**
|
|
2909
|
+
* Authenticates the presented Automation API key (x-api-key or Authorization: ApiKey <key>) and returns status only: 200 when the key is active and not expired, 401 otherwise. Not authenticated by cookie/JWT sessions.
|
|
2910
|
+
* @summary Authenticate API key
|
|
2911
|
+
* @param {*} [options] Override http request option.
|
|
2912
|
+
* @throws {RequiredError}
|
|
2913
|
+
*/
|
|
2914
|
+
authenticateApiKey: (options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
|
|
2891
2915
|
/**
|
|
2892
2916
|
* Create an Automation API key (optional org association). Requires CreateGlobalAPIKey. Raw secret is returned once.
|
|
2893
2917
|
* @summary Create global API key
|
|
@@ -2934,6 +2958,13 @@ export declare const APIKeysApiAxiosParamCreator: (configuration?: Configuration
|
|
|
2934
2958
|
* @export
|
|
2935
2959
|
*/
|
|
2936
2960
|
export declare const APIKeysApiFp: (configuration?: Configuration) => {
|
|
2961
|
+
/**
|
|
2962
|
+
* Authenticates the presented Automation API key (x-api-key or Authorization: ApiKey <key>) and returns status only: 200 when the key is active and not expired, 401 otherwise. Not authenticated by cookie/JWT sessions.
|
|
2963
|
+
* @summary Authenticate API key
|
|
2964
|
+
* @param {*} [options] Override http request option.
|
|
2965
|
+
* @throws {RequiredError}
|
|
2966
|
+
*/
|
|
2967
|
+
authenticateApiKey(options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<AuthenticateApiKey200Response>>;
|
|
2937
2968
|
/**
|
|
2938
2969
|
* Create an Automation API key (optional org association). Requires CreateGlobalAPIKey. Raw secret is returned once.
|
|
2939
2970
|
* @summary Create global API key
|
|
@@ -2980,6 +3011,13 @@ export declare const APIKeysApiFp: (configuration?: Configuration) => {
|
|
|
2980
3011
|
* @export
|
|
2981
3012
|
*/
|
|
2982
3013
|
export declare const APIKeysApiFactory: (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) => {
|
|
3014
|
+
/**
|
|
3015
|
+
* Authenticates the presented Automation API key (x-api-key or Authorization: ApiKey <key>) and returns status only: 200 when the key is active and not expired, 401 otherwise. Not authenticated by cookie/JWT sessions.
|
|
3016
|
+
* @summary Authenticate API key
|
|
3017
|
+
* @param {*} [options] Override http request option.
|
|
3018
|
+
* @throws {RequiredError}
|
|
3019
|
+
*/
|
|
3020
|
+
authenticateApiKey(options?: RawAxiosRequestConfig): AxiosPromise<AuthenticateApiKey200Response>;
|
|
2983
3021
|
/**
|
|
2984
3022
|
* Create an Automation API key (optional org association). Requires CreateGlobalAPIKey. Raw secret is returned once.
|
|
2985
3023
|
* @summary Create global API key
|
|
@@ -3028,6 +3066,14 @@ export declare const APIKeysApiFactory: (configuration?: Configuration, basePath
|
|
|
3028
3066
|
* @extends {BaseAPI}
|
|
3029
3067
|
*/
|
|
3030
3068
|
export declare class APIKeysApi extends BaseAPI {
|
|
3069
|
+
/**
|
|
3070
|
+
* Authenticates the presented Automation API key (x-api-key or Authorization: ApiKey <key>) and returns status only: 200 when the key is active and not expired, 401 otherwise. Not authenticated by cookie/JWT sessions.
|
|
3071
|
+
* @summary Authenticate API key
|
|
3072
|
+
* @param {*} [options] Override http request option.
|
|
3073
|
+
* @throws {RequiredError}
|
|
3074
|
+
* @memberof APIKeysApi
|
|
3075
|
+
*/
|
|
3076
|
+
authenticateApiKey(options?: RawAxiosRequestConfig): Promise<import("axios").AxiosResponse<AuthenticateApiKey200Response, any, {}, any>>;
|
|
3031
3077
|
/**
|
|
3032
3078
|
* Create an Automation API key (optional org association). Requires CreateGlobalAPIKey. Raw secret is returned once.
|
|
3033
3079
|
* @summary Create global API key
|
package/dist/api.js
CHANGED
|
@@ -84,8 +84,8 @@ var __spreadArray = (this && this.__spreadArray) || function (to, from, pack) {
|
|
|
84
84
|
return to.concat(ar || Array.prototype.slice.call(from));
|
|
85
85
|
};
|
|
86
86
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
87
|
-
exports.
|
|
88
|
-
exports.UserPermissionsApi = exports.UserPermissionsApiFactory = exports.UserPermissionsApiFp = exports.UserPermissionsApiAxiosParamCreator = exports.UserManagementApi = exports.UserManagementApiFactory = exports.UserManagementApiFp = exports.UserManagementApiAxiosParamCreator = exports.ListMyTimedAccessGrantsStatusEnum = exports.TimedAccessApi = exports.TimedAccessApiFactory = exports.TimedAccessApiFp = exports.TimedAccessApiAxiosParamCreator = exports.RoleAssignmentApi = exports.RoleAssignmentApiFactory = exports.RoleAssignmentApiFp = exports.RoleAssignmentApiAxiosParamCreator = exports.ListPrincipalAccessBlocksTypeEnum = exports.GetPrincipalAccessBlockTypeEnum = exports.PrincipalAccessBlockApi = exports.PrincipalAccessBlockApiFactory = exports.PrincipalAccessBlockApiFp = exports.PrincipalAccessBlockApiAxiosParamCreator = exports.JoinAccessApi = exports.JoinAccessApiFactory = exports.JoinAccessApiFp = exports.JoinAccessApiAxiosParamCreator = exports.ConfigurationDataApi = exports.ConfigurationDataApiFactory = exports.ConfigurationDataApiFp = exports.ConfigurationDataApiAxiosParamCreator = exports.AuthorizedEntitiesApi = exports.AuthorizedEntitiesApiFactory = exports.AuthorizedEntitiesApiFp = exports.AuthorizedEntitiesApiAxiosParamCreator = exports.AuthorizationApi = void 0;
|
|
87
|
+
exports.AuthorizationApiFp = exports.AuthorizationApiAxiosParamCreator = exports.AuthenticationApi = exports.AuthenticationApiFactory = exports.AuthenticationApiFp = exports.AuthenticationApiAxiosParamCreator = exports.ListGlobalApiKeysStatusEnum = exports.APIKeysApi = exports.APIKeysApiFactory = exports.APIKeysApiFp = exports.APIKeysApiAxiosParamCreator = exports.UnblockPrincipalAccessResponseStatusEnum = exports.TimedAccessGrantResponseStatusEnum = exports.TimedAccessGrantResponsePrincipalTypeEnum = exports.TimedAccessGrantRequestBodyRoleNameEnum = exports.TimedAccessGrantStatusEnum = exports.TimedAccessGrantPrincipalTypeEnum = exports.RoleNames = exports.RoleAssignmentRequestBodyPrincipalTypeEnum = exports.RoleAssignmentRequestBodyActorTypeEnum = exports.RoleAssignmentRequestBodyRoleNameEnum = exports.RemoveTeammateRequestBodyPrincipalTypeEnum = exports.RemoveTeammateRequestBodyActorTypeEnum = exports.PrincipalInOrgTypeEnum = exports.Permissions = exports.ListOrgRolesSuccessResponseValueRolesEnum = exports.JoinAccessErrorResponseCodeEnum = exports.IsInRoleRequestCheckModeEnum = exports.InviteTokenResponseRoleNameEnum = exports.GlobalApiKeyStateResponseUpdatedStatusEnum = exports.GlobalApiKeyStateResponseRevokedStatusEnum = exports.GlobalApiKeyStateResponseStatusEnum = exports.GetUserPermissionsSuccessResponseResourcesValueResourceTypeEnum = exports.GetJoinAccessRequest200ResponseRoleNameEnum = exports.GetJoinAccessRequest200ResponseStateEnum = exports.GetAuthorizedOrgsRequestPrincipalTypeEnum = exports.AuthorizationRequestResourceOneOf3TypeEnum = exports.AuthorizationRequestResourceOneOf2TypeEnum = exports.AuthorizationRequestResourceOneOf1TypeEnum = exports.AuthorizationRequestResourceOneOfTypeEnum = exports.AuthorizationRequestPrincipalTypeEnum = exports.AuthorizationRequestCheckModeEnum = exports.AuthorizationBatchResponseAllowedResourcesInnerPrincipalTypeEnum = exports.AuthenticateApiKey200ResponseOkEnum = exports.AuthenticateAndCheckIsInRoleRequestCheckModeEnum = exports.AuthenticateAndAuthorizeRequestCheckModeEnum = exports.AccessRequestResponseRoleNameEnum = exports.AccessRequestResponseStateEnum = exports.AccessBlockStateResponseBlockedPrincipalTypeEnum = exports.AcceptJoinRequestRoleNameEnum = void 0;
|
|
88
|
+
exports.UserPermissionsApi = exports.UserPermissionsApiFactory = exports.UserPermissionsApiFp = exports.UserPermissionsApiAxiosParamCreator = exports.UserManagementApi = exports.UserManagementApiFactory = exports.UserManagementApiFp = exports.UserManagementApiAxiosParamCreator = exports.ListMyTimedAccessGrantsStatusEnum = exports.TimedAccessApi = exports.TimedAccessApiFactory = exports.TimedAccessApiFp = exports.TimedAccessApiAxiosParamCreator = exports.RoleAssignmentApi = exports.RoleAssignmentApiFactory = exports.RoleAssignmentApiFp = exports.RoleAssignmentApiAxiosParamCreator = exports.ListPrincipalAccessBlocksTypeEnum = exports.GetPrincipalAccessBlockTypeEnum = exports.PrincipalAccessBlockApi = exports.PrincipalAccessBlockApiFactory = exports.PrincipalAccessBlockApiFp = exports.PrincipalAccessBlockApiAxiosParamCreator = exports.JoinAccessApi = exports.JoinAccessApiFactory = exports.JoinAccessApiFp = exports.JoinAccessApiAxiosParamCreator = exports.ConfigurationDataApi = exports.ConfigurationDataApiFactory = exports.ConfigurationDataApiFp = exports.ConfigurationDataApiAxiosParamCreator = exports.AuthorizedEntitiesApi = exports.AuthorizedEntitiesApiFactory = exports.AuthorizedEntitiesApiFp = exports.AuthorizedEntitiesApiAxiosParamCreator = exports.AuthorizationApi = exports.AuthorizationApiFactory = void 0;
|
|
89
89
|
var axios_1 = require("axios");
|
|
90
90
|
// Some imports not used depending on template conditions
|
|
91
91
|
// @ts-ignore
|
|
@@ -134,6 +134,9 @@ exports.AuthenticateAndCheckIsInRoleRequestCheckModeEnum = {
|
|
|
134
134
|
Any: 'any',
|
|
135
135
|
All: 'all'
|
|
136
136
|
};
|
|
137
|
+
exports.AuthenticateApiKey200ResponseOkEnum = {
|
|
138
|
+
True: true
|
|
139
|
+
};
|
|
137
140
|
exports.AuthorizationBatchResponseAllowedResourcesInnerPrincipalTypeEnum = {
|
|
138
141
|
User: 'User',
|
|
139
142
|
Automation: 'Automation',
|
|
@@ -562,6 +565,47 @@ exports.UnblockPrincipalAccessResponseStatusEnum = {
|
|
|
562
565
|
var APIKeysApiAxiosParamCreator = function (configuration) {
|
|
563
566
|
var _this = this;
|
|
564
567
|
return {
|
|
568
|
+
/**
|
|
569
|
+
* Authenticates the presented Automation API key (x-api-key or Authorization: ApiKey <key>) and returns status only: 200 when the key is active and not expired, 401 otherwise. Not authenticated by cookie/JWT sessions.
|
|
570
|
+
* @summary Authenticate API key
|
|
571
|
+
* @param {*} [options] Override http request option.
|
|
572
|
+
* @throws {RequiredError}
|
|
573
|
+
*/
|
|
574
|
+
authenticateApiKey: function () {
|
|
575
|
+
var args_1 = [];
|
|
576
|
+
for (var _i = 0; _i < arguments.length; _i++) {
|
|
577
|
+
args_1[_i] = arguments[_i];
|
|
578
|
+
}
|
|
579
|
+
return __awaiter(_this, __spreadArray([], args_1, true), void 0, function (options) {
|
|
580
|
+
var localVarPath, localVarUrlObj, baseOptions, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
|
|
581
|
+
if (options === void 0) { options = {}; }
|
|
582
|
+
return __generator(this, function (_a) {
|
|
583
|
+
switch (_a.label) {
|
|
584
|
+
case 0:
|
|
585
|
+
localVarPath = "/apiKey/authenticate";
|
|
586
|
+
localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
|
|
587
|
+
if (configuration) {
|
|
588
|
+
baseOptions = configuration.baseOptions;
|
|
589
|
+
}
|
|
590
|
+
localVarRequestOptions = __assign(__assign({ method: 'GET' }, baseOptions), options);
|
|
591
|
+
localVarHeaderParameter = {};
|
|
592
|
+
localVarQueryParameter = {};
|
|
593
|
+
// authentication ApiKeyAuth required
|
|
594
|
+
return [4 /*yield*/, (0, common_1.setApiKeyToObject)(localVarHeaderParameter, "Authorization", configuration)];
|
|
595
|
+
case 1:
|
|
596
|
+
// authentication ApiKeyAuth required
|
|
597
|
+
_a.sent();
|
|
598
|
+
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
|
599
|
+
headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
600
|
+
localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
601
|
+
return [2 /*return*/, {
|
|
602
|
+
url: (0, common_1.toPathString)(localVarUrlObj),
|
|
603
|
+
options: localVarRequestOptions,
|
|
604
|
+
}];
|
|
605
|
+
}
|
|
606
|
+
});
|
|
607
|
+
});
|
|
608
|
+
},
|
|
565
609
|
/**
|
|
566
610
|
* Create an Automation API key (optional org association). Requires CreateGlobalAPIKey. Raw secret is returned once.
|
|
567
611
|
* @summary Create global API key
|
|
@@ -795,6 +839,28 @@ exports.APIKeysApiAxiosParamCreator = APIKeysApiAxiosParamCreator;
|
|
|
795
839
|
var APIKeysApiFp = function (configuration) {
|
|
796
840
|
var localVarAxiosParamCreator = (0, exports.APIKeysApiAxiosParamCreator)(configuration);
|
|
797
841
|
return {
|
|
842
|
+
/**
|
|
843
|
+
* Authenticates the presented Automation API key (x-api-key or Authorization: ApiKey <key>) and returns status only: 200 when the key is active and not expired, 401 otherwise. Not authenticated by cookie/JWT sessions.
|
|
844
|
+
* @summary Authenticate API key
|
|
845
|
+
* @param {*} [options] Override http request option.
|
|
846
|
+
* @throws {RequiredError}
|
|
847
|
+
*/
|
|
848
|
+
authenticateApiKey: function (options) {
|
|
849
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
850
|
+
var localVarAxiosArgs, localVarOperationServerIndex, localVarOperationServerBasePath;
|
|
851
|
+
var _a, _b, _c;
|
|
852
|
+
return __generator(this, function (_d) {
|
|
853
|
+
switch (_d.label) {
|
|
854
|
+
case 0: return [4 /*yield*/, localVarAxiosParamCreator.authenticateApiKey(options)];
|
|
855
|
+
case 1:
|
|
856
|
+
localVarAxiosArgs = _d.sent();
|
|
857
|
+
localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
|
|
858
|
+
localVarOperationServerBasePath = (_c = (_b = base_1.operationServerMap['APIKeysApi.authenticateApiKey']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
|
|
859
|
+
return [2 /*return*/, function (axios, basePath) { return (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }];
|
|
860
|
+
}
|
|
861
|
+
});
|
|
862
|
+
});
|
|
863
|
+
},
|
|
798
864
|
/**
|
|
799
865
|
* Create an Automation API key (optional org association). Requires CreateGlobalAPIKey. Raw secret is returned once.
|
|
800
866
|
* @summary Create global API key
|
|
@@ -920,6 +986,15 @@ exports.APIKeysApiFp = APIKeysApiFp;
|
|
|
920
986
|
var APIKeysApiFactory = function (configuration, basePath, axios) {
|
|
921
987
|
var localVarFp = (0, exports.APIKeysApiFp)(configuration);
|
|
922
988
|
return {
|
|
989
|
+
/**
|
|
990
|
+
* Authenticates the presented Automation API key (x-api-key or Authorization: ApiKey <key>) and returns status only: 200 when the key is active and not expired, 401 otherwise. Not authenticated by cookie/JWT sessions.
|
|
991
|
+
* @summary Authenticate API key
|
|
992
|
+
* @param {*} [options] Override http request option.
|
|
993
|
+
* @throws {RequiredError}
|
|
994
|
+
*/
|
|
995
|
+
authenticateApiKey: function (options) {
|
|
996
|
+
return localVarFp.authenticateApiKey(options).then(function (request) { return request(axios, basePath); });
|
|
997
|
+
},
|
|
923
998
|
/**
|
|
924
999
|
* Create an Automation API key (optional org association). Requires CreateGlobalAPIKey. Raw secret is returned once.
|
|
925
1000
|
* @summary Create global API key
|
|
@@ -984,6 +1059,17 @@ var APIKeysApi = /** @class */ (function (_super) {
|
|
|
984
1059
|
function APIKeysApi() {
|
|
985
1060
|
return _super !== null && _super.apply(this, arguments) || this;
|
|
986
1061
|
}
|
|
1062
|
+
/**
|
|
1063
|
+
* Authenticates the presented Automation API key (x-api-key or Authorization: ApiKey <key>) and returns status only: 200 when the key is active and not expired, 401 otherwise. Not authenticated by cookie/JWT sessions.
|
|
1064
|
+
* @summary Authenticate API key
|
|
1065
|
+
* @param {*} [options] Override http request option.
|
|
1066
|
+
* @throws {RequiredError}
|
|
1067
|
+
* @memberof APIKeysApi
|
|
1068
|
+
*/
|
|
1069
|
+
APIKeysApi.prototype.authenticateApiKey = function (options) {
|
|
1070
|
+
var _this = this;
|
|
1071
|
+
return (0, exports.APIKeysApiFp)(this.configuration).authenticateApiKey(options).then(function (request) { return request(_this.axios, _this.basePath); });
|
|
1072
|
+
};
|
|
987
1073
|
/**
|
|
988
1074
|
* Create an Automation API key (optional org association). Requires CreateGlobalAPIKey. Raw secret is returned once.
|
|
989
1075
|
* @summary Create global API key
|
package/dist/configuration.js
CHANGED
|
@@ -36,7 +36,7 @@ var Configuration = /** @class */ (function () {
|
|
|
36
36
|
this.serverIndex = param.serverIndex;
|
|
37
37
|
var extraHeaders = param.useDefaultUserAgent ? {} : {
|
|
38
38
|
headers: {
|
|
39
|
-
"user-agent": "Flipdish authorization typescript SDK / 0.2.
|
|
39
|
+
"user-agent": "Flipdish authorization typescript SDK / 0.2.53"
|
|
40
40
|
}
|
|
41
41
|
};
|
|
42
42
|
this.baseOptions = __assign(__assign({}, extraHeaders), param.baseOptions);
|