/* tslint:disable */
/* eslint-disable */
/**
 * Halo Next API
 * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
 *
 * 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 type { Configuration } from "../configuration";
import type { AxiosPromise, AxiosInstance, AxiosRequestConfig } from "axios";
import globalAxios from "axios";
// Some imports not used depending on template conditions
// @ts-ignore
import {
  DUMMY_BASE_URL,
  assertParamExists,
  setApiKeyToObject,
  setBasicAuthToObject,
  setBearerAuthToObject,
  setOAuthToObject,
  setSearchParams,
  serializeDataIfNeeded,
  toPathString,
  createRequestFunction,
} from "../common";
// @ts-ignore
import {
  BASE_PATH,
  COLLECTION_FORMATS,
  RequestArgs,
  BaseAPI,
  RequiredError,
} from "../base";
// @ts-ignore
import { RoleBinding } from "../models";
// @ts-ignore
import { RoleBindingList } from "../models";
/**
 * V1alpha1RoleBindingApi - axios parameter creator
 * @export
 */
export const V1alpha1RoleBindingApiAxiosParamCreator = function (
  configuration?: Configuration
) {
  return {
    /**
     * Create v1alpha1/RoleBinding
     * @param {RoleBinding} [roleBinding] Fresh rolebinding
     * @param {*} [options] Override http request option.
     * @throws {RequiredError}
     */
    createv1alpha1RoleBinding: async (
      roleBinding?: RoleBinding,
      options: AxiosRequestConfig = {}
    ): Promise<RequestArgs> => {
      const localVarPath = `/api/v1alpha1/rolebindings`;
      // 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: "POST",
        ...baseOptions,
        ...options,
      };
      const localVarHeaderParameter = {} as any;
      const localVarQueryParameter = {} as any;

      // authentication BasicAuth required
      // http basic authentication required
      setBasicAuthToObject(localVarRequestOptions, configuration);

      // authentication BearerAuth required
      // http bearer authentication required
      await setBearerAuthToObject(localVarHeaderParameter, configuration);

      localVarHeaderParameter["Content-Type"] = "application/json";

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

      return {
        url: toPathString(localVarUrlObj),
        options: localVarRequestOptions,
      };
    },
    /**
     * Delete v1alpha1/RoleBinding
     * @param {string} name Name of rolebinding
     * @param {*} [options] Override http request option.
     * @throws {RequiredError}
     */
    deletev1alpha1RoleBinding: async (
      name: string,
      options: AxiosRequestConfig = {}
    ): Promise<RequestArgs> => {
      // verify required parameter 'name' is not null or undefined
      assertParamExists("deletev1alpha1RoleBinding", "name", name);
      const localVarPath = `/api/v1alpha1/rolebindings/{name}`.replace(
        `{${"name"}}`,
        encodeURIComponent(String(name))
      );
      // 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: "DELETE",
        ...baseOptions,
        ...options,
      };
      const localVarHeaderParameter = {} as any;
      const localVarQueryParameter = {} as any;

      // authentication BasicAuth required
      // http basic authentication required
      setBasicAuthToObject(localVarRequestOptions, configuration);

      // authentication BearerAuth required
      // http bearer authentication required
      await setBearerAuthToObject(localVarHeaderParameter, configuration);

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

      return {
        url: toPathString(localVarUrlObj),
        options: localVarRequestOptions,
      };
    },
    /**
     * Get v1alpha1/RoleBinding
     * @param {string} name Name of rolebinding
     * @param {*} [options] Override http request option.
     * @throws {RequiredError}
     */
    getv1alpha1RoleBinding: async (
      name: string,
      options: AxiosRequestConfig = {}
    ): Promise<RequestArgs> => {
      // verify required parameter 'name' is not null or undefined
      assertParamExists("getv1alpha1RoleBinding", "name", name);
      const localVarPath = `/api/v1alpha1/rolebindings/{name}`.replace(
        `{${"name"}}`,
        encodeURIComponent(String(name))
      );
      // 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 BasicAuth required
      // http basic authentication required
      setBasicAuthToObject(localVarRequestOptions, configuration);

      // authentication BearerAuth required
      // http bearer authentication required
      await setBearerAuthToObject(localVarHeaderParameter, configuration);

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

      return {
        url: toPathString(localVarUrlObj),
        options: localVarRequestOptions,
      };
    },
    /**
     * List v1alpha1/RoleBinding
     * @param {Array<string>} [fieldSelector] Field selector for filtering.
     * @param {Array<string>} [labelSelector] Label selector for filtering.
     * @param {number} [page] The page number. Zero indicates no page.
     * @param {number} [size] Size of one page. Zero indicates no limit.
     * @param {Array<string>} [sort] Sort property and direction of the list result. Support sorting based on attribute name path.
     * @param {*} [options] Override http request option.
     * @throws {RequiredError}
     */
    listv1alpha1RoleBinding: async (
      fieldSelector?: Array<string>,
      labelSelector?: Array<string>,
      page?: number,
      size?: number,
      sort?: Array<string>,
      options: AxiosRequestConfig = {}
    ): Promise<RequestArgs> => {
      const localVarPath = `/api/v1alpha1/rolebindings`;
      // 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 BasicAuth required
      // http basic authentication required
      setBasicAuthToObject(localVarRequestOptions, configuration);

      // authentication BearerAuth required
      // http bearer authentication required
      await setBearerAuthToObject(localVarHeaderParameter, configuration);

      if (fieldSelector) {
        localVarQueryParameter["fieldSelector"] = fieldSelector;
      }

      if (labelSelector) {
        localVarQueryParameter["labelSelector"] = labelSelector;
      }

      if (page !== undefined) {
        localVarQueryParameter["page"] = page;
      }

      if (size !== undefined) {
        localVarQueryParameter["size"] = size;
      }

      if (sort) {
        localVarQueryParameter["sort"] = Array.from(sort);
      }

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

      return {
        url: toPathString(localVarUrlObj),
        options: localVarRequestOptions,
      };
    },
    /**
     * Update v1alpha1/RoleBinding
     * @param {string} name Name of rolebinding
     * @param {RoleBinding} [roleBinding] Updated rolebinding
     * @param {*} [options] Override http request option.
     * @throws {RequiredError}
     */
    updatev1alpha1RoleBinding: async (
      name: string,
      roleBinding?: RoleBinding,
      options: AxiosRequestConfig = {}
    ): Promise<RequestArgs> => {
      // verify required parameter 'name' is not null or undefined
      assertParamExists("updatev1alpha1RoleBinding", "name", name);
      const localVarPath = `/api/v1alpha1/rolebindings/{name}`.replace(
        `{${"name"}}`,
        encodeURIComponent(String(name))
      );
      // 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: "PUT",
        ...baseOptions,
        ...options,
      };
      const localVarHeaderParameter = {} as any;
      const localVarQueryParameter = {} as any;

      // authentication BasicAuth required
      // http basic authentication required
      setBasicAuthToObject(localVarRequestOptions, configuration);

      // authentication BearerAuth required
      // http bearer authentication required
      await setBearerAuthToObject(localVarHeaderParameter, configuration);

      localVarHeaderParameter["Content-Type"] = "application/json";

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

      return {
        url: toPathString(localVarUrlObj),
        options: localVarRequestOptions,
      };
    },
  };
};

