Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .openapi-generator/FILES
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,7 @@ model/modify-integration-request.ts
model/operation-type.ts
model/organization-admin-model.ts
model/organization-invitation-model.ts
model/organization-limitations.ts
model/organization-member-model.ts
model/organization-members-model.ts
model/organization-model.ts
Expand All @@ -95,9 +96,13 @@ model/organization-permission-model.ts
model/organization-product-model.ts
model/percentage-option-model.ts
model/permission-group-model.ts
model/predefined-variation-environment-model.ts
model/predefined-variation-model.ts
model/predefined-variation-usage-model.ts
model/predefined-variation-value-model.ts
model/predefined-variation-with-usages-model.ts
model/predefined-variations-model.ts
model/predefined-variations-with-usages-model.ts
model/preferences-model.ts
model/prerequisite-comparator.ts
model/prerequisite-flag-condition-model.ts
Expand Down
75 changes: 75 additions & 0 deletions api/feature-flags-settings-api.ts
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,8 @@ import { JsonPatchOperation } from '../model';
// @ts-ignore
import { PredefinedVariationsModel } from '../model';
// @ts-ignore
import { PredefinedVariationsWithUsagesModel } from '../model';
// @ts-ignore
import { ReplaceSettingModel } from '../model';
// @ts-ignore
import { SettingModel } from '../model';
Expand Down Expand Up @@ -112,6 +114,44 @@ export const FeatureFlagsSettingsApiAxiosParamCreator = function (configuration?



setSearchParams(localVarUrlObj, localVarQueryParameter);
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};

return {
url: toPathString(localVarUrlObj),
options: localVarRequestOptions,
};
},
/**
* This endpoint returns the predefined variations along with their usages in the Environments for a Feature Flag or Setting identified by the `settingId` parameter. **Beta feature:** The feature is currently in closed beta state and cannot be used.
* @summary Get predefined variations (Beta)
* @param {number} settingId The identifier of the Setting.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
getPredefinedVariations: async (settingId: number, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
// verify required parameter 'settingId' is not null or undefined
assertParamExists('getPredefinedVariations', 'settingId', settingId)
const localVarPath = `/v1/settings/{settingId}/predefined-variations`
.replace(`{${"settingId"}}`, encodeURIComponent(String(settingId)));
// use dummy base URL string because the URL constructor only accepts absolute URLs.
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
let baseOptions;
if (configuration) {
baseOptions = configuration.baseOptions;
}

const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};
const localVarHeaderParameter = {} as any;
const localVarQueryParameter = {} as any;

// authentication Basic required
// http basic authentication required
setBasicAuthToObject(localVarRequestOptions, configuration)



setSearchParams(localVarUrlObj, localVarQueryParameter);
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
Expand Down Expand Up @@ -366,6 +406,19 @@ export const FeatureFlagsSettingsApiFp = function(configuration?: Configuration)
const localVarOperationServerBasePath = operationServerMap['FeatureFlagsSettingsApi.deleteSetting']?.[localVarOperationServerIndex]?.url;
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
},
/**
* This endpoint returns the predefined variations along with their usages in the Environments for a Feature Flag or Setting identified by the `settingId` parameter. **Beta feature:** The feature is currently in closed beta state and cannot be used.
* @summary Get predefined variations (Beta)
* @param {number} settingId The identifier of the Setting.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
async getPredefinedVariations(settingId: number, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<PredefinedVariationsWithUsagesModel>> {
const localVarAxiosArgs = await localVarAxiosParamCreator.getPredefinedVariations(settingId, options);
const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
const localVarOperationServerBasePath = operationServerMap['FeatureFlagsSettingsApi.getPredefinedVariations']?.[localVarOperationServerIndex]?.url;
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
},
/**
* This endpoint returns the metadata attributes of a Feature Flag or Setting identified by the `settingId` parameter.
* @summary Get Flag
Expand Down Expand Up @@ -465,6 +518,16 @@ export const FeatureFlagsSettingsApiFactory = function (configuration?: Configur
deleteSetting(settingId: number, options?: any): AxiosPromise<void> {
return localVarFp.deleteSetting(settingId, options).then((request) => request(axios, basePath));
},
/**
* This endpoint returns the predefined variations along with their usages in the Environments for a Feature Flag or Setting identified by the `settingId` parameter. **Beta feature:** The feature is currently in closed beta state and cannot be used.
* @summary Get predefined variations (Beta)
* @param {number} settingId The identifier of the Setting.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
getPredefinedVariations(settingId: number, options?: any): AxiosPromise<PredefinedVariationsWithUsagesModel> {
return localVarFp.getPredefinedVariations(settingId, options).then((request) => request(axios, basePath));
},
/**
* This endpoint returns the metadata attributes of a Feature Flag or Setting identified by the `settingId` parameter.
* @summary Get Flag
Expand Down Expand Up @@ -553,6 +616,18 @@ export class FeatureFlagsSettingsApi extends BaseAPI {
return FeatureFlagsSettingsApiFp(this.configuration).deleteSetting(settingId, options).then((request) => request(this.axios, this.basePath));
}

/**
* This endpoint returns the predefined variations along with their usages in the Environments for a Feature Flag or Setting identified by the `settingId` parameter. **Beta feature:** The feature is currently in closed beta state and cannot be used.
* @summary Get predefined variations (Beta)
* @param {number} settingId The identifier of the Setting.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof FeatureFlagsSettingsApi
*/
public getPredefinedVariations(settingId: number, options?: RawAxiosRequestConfig) {
return FeatureFlagsSettingsApiFp(this.configuration).getPredefinedVariations(settingId, options).then((request) => request(this.axios, this.basePath));
}

