/** * Permit.io API * Authorization as a service * * The version of the OpenAPI document: 2.0.0 * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech * Do not edit the class manually. */ import { AxiosPromise, AxiosInstance, AxiosRequestConfig } from 'axios'; import { Configuration } from '../configuration'; import { RequestArgs, BaseAPI } from '../base'; import { APIKeyCreate } from '../types'; import { APIKeyRead } from '../types'; import { APIKeyScopeRead } from '../types'; import { MemberAccessObj } from '../types'; import { PaginatedResultAPIKeyRead } from '../types'; /** * APIKeysApi - axios parameter creator * @export */ export declare const APIKeysApiAxiosParamCreator: (configuration?: Configuration) => { /** * Creates a new api_key under the active organization. * @summary Create Api Key * @param {APIKeyCreate} aPIKeyCreate * @param {*} [options] Override http request option. * @throws {RequiredError} */ createApiKey: (aPIKeyCreate: APIKeyCreate, options?: AxiosRequestConfig) => Promise; /** * Deletes the api_key and all its related data. * @summary Delete Api Key * @param {string} apiKeyId The unique id of the API key * @param {*} [options] Override http request option. * @throws {RequiredError} */ deleteApiKey: (apiKeyId: string, options?: AxiosRequestConfig) => Promise; /** * Gets a single api_key matching the given api_key_id, if such api_key exists. * @summary Get Api Key * @param {string} apiKeyId The unique id of the API key * @param {*} [options] Override http request option. * @throws {RequiredError} */ getApiKey: (apiKeyId: string, options?: AxiosRequestConfig) => Promise; /** * * @summary Get Api Key Scope * @param {*} [options] Override http request option. * @throws {RequiredError} */ getApiKeyScope: (options?: AxiosRequestConfig) => Promise; /** * * @summary Get Environment Api Key * @param {string} projId Either the unique id of the project, or the URL-friendly key of the project (i.e: the \"slug\"). * @param {string} envId Either the unique id of the environment, or the URL-friendly key of the environment (i.e: the \"slug\"). * @param {*} [options] Override http request option. * @throws {RequiredError} */ getEnvironmentApiKey: (projId: string, envId: string, options?: AxiosRequestConfig) => Promise; /** * Lists all the api_keys under the active organization. * @summary List Api Keys * @param {MemberAccessObj} [objectType] * @param {number} [page] Page number of the results to fetch, starting at 1. * @param {number} [perPage] The number of results per page (max 100). * @param {*} [options] Override http request option. * @throws {RequiredError} */ listApiKeys: (objectType?: MemberAccessObj, page?: number, perPage?: number, options?: AxiosRequestConfig) => Promise; /** * Rotates the API key of the PDP container with id `pdp_id`. The rotation of the API key revokes the old API key and issues a new API key to the PDP. * @summary Rotate API Key * @param {string} apiKeyId The unique id of the API key * @param {*} [options] Override http request option. * @throws {RequiredError} */ rotateApiKey: (apiKeyId: string, options?: AxiosRequestConfig) => Promise; }; /** * APIKeysApi - functional programming interface * @export */ export declare const APIKeysApiFp: (configuration?: Configuration) => { /** * Creates a new api_key under the active organization. * @summary Create Api Key * @param {APIKeyCreate} aPIKeyCreate * @param {*} [options] Override http request option. * @throws {RequiredError} */ createApiKey(aPIKeyCreate: APIKeyCreate, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise>; /** * Deletes the api_key and all its related data. * @summary Delete Api Key * @param {string} apiKeyId The unique id of the API key * @param {*} [options] Override http request option. * @throws {RequiredError} */ deleteApiKey(apiKeyId: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise>; /** * Gets a single api_key matching the given api_key_id, if such api_key exists. * @summary Get Api Key * @param {string} apiKeyId The unique id of the API key * @param {*} [options] Override http request option. * @throws {RequiredError} */ getApiKey(apiKeyId: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise>; /** * * @summary Get Api Key Scope * @param {*} [options] Override http request option. * @throws {RequiredError} */ getApiKeyScope(options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise>; /** * * @summary Get Environment Api Key * @param {string} projId Either the unique id of the project, or the URL-friendly key of the project (i.e: the \"slug\"). * @param {string} envId Either the unique id of the environment, or the URL-friendly key of the environment (i.e: the \"slug\"). * @param {*} [options] Override http request option. * @throws {RequiredError} */ getEnvironmentApiKey(projId: string, envId: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise>; /** * Lists all the api_keys under the active organization. * @summary List Api Keys * @param {MemberAccessObj} [objectType] * @param {number} [page] Page number of the results to fetch, starting at 1. * @param {number} [perPage] The number of results per page (max 100). * @param {*} [options] Override http request option. * @throws {RequiredError} */ listApiKeys(objectType?: MemberAccessObj, page?: number, perPage?: number, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise>; /** * Rotates the API key of the PDP container with id `pdp_id`. The rotation of the API key revokes the old API key and issues a new API key to the PDP. * @summary Rotate API Key * @param {string} apiKeyId The unique id of the API key * @param {*} [options] Override http request option. * @throws {RequiredError} */ rotateApiKey(apiKeyId: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise>; }; /** * APIKeysApi - factory interface * @export */ export declare const APIKeysApiFactory: (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) => { /** * Creates a new api_key under the active organization. * @summary Create Api Key * @param {APIKeyCreate} aPIKeyCreate * @param {*} [options] Override http request option. * @throws {RequiredError} */ createApiKey(aPIKeyCreate: APIKeyCreate, options?: any): AxiosPromise; /** * Deletes the api_key and all its related data. * @summary Delete Api Key * @param {string} apiKeyId The unique id of the API key * @param {*} [options] Override http request option. * @throws {RequiredError} */ deleteApiKey(apiKeyId: string, options?: any): AxiosPromise; /** * Gets a single api_key matching the given api_key_id, if such api_key exists. * @summary Get Api Key * @param {string} apiKeyId The unique id of the API key * @param {*} [options] Override http request option. * @throws {RequiredError} */ getApiKey(apiKeyId: string, options?: any): AxiosPromise; /** * * @summary Get Api Key Scope * @param {*} [options] Override http request option. * @throws {RequiredError} */ getApiKeyScope(options?: any): AxiosPromise; /** * * @summary Get Environment Api Key * @param {string} projId Either the unique id of the project, or the URL-friendly key of the project (i.e: the \"slug\"). * @param {string} envId Either the unique id of the environment, or the URL-friendly key of the environment (i.e: the \"slug\"). * @param {*} [options] Override http request option. * @throws {RequiredError} */ getEnvironmentApiKey(projId: string, envId: string, options?: any): AxiosPromise; /** * Lists all the api_keys under the active organization. * @summary List Api Keys * @param {MemberAccessObj} [objectType] * @param {number} [page] Page number of the results to fetch, starting at 1. * @param {number} [perPage] The number of results per page (max 100). * @param {*} [options] Override http request option. * @throws {RequiredError} */ listApiKeys(objectType?: MemberAccessObj, page?: number, perPage?: number, options?: any): AxiosPromise; /** * Rotates the API key of the PDP container with id `pdp_id`. The rotation of the API key revokes the old API key and issues a new API key to the PDP. * @summary Rotate API Key * @param {string} apiKeyId The unique id of the API key * @param {*} [options] Override http request option. * @throws {RequiredError} */ rotateApiKey(apiKeyId: string, options?: any): AxiosPromise; }; /** * Request parameters for createApiKey operation in APIKeysApi. * @export * @interface APIKeysApiCreateApiKeyRequest */ export interface APIKeysApiCreateApiKeyRequest { /** * * @type {APIKeyCreate} * @memberof APIKeysApiCreateApiKey */ readonly aPIKeyCreate: APIKeyCreate; } /** * Request parameters for deleteApiKey operation in APIKeysApi. * @export * @interface APIKeysApiDeleteApiKeyRequest */ export interface APIKeysApiDeleteApiKeyRequest { /** * The unique id of the API key * @type {string} * @memberof APIKeysApiDeleteApiKey */ readonly apiKeyId: string; } /** * Request parameters for getApiKey operation in APIKeysApi. * @export * @interface APIKeysApiGetApiKeyRequest */ export interface APIKeysApiGetApiKeyRequest { /** * The unique id of the API key * @type {string} * @memberof APIKeysApiGetApiKey */ readonly apiKeyId: string; } /** * Request parameters for getEnvironmentApiKey operation in APIKeysApi. * @export * @interface APIKeysApiGetEnvironmentApiKeyRequest */ export interface APIKeysApiGetEnvironmentApiKeyRequest { /** * Either the unique id of the project, or the URL-friendly key of the project (i.e: the \"slug\"). * @type {string} * @memberof APIKeysApiGetEnvironmentApiKey */ readonly projId: string; /** * Either the unique id of the environment, or the URL-friendly key of the environment (i.e: the \"slug\"). * @type {string} * @memberof APIKeysApiGetEnvironmentApiKey */ readonly envId: string; } /** * Request parameters for listApiKeys operation in APIKeysApi. * @export * @interface APIKeysApiListApiKeysRequest */ export interface APIKeysApiListApiKeysRequest { /** * * @type {MemberAccessObj} * @memberof APIKeysApiListApiKeys */ readonly objectType?: MemberAccessObj; /** * Page number of the results to fetch, starting at 1. * @type {number} * @memberof APIKeysApiListApiKeys */ readonly page?: number; /** * The number of results per page (max 100). * @type {number} * @memberof APIKeysApiListApiKeys */ readonly perPage?: number; } /** * Request parameters for rotateApiKey operation in APIKeysApi. * @export * @interface APIKeysApiRotateApiKeyRequest */ export interface APIKeysApiRotateApiKeyRequest { /** * The unique id of the API key * @type {string} * @memberof APIKeysApiRotateApiKey */ readonly apiKeyId: string; } /** * APIKeysApi - object-oriented interface * @export * @class APIKeysApi * @extends {BaseAPI} */ export declare class APIKeysApi extends BaseAPI { /** * Creates a new api_key under the active organization. * @summary Create Api Key * @param {APIKeysApiCreateApiKeyRequest} requestParameters Request parameters. * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof APIKeysApi */ createApiKey(requestParameters: APIKeysApiCreateApiKeyRequest, options?: AxiosRequestConfig): Promise>; /** * Deletes the api_key and all its related data. * @summary Delete Api Key * @param {APIKeysApiDeleteApiKeyRequest} requestParameters Request parameters. * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof APIKeysApi */ deleteApiKey(requestParameters: APIKeysApiDeleteApiKeyRequest, options?: AxiosRequestConfig): Promise>; /** * Gets a single api_key matching the given api_key_id, if such api_key exists. * @summary Get Api Key * @param {APIKeysApiGetApiKeyRequest} requestParameters Request parameters. * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof APIKeysApi */ getApiKey(requestParameters: APIKeysApiGetApiKeyRequest, options?: AxiosRequestConfig): Promise>; /** * * @summary Get Api Key Scope * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof APIKeysApi */ getApiKeyScope(options?: AxiosRequestConfig): Promise>; /** * * @summary Get Environment Api Key * @param {APIKeysApiGetEnvironmentApiKeyRequest} requestParameters Request parameters. * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof APIKeysApi */ getEnvironmentApiKey(requestParameters: APIKeysApiGetEnvironmentApiKeyRequest, options?: AxiosRequestConfig): Promise>; /** * Lists all the api_keys under the active organization. * @summary List Api Keys * @param {APIKeysApiListApiKeysRequest} requestParameters Request parameters. * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof APIKeysApi */ listApiKeys(requestParameters?: APIKeysApiListApiKeysRequest, options?: AxiosRequestConfig): Promise>; /** * Rotates the API key of the PDP container with id `pdp_id`. The rotation of the API key revokes the old API key and issues a new API key to the PDP. * @summary Rotate API Key * @param {APIKeysApiRotateApiKeyRequest} requestParameters Request parameters. * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof APIKeysApi */ rotateApiKey(requestParameters: APIKeysApiRotateApiKeyRequest, options?: AxiosRequestConfig): Promise>; }