/**
 * V1alpha1RoleBindingApi - functional programming interface
 * @export
 */
export const V1alpha1RoleBindingApiFp = function (
  configuration?: Configuration
) {
  const localVarAxiosParamCreator =
    V1alpha1RoleBindingApiAxiosParamCreator(configuration);
  return {
    /**
     * Create v1alpha1/RoleBinding
     * @param {RoleBinding} [roleBinding] Fresh rolebinding
     * @param {*} [options] Override http request option.
     * @throws {RequiredError}
     */
    async createv1alpha1RoleBinding(
      roleBinding?: RoleBinding,
      options?: AxiosRequestConfig
    ): Promise<
      (axios?: AxiosInstance, basePath?: string) => AxiosPromise<RoleBinding>
    > {
      const localVarAxiosArgs =
        await localVarAxiosParamCreator.createv1alpha1RoleBinding(
          roleBinding,
          options
        );
      return createRequestFunction(
        localVarAxiosArgs,
        globalAxios,
        BASE_PATH,
        configuration
      );
    },
    /**
     * Delete v1alpha1/RoleBinding
     * @param {string} name Name of rolebinding
     * @param {*} [options] Override http request option.
     * @throws {RequiredError}
     */
    async deletev1alpha1RoleBinding(
      name: string,
      options?: AxiosRequestConfig
    ): Promise<
      (axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>
    > {
      const localVarAxiosArgs =
        await localVarAxiosParamCreator.deletev1alpha1RoleBinding(
          name,
          options
        );
      return createRequestFunction(
        localVarAxiosArgs,
        globalAxios,
        BASE_PATH,
        configuration
      );
    },
    /**
     * Get v1alpha1/RoleBinding
     * @param {string} name Name of rolebinding
     * @param {*} [options] Override http request option.
     * @throws {RequiredError}
     */
    async getv1alpha1RoleBinding(
      name: string,
      options?: AxiosRequestConfig
    ): Promise<
      (axios?: AxiosInstance, basePath?: string) => AxiosPromise<RoleBinding>
    > {
      const localVarAxiosArgs =
        await localVarAxiosParamCreator.getv1alpha1RoleBinding(name, options);
      return createRequestFunction(
        localVarAxiosArgs,
        globalAxios,
        BASE_PATH,
        configuration
      );
    },
    /**
     * List v1alpha1/RoleBinding
     * @param {Array<string>} [fieldSelector] Field selector for filtering.
     * @param {Array<string>} [labelSelector] Label selector for filtering.
     * @param {number} [page] The page number. Zero indicates no page.
     * @param {number} [size] Size of one page. Zero indicates no limit.
     * @param {Array<string>} [sort] Sort property and direction of the list result. Support sorting based on attribute name path.
     * @param {*} [options] Override http request option.
     * @throws {RequiredError}
     */
    async listv1alpha1RoleBinding(
      fieldSelector?: Array<string>,
      labelSelector?: Array<string>,
      page?: number,
      size?: number,
      sort?: Array<string>,
      options?: AxiosRequestConfig
    ): Promise<
      (
        axios?: AxiosInstance,
        basePath?: string
      ) => AxiosPromise<RoleBindingList>
    > {
      const localVarAxiosArgs =
        await localVarAxiosParamCreator.listv1alpha1RoleBinding(
          fieldSelector,
          labelSelector,
          page,
          size,
          sort,
          options
        );
      return createRequestFunction(
        localVarAxiosArgs,
        globalAxios,
        BASE_PATH,
        configuration
      );
    },
    /**
     * Update v1alpha1/RoleBinding
     * @param {string} name Name of rolebinding
     * @param {RoleBinding} [roleBinding] Updated rolebinding
     * @param {*} [options] Override http request option.
     * @throws {RequiredError}
     */
    async updatev1alpha1RoleBinding(
      name: string,
      roleBinding?: RoleBinding,
      options?: AxiosRequestConfig
    ): Promise<
      (axios?: AxiosInstance, basePath?: string) => AxiosPromise<RoleBinding>
    > {
      const localVarAxiosArgs =
        await localVarAxiosParamCreator.updatev1alpha1RoleBinding(
          name,
          roleBinding,
          options
        );
      return createRequestFunction(
        localVarAxiosArgs,
        globalAxios,
        BASE_PATH,
        configuration
      );
    },
  };
};

/**
 * V1alpha1RoleBindingApi - factory interface
 * @export
 */
export const V1alpha1RoleBindingApiFactory = function (
  configuration?: Configuration,
  basePath?: string,
  axios?: AxiosInstance
) {
  const localVarFp = V1alpha1RoleBindingApiFp(configuration);
  return {
    /**
     * Create v1alpha1/RoleBinding
     * @param {V1alpha1RoleBindingApiCreatev1alpha1RoleBindingRequest} requestParameters Request parameters.
     * @param {*} [options] Override http request option.
     * @throws {RequiredError}
     */
    createv1alpha1RoleBinding(
      requestParameters: V1alpha1RoleBindingApiCreatev1alpha1RoleBindingRequest = {},
      options?: AxiosRequestConfig
    ): AxiosPromise<RoleBinding> {
      return localVarFp
        .createv1alpha1RoleBinding(requestParameters.roleBinding, options)
        .then((request) => request(axios, basePath));
    },
    /**
     * Delete v1alpha1/RoleBinding
     * @param {V1alpha1RoleBindingApiDeletev1alpha1RoleBindingRequest} requestParameters Request parameters.
     * @param {*} [options] Override http request option.
     * @throws {RequiredError}
     */
    deletev1alpha1RoleBinding(
      requestParameters: V1alpha1RoleBindingApiDeletev1alpha1RoleBindingRequest,
      options?: AxiosRequestConfig
    ): AxiosPromise<void> {
      return localVarFp
        .deletev1alpha1RoleBinding(requestParameters.name, options)
        .then((request) => request(axios, basePath));
    },
    /**
     * Get v1alpha1/RoleBinding
     * @param {V1alpha1RoleBindingApiGetv1alpha1RoleBindingRequest} requestParameters Request parameters.
     * @param {*} [options] Override http request option.
     * @throws {RequiredError}
     */
    getv1alpha1RoleBinding(
      requestParameters: V1alpha1RoleBindingApiGetv1alpha1RoleBindingRequest,
      options?: AxiosRequestConfig
    ): AxiosPromise<RoleBinding> {
      return localVarFp
        .getv1alpha1RoleBinding(requestParameters.name, options)
        .then((request) => request(axios, basePath));
    },
    /**
     * List v1alpha1/RoleBinding
     * @param {V1alpha1RoleBindingApiListv1alpha1RoleBindingRequest} requestParameters Request parameters.
     * @param {*} [options] Override http request option.
     * @throws {RequiredError}
     */
    listv1alpha1RoleBinding(
      requestParameters: V1alpha1RoleBindingApiListv1alpha1RoleBindingRequest = {},
      options?: AxiosRequestConfig
    ): AxiosPromise<RoleBindingList> {
      return localVarFp
        .listv1alpha1RoleBinding(
          requestParameters.fieldSelector,
          requestParameters.labelSelector,
          requestParameters.page,
          requestParameters.size,
          requestParameters.sort,
          options
        )
        .then((request) => request(axios, basePath));
    },
    /**
     * Update v1alpha1/RoleBinding
     * @param {V1alpha1RoleBindingApiUpdatev1alpha1RoleBindingRequest} requestParameters Request parameters.
     * @param {*} [options] Override http request option.
     * @throws {RequiredError}
     */
    updatev1alpha1RoleBinding(
      requestParameters: V1alpha1RoleBindingApiUpdatev1alpha1RoleBindingRequest,
      options?: AxiosRequestConfig
    ): AxiosPromise<RoleBinding> {
      return localVarFp
        .updatev1alpha1RoleBinding(
          requestParameters.name,
          requestParameters.roleBinding,
          options
        )
        .then((request) => request(axios, basePath));
    },
  };
};

/**
 * Request parameters for createv1alpha1RoleBinding operation in V1alpha1RoleBindingApi.
 * @export
 * @interface V1alpha1RoleBindingApiCreatev1alpha1RoleBindingRequest
 */
export interface V1alpha1RoleBindingApiCreatev1alpha1RoleBindingRequest {
  /**
   * Fresh rolebinding
   * @type {RoleBinding}
   * @memberof V1alpha1RoleBindingApiCreatev1alpha1RoleBinding
   */
  readonly roleBinding?: RoleBinding;
}

/**
 * Request parameters for deletev1alpha1RoleBinding operation in V1alpha1RoleBindingApi.
 * @export
 * @interface V1alpha1RoleBindingApiDeletev1alpha1RoleBindingRequest
 */
export interface V1alpha1RoleBindingApiDeletev1alpha1RoleBindingRequest {
  /**
   * Name of rolebinding
   * @type {string}
   * @memberof V1alpha1RoleBindingApiDeletev1alpha1RoleBinding
   */
  readonly name: string;
}

/**
 * Request parameters for getv1alpha1RoleBinding operation in V1alpha1RoleBindingApi.
 * @export
 * @interface V1alpha1RoleBindingApiGetv1alpha1RoleBindingRequest
 */
export interface V1alpha1RoleBindingApiGetv1alpha1RoleBindingRequest {
  /**
   * Name of rolebinding
   * @type {string}
   * @memberof V1alpha1RoleBindingApiGetv1alpha1RoleBinding
   */
  readonly name: string;
}

/**
 * Request parameters for listv1alpha1RoleBinding operation in V1alpha1RoleBindingApi.
 * @export
 * @interface V1alpha1RoleBindingApiListv1alpha1RoleBindingRequest
 */
export interface V1alpha1RoleBindingApiListv1alpha1RoleBindingRequest {
  /**
   * Field selector for filtering.
   * @type {Array<string>}
   * @memberof V1alpha1RoleBindingApiListv1alpha1RoleBinding
   */
  readonly fieldSelector?: Array<string>;

  /**
   * Label selector for filtering.
   * @type {Array<string>}
   * @memberof V1alpha1RoleBindingApiListv1alpha1RoleBinding
   */
  readonly labelSelector?: Array<string>;

  /**
   * The page number. Zero indicates no page.
   * @type {number}
   * @memberof V1alpha1RoleBindingApiListv1alpha1RoleBinding
   */
  readonly page?: number;

  /**
   * Size of one page. Zero indicates no limit.
   * @type {number}
   * @memberof V1alpha1RoleBindingApiListv1alpha1RoleBinding
   */
  readonly size?: number;

  /**
   * Sort property and direction of the list result. Support sorting based on attribute name path.
   * @type {Array<string>}
   * @memberof V1alpha1RoleBindingApiListv1alpha1RoleBinding
   */
  readonly sort?: Array<string>;
}

/**
 * Request parameters for updatev1alpha1RoleBinding operation in V1alpha1RoleBindingApi.
 * @export
 * @interface V1alpha1RoleBindingApiUpdatev1alpha1RoleBindingRequest
 */
export interface V1alpha1RoleBindingApiUpdatev1alpha1RoleBindingRequest {
  /**
   * Name of rolebinding
   * @type {string}
   * @memberof V1alpha1RoleBindingApiUpdatev1alpha1RoleBinding
   */
  readonly name: string;

  /**
   * Updated rolebinding
   * @type {RoleBinding}
   * @memberof V1alpha1RoleBindingApiUpdatev1alpha1RoleBinding
   */
  readonly roleBinding?: RoleBinding;
}

/**
 * V1alpha1RoleBindingApi - object-oriented interface
 * @export
 * @class V1alpha1RoleBindingApi
 * @extends {BaseAPI}
 */
export class V1alpha1RoleBindingApi extends BaseAPI {
  /**
   * Create v1alpha1/RoleBinding
   * @param {V1alpha1RoleBindingApiCreatev1alpha1RoleBindingRequest} requestParameters Request parameters.
   * @param {*} [options] Override http request option.
   * @throws {RequiredError}
   * @memberof V1alpha1RoleBindingApi
   */
  public createv1alpha1RoleBinding(
    requestParameters: V1alpha1RoleBindingApiCreatev1alpha1RoleBindingRequest = {},
    options?: AxiosRequestConfig
  ) {
    return V1alpha1RoleBindingApiFp(this.configuration)
      .createv1alpha1RoleBinding(requestParameters.roleBinding, options)
      .then((request) => request(this.axios, this.basePath));
  }

  /**
   * Delete v1alpha1/RoleBinding
   * @param {V1alpha1RoleBindingApiDeletev1alpha1RoleBindingRequest} requestParameters Request parameters.
   * @param {*} [options] Override http request option.
   * @throws {RequiredError}
   * @memberof V1alpha1RoleBindingApi
   */
  public deletev1alpha1RoleBinding(
    requestParameters: V1alpha1RoleBindingApiDeletev1alpha1RoleBindingRequest,
    options?: AxiosRequestConfig
  ) {
    return V1alpha1RoleBindingApiFp(this.configuration)
      .deletev1alpha1RoleBinding(requestParameters.name, options)
      .then((request) => request(this.axios, this.basePath));
  }

  /**
   * Get v1alpha1/RoleBinding
   * @param {V1alpha1RoleBindingApiGetv1alpha1RoleBindingRequest} requestParameters Request parameters.
   * @param {*} [options] Override http request option.
   * @throws {RequiredError}
   * @memberof V1alpha1RoleBindingApi
   */
  public getv1alpha1RoleBinding(
    requestParameters: V1alpha1RoleBindingApiGetv1alpha1RoleBindingRequest,
    options?: AxiosRequestConfig
  ) {
    return V1alpha1RoleBindingApiFp(this.configuration)
      .getv1alpha1RoleBinding(requestParameters.name, options)
      .then((request) => request(this.axios, this.basePath));
  }

  /**
   * List v1alpha1/RoleBinding
   * @param {V1alpha1RoleBindingApiListv1alpha1RoleBindingRequest} requestParameters Request parameters.
   * @param {*} [options] Override http request option.
   * @throws {RequiredError}
   * @memberof V1alpha1RoleBindingApi
   */
  public listv1alpha1RoleBinding(
    requestParameters: V1alpha1RoleBindingApiListv1alpha1RoleBindingRequest = {},
    options?: AxiosRequestConfig
  ) {
    return V1alpha1RoleBindingApiFp(this.configuration)
      .listv1alpha1RoleBinding(
        requestParameters.fieldSelector,
        requestParameters.labelSelector,
        requestParameters.page,
        requestParameters.size,
        requestParameters.sort,
        options
      )
      .then((request) => request(this.axios, this.basePath));
  }

  /**
   * Update v1alpha1/RoleBinding
   * @param {V1alpha1RoleBindingApiUpdatev1alpha1RoleBindingRequest} requestParameters Request parameters.
   * @param {*} [options] Override http request option.
   * @throws {RequiredError}
   * @memberof V1alpha1RoleBindingApi
   */
  public updatev1alpha1RoleBinding(
    requestParameters: V1alpha1RoleBindingApiUpdatev1alpha1RoleBindingRequest,
    options?: AxiosRequestConfig
  ) {
    return V1alpha1RoleBindingApiFp(this.configuration)
      .updatev1alpha1RoleBinding(
        requestParameters.name,
        requestParameters.roleBinding,
        options
      )
      .then((request) => request(this.axios, this.basePath));
  }
}