/**
* This endpoint returns the metadata attributes of a Feature Flag or Setting identified by the `settingId` parameter.
* @summary Get Flag
Expand Down
75 changes: 75 additions & 0 deletions api/organizations-api.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,13 +22,53 @@ import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObj
// @ts-ignore
import { BASE_PATH, COLLECTION_FORMATS, RequestArgs, BaseAPI, RequiredError, operationServerMap } from '../base';
// @ts-ignore
import { OrganizationLimitations } from '../model';
// @ts-ignore
import { OrganizationModel } from '../model';
/**
* OrganizationsApi - axios parameter creator
* @export
*/
export const OrganizationsApiAxiosParamCreator = function (configuration?: Configuration) {
return {
/**
* This endpoint returns the limitations of an Organization identified by the `organizationId`.
* @summary Get Organization limitations
* @param {string} organizationId The identifier of the Organization.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
getOrganizationLimitations: async (organizationId: string, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
// verify required parameter 'organizationId' is not null or undefined
assertParamExists('getOrganizationLimitations', 'organizationId', organizationId)
const localVarPath = `/v1/organizations/{organizationId}/organization-limitations`
.replace(`{${"organizationId"}}`, encodeURIComponent(String(organizationId)));
// use dummy base URL string because the URL constructor only accepts absolute URLs.
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
let baseOptions;
if (configuration) {
baseOptions = configuration.baseOptions;
}

const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};
const localVarHeaderParameter = {} as any;
const localVarQueryParameter = {} as any;

// authentication Basic required
// http basic authentication required
setBasicAuthToObject(localVarRequestOptions, configuration)



setSearchParams(localVarUrlObj, localVarQueryParameter);
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};

return {
url: toPathString(localVarUrlObj),
options: localVarRequestOptions,
};
},
/**
* This endpoint returns the list of the Organizations that belongs to the user.
* @summary List Organizations
Expand Down Expand Up @@ -73,6 +113,19 @@ export const OrganizationsApiAxiosParamCreator = function (configuration?: Confi
export const OrganizationsApiFp = function(configuration?: Configuration) {
const localVarAxiosParamCreator = OrganizationsApiAxiosParamCreator(configuration)
return {
/**
* This endpoint returns the limitations of an Organization identified by the `organizationId`.
* @summary Get Organization limitations
* @param {string} organizationId The identifier of the Organization.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
async getOrganizationLimitations(organizationId: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<OrganizationLimitations>> {
const localVarAxiosArgs = await localVarAxiosParamCreator.getOrganizationLimitations(organizationId, options);
const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
const localVarOperationServerBasePath = operationServerMap['OrganizationsApi.getOrganizationLimitations']?.[localVarOperationServerIndex]?.url;
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
},
/**
* This endpoint returns the list of the Organizations that belongs to the user.
* @summary List Organizations
Expand All @@ -95,6 +148,16 @@ export const OrganizationsApiFp = function(configuration?: Configuration) {
export const OrganizationsApiFactory = function (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) {
const localVarFp = OrganizationsApiFp(configuration)
return {
/**
* This endpoint returns the limitations of an Organization identified by the `organizationId`.
* @summary Get Organization limitations
* @param {string} organizationId The identifier of the Organization.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
getOrganizationLimitations(organizationId: string, options?: any): AxiosPromise<OrganizationLimitations> {
return localVarFp.getOrganizationLimitations(organizationId, options).then((request) => request(axios, basePath));
},
/**
* This endpoint returns the list of the Organizations that belongs to the user.
* @summary List Organizations
Expand All @@ -114,6 +177,18 @@ export const OrganizationsApiFactory = function (configuration?: Configuration,
* @extends {BaseAPI}
*/
export class OrganizationsApi extends BaseAPI {
/**
* This endpoint returns the limitations of an Organization identified by the `organizationId`.
* @summary Get Organization limitations
* @param {string} organizationId The identifier of the Organization.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof OrganizationsApi
*/
public getOrganizationLimitations(organizationId: string, options?: RawAxiosRequestConfig) {
return OrganizationsApiFp(this.configuration).getOrganizationLimitations(organizationId, options).then((request) => request(this.axios, this.basePath));
}

/**
* This endpoint returns the list of the Organizations that belongs to the user.
* @summary List Organizations
Expand Down
2 changes: 1 addition & 1 deletion model/environment-access-model.ts
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ export interface EnvironmentAccessModel {
* @type {string}
* @memberof EnvironmentAccessModel
*/
'name': string | null;
'name': string;
/**
* Color of the Environment.
* @type {string}
Expand Down
5 changes: 5 additions & 0 deletions model/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@ export * from './modify-integration-request';
export * from './operation-type';
export * from './organization-admin-model';
export * from './organization-invitation-model';
export * from './organization-limitations';
export * from './organization-member-model';
export * from './organization-members-model';
export * from './organization-model';
Expand All @@ -64,9 +65,13 @@ export * from './organization-permission-model';
export * from './organization-product-model';
export * from './percentage-option-model';
export * from './permission-group-model';
export * from './predefined-variation-environment-model';
export * from './predefined-variation-model';
export * from './predefined-variation-usage-model';
export * from './predefined-variation-value-model';
export * from './predefined-variation-with-usages-model';
export * from './predefined-variations-model';
export * from './predefined-variations-with-usages-model';
export * from './preferences-model';
export * from './prerequisite-comparator';
export * from './prerequisite-flag-condition-model';
Expand Down
72 changes: 72 additions & 0 deletions model/organization-limitations.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,72 @@
/* tslint:disable */
/* eslint-disable */
/**
* ConfigCat Public Management API
* The purpose of this API is to access the ConfigCat platform programmatically. You can **Create**, **Read**, **Update** and **Delete** any entities like **Feature Flags, Configs, Environments** or **Products** within ConfigCat. **Base API URL**: https://api.configcat.com If you prefer the swagger documentation, you can find it here: [Swagger UI](https://api.configcat.com/swagger). The API is based on HTTP REST, uses resource-oriented URLs, status codes and supports JSON format. **Important:** Do not use this API for accessing and evaluating feature flag values. Use the [SDKs](https://configcat.com/docs/sdk-reference/overview) or the [ConfigCat Proxy](https://configcat.com/docs/advanced/proxy/proxy-overview/) instead. # OpenAPI Specification The complete specification is publicly available in the following formats: - [OpenAPI v3](https://api.configcat.com/docs/v1/swagger.json) - [Swagger v2](https://api.configcat.com/docs/v1/swagger.v2.json) You can use it to generate client libraries in various languages with [OpenAPI Generator](https://github.com/OpenAPITools/openapi-generator) or [Swagger Codegen](https://swagger.io/tools/swagger-codegen/) to interact with this API. # Authentication This API uses the [Basic HTTP Authentication Scheme](https://en.wikipedia.org/wiki/Basic_access_authentication). <!-- ReDoc-Inject: <security-definitions> --> # Throttling and rate limits All the rate limited API calls are returning information about the current rate limit period in the following HTTP headers: | Header | Description | | :- | :- | | X-Rate-Limit-Remaining | The maximum number of requests remaining in the current rate limit period. | | X-Rate-Limit-Reset | The time when the current rate limit period resets. | When the rate limit is exceeded by a request, the API returns with a `HTTP 429 - Too many requests` status along with a `Retry-After` HTTP header.
*
* The version of the OpenAPI document: v1
* Contact: support@configcat.com
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/



/**
*
* @export
* @interface OrganizationLimitations
*/
export interface OrganizationLimitations {
/**
* Maximum number of percentage options a Feature Flag or Setting can have within a targeting rule.
* @type {number}
* @memberof OrganizationLimitations
*/
'maxPercentageOptionCount': number;
/**
* Maximum number of targeting rules a Feature Flag or Setting can have.
* @type {number}
* @memberof OrganizationLimitations
*/
'maxTargetingRuleCount': number;
/**
* Maximum length of a text comparison value.
* @type {number}
* @memberof OrganizationLimitations
*/
'maxComparisonValueLength': number;
/**
* Maximum item count of a list comparison value.
* @type {number}
* @memberof OrganizationLimitations
*/
'maxComparisonValueListLength': number;
/**
* Maximum length of a list comparison value\'s item.
* @type {number}
* @memberof OrganizationLimitations
*/
'maxComparisonValueListItemLength': number;
/**
* Maximum length of a text Setting\'s value.
* @type {number}
* @memberof OrganizationLimitations
*/
'maxStringFlagValueLength': number;
/**
* Maximum number of `AND` conditions a Feature Flag or Setting can have within a targeting rule.
* @type {number}
* @memberof OrganizationLimitations
*/
'maxConditionPerTargetingRuleCount': number;
/**
* The maximum number of predefined variations allowed for a Feature Flag or Setting.
* @type {number}
* @memberof OrganizationLimitations
*/
'maxPredefinedVariations': number;
}

Loading