/* 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 { UserConnection } from "../models";
// @ts-ignore
import { UserConnectionList } from "../models";
/**
 * AuthHaloRunV1alpha1UserConnectionApi - axios parameter creator
 * @export
 */
export const AuthHaloRunV1alpha1UserConnectionApiAxiosParamCreator = function (
  configuration?: Configuration
) {
  return {
    /**
     * Create auth.halo.run/v1alpha1/UserConnection
     * @param {UserConnection} [userConnection] Fresh userconnection
     * @param {*} [options] Override http request option.
     * @throws {RequiredError}
     */
    createauthHaloRunV1alpha1UserConnection: async (
      userConnection?: UserConnection,
      options: AxiosRequestConfig = {}
    ): Promise<RequestArgs> => {
      const localVarPath = `/apis/auth.halo.run/v1alpha1/userconnections`;
      // 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(
        userConnection,
        localVarRequestOptions,
        configuration
      );

      return {
        url: toPathString(localVarUrlObj),
        options: localVarRequestOptions,
      };
    },
    /**
     * Delete auth.halo.run/v1alpha1/UserConnection
     * @param {string} name Name of userconnection
     * @param {*} [options] Override http request option.
     * @throws {RequiredError}
     */
    deleteauthHaloRunV1alpha1UserConnection: async (
      name: string,
      options: AxiosRequestConfig = {}
    ): Promise<RequestArgs> => {
      // verify required parameter 'name' is not null or undefined
      assertParamExists(
        "deleteauthHaloRunV1alpha1UserConnection",
        "name",
        name
      );
      const localVarPath =
        `/apis/auth.halo.run/v1alpha1/userconnections/{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 auth.halo.run/v1alpha1/UserConnection
     * @param {string} name Name of userconnection
     * @param {*} [options] Override http request option.
     * @throws {RequiredError}
     */
    getauthHaloRunV1alpha1UserConnection: async (
      name: string,
      options: AxiosRequestConfig = {}
    ): Promise<RequestArgs> => {
      // verify required parameter 'name' is not null or undefined
      assertParamExists("getauthHaloRunV1alpha1UserConnection", "name", name);
      const localVarPath =
        `/apis/auth.halo.run/v1alpha1/userconnections/{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 auth.halo.run/v1alpha1/UserConnection
     * @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}
     */
    listauthHaloRunV1alpha1UserConnection: async (
      fieldSelector?: Array<string>,
      labelSelector?: Array<string>,
      page?: number,
      size?: number,
      sort?: Array<string>,
      options: AxiosRequestConfig = {}
    ): Promise<RequestArgs> => {
      const localVarPath = `/apis/auth.halo.run/v1alpha1/userconnections`;
      // 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 auth.halo.run/v1alpha1/UserConnection
     * @param {string} name Name of userconnection
     * @param {UserConnection} [userConnection] Updated userconnection
     * @param {*} [options] Override http request option.
     * @throws {RequiredError}
     */
    updateauthHaloRunV1alpha1UserConnection: async (
      name: string,
      userConnection?: UserConnection,
      options: AxiosRequestConfig = {}
    ): Promise<RequestArgs> => {
      // verify required parameter 'name' is not null or undefined
      assertParamExists(
        "updateauthHaloRunV1alpha1UserConnection",
        "name",
        name
      );
      const localVarPath =
        `/apis/auth.halo.run/v1alpha1/userconnections/{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(
        userConnection,
        localVarRequestOptions,
        configuration
      );

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

/**
 * AuthHaloRunV1alpha1UserConnectionApi - functional programming interface
 * @export
 */
export const AuthHaloRunV1alpha1UserConnectionApiFp = function (
  configuration?: Configuration
) {
  const localVarAxiosParamCreator =
    AuthHaloRunV1alpha1UserConnectionApiAxiosParamCreator(configuration);
  return {
    /**
     * Create auth.halo.run/v1alpha1/UserConnection
     * @param {UserConnection} [userConnection] Fresh userconnection
     * @param {*} [options] Override http request option.
     * @throws {RequiredError}
     */
    async createauthHaloRunV1alpha1UserConnection(
      userConnection?: UserConnection,
      options?: AxiosRequestConfig
    ): Promise<
      (axios?: AxiosInstance, basePath?: string) => AxiosPromise<UserConnection>
    > {
      const localVarAxiosArgs =
        await localVarAxiosParamCreator.createauthHaloRunV1alpha1UserConnection(
          userConnection,
          options
        );
      return createRequestFunction(
        localVarAxiosArgs,
        globalAxios,
        BASE_PATH,
        configuration
      );
    },
    /**
     * Delete auth.halo.run/v1alpha1/UserConnection
     * @param {string} name Name of userconnection
     * @param {*} [options] Override http request option.
     * @throws {RequiredError}
     */
    async deleteauthHaloRunV1alpha1UserConnection(
      name: string,
      options?: AxiosRequestConfig
    ): Promise<
      (axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>
    > {
      const localVarAxiosArgs =
        await localVarAxiosParamCreator.deleteauthHaloRunV1alpha1UserConnection(
          name,
          options
        );
      return createRequestFunction(
        localVarAxiosArgs,
        globalAxios,
        BASE_PATH,
        configuration
      );
    },
    /**
     * Get auth.halo.run/v1alpha1/UserConnection
     * @param {string} name Name of userconnection
     * @param {*} [options] Override http request option.
     * @throws {RequiredError}
     */
    async getauthHaloRunV1alpha1UserConnection(
      name: string,
      options?: AxiosRequestConfig
    ): Promise<
      (axios?: AxiosInstance, basePath?: string) => AxiosPromise<UserConnection>
    > {
      const localVarAxiosArgs =
        await localVarAxiosParamCreator.getauthHaloRunV1alpha1UserConnection(
          name,
          options
        );
      return createRequestFunction(
        localVarAxiosArgs,
        globalAxios,
        BASE_PATH,
        configuration
      );
    },
    /**
     * List auth.halo.run/v1alpha1/UserConnection
     * @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 listauthHaloRunV1alpha1UserConnection(
      fieldSelector?: Array<string>,
      labelSelector?: Array<string>,
      page?: number,
      size?: number,
      sort?: Array<string>,
      options?: AxiosRequestConfig
    ): Promise<
      (
        axios?: AxiosInstance,
        basePath?: string
      ) => AxiosPromise<UserConnectionList>
    > {
      const localVarAxiosArgs =
        await localVarAxiosParamCreator.listauthHaloRunV1alpha1UserConnection(
          fieldSelector,
          labelSelector,
          page,
          size,
          sort,
          options
        );
      return createRequestFunction(
        localVarAxiosArgs,
        globalAxios,
        BASE_PATH,
        configuration
      );
    },
    /**
     * Update auth.halo.run/v1alpha1/UserConnection
     * @param {string} name Name of userconnection
     * @param {UserConnection} [userConnection] Updated userconnection
     * @param {*} [options] Override http request option.
     * @throws {RequiredError}
     */
    async updateauthHaloRunV1alpha1UserConnection(
      name: string,
      userConnection?: UserConnection,
      options?: AxiosRequestConfig
    ): Promise<
      (axios?: AxiosInstance, basePath?: string) => AxiosPromise<UserConnection>
    > {
      const localVarAxiosArgs =
        await localVarAxiosParamCreator.updateauthHaloRunV1alpha1UserConnection(
          name,
          userConnection,
          options
        );
      return createRequestFunction(
        localVarAxiosArgs,
        globalAxios,
        BASE_PATH,
        configuration
      );
    },
  };
};

/**
 * AuthHaloRunV1alpha1UserConnectionApi - factory interface
 * @export
 */
export const AuthHaloRunV1alpha1UserConnectionApiFactory = function (
  configuration?: Configuration,
  basePath?: string,
  axios?: AxiosInstance
) {
  const localVarFp = AuthHaloRunV1alpha1UserConnectionApiFp(configuration);
  return {
    /**
     * Create auth.halo.run/v1alpha1/UserConnection
     * @param {AuthHaloRunV1alpha1UserConnectionApiCreateauthHaloRunV1alpha1UserConnectionRequest} requestParameters Request parameters.
     * @param {*} [options] Override http request option.
     * @throws {RequiredError}
     */
    createauthHaloRunV1alpha1UserConnection(
      requestParameters: AuthHaloRunV1alpha1UserConnectionApiCreateauthHaloRunV1alpha1UserConnectionRequest = {},
      options?: AxiosRequestConfig
    ): AxiosPromise<UserConnection> {
      return localVarFp
        .createauthHaloRunV1alpha1UserConnection(
          requestParameters.userConnection,
          options
        )
        .then((request) => request(axios, basePath));
    },
    /**
     * Delete auth.halo.run/v1alpha1/UserConnection
     * @param {AuthHaloRunV1alpha1UserConnectionApiDeleteauthHaloRunV1alpha1UserConnectionRequest} requestParameters Request parameters.
     * @param {*} [options] Override http request option.
     * @throws {RequiredError}
     */
    deleteauthHaloRunV1alpha1UserConnection(
      requestParameters: AuthHaloRunV1alpha1UserConnectionApiDeleteauthHaloRunV1alpha1UserConnectionRequest,
      options?: AxiosRequestConfig
    ): AxiosPromise<void> {
      return localVarFp
        .deleteauthHaloRunV1alpha1UserConnection(
          requestParameters.name,
          options
        )
        .then((request) => request(axios, basePath));
    },
    /**
     * Get auth.halo.run/v1alpha1/UserConnection
     * @param {AuthHaloRunV1alpha1UserConnectionApiGetauthHaloRunV1alpha1UserConnectionRequest} requestParameters Request parameters.
     * @param {*} [options] Override http request option.
     * @throws {RequiredError}
     */
    getauthHaloRunV1alpha1UserConnection(
      requestParameters: AuthHaloRunV1alpha1UserConnectionApiGetauthHaloRunV1alpha1UserConnectionRequest,
      options?: AxiosRequestConfig
    ): AxiosPromise<UserConnection> {
      return localVarFp
        .getauthHaloRunV1alpha1UserConnection(requestParameters.name, options)
        .then((request) => request(axios, basePath));
    },
    /**
     * List auth.halo.run/v1alpha1/UserConnection
     * @param {AuthHaloRunV1alpha1UserConnectionApiListauthHaloRunV1alpha1UserConnectionRequest} requestParameters Request parameters.
     * @param {*} [options] Override http request option.
     * @throws {RequiredError}
     */
    listauthHaloRunV1alpha1UserConnection(
      requestParameters: AuthHaloRunV1alpha1UserConnectionApiListauthHaloRunV1alpha1UserConnectionRequest = {},
      options?: AxiosRequestConfig
    ): AxiosPromise<UserConnectionList> {
      return localVarFp
        .listauthHaloRunV1alpha1UserConnection(
          requestParameters.fieldSelector,
          requestParameters.labelSelector,
          requestParameters.page,
          requestParameters.size,
          requestParameters.sort,
          options
        )
        .then((request) => request(axios, basePath));
    },
    /**
     * Update auth.halo.run/v1alpha1/UserConnection
     * @param {AuthHaloRunV1alpha1UserConnectionApiUpdateauthHaloRunV1alpha1UserConnectionRequest} requestParameters Request parameters.
     * @param {*} [options] Override http request option.
     * @throws {RequiredError}
     */
    updateauthHaloRunV1alpha1UserConnection(
      requestParameters: AuthHaloRunV1alpha1UserConnectionApiUpdateauthHaloRunV1alpha1UserConnectionRequest,
      options?: AxiosRequestConfig
    ): AxiosPromise<UserConnection> {
      return localVarFp
        .updateauthHaloRunV1alpha1UserConnection(
          requestParameters.name,
          requestParameters.userConnection,
          options
        )
        .then((request) => request(axios, basePath));
    },
  };
};

/**
 * Request parameters for createauthHaloRunV1alpha1UserConnection operation in AuthHaloRunV1alpha1UserConnectionApi.
 * @export
 * @interface AuthHaloRunV1alpha1UserConnectionApiCreateauthHaloRunV1alpha1UserConnectionRequest
 */
export interface AuthHaloRunV1alpha1UserConnectionApiCreateauthHaloRunV1alpha1UserConnectionRequest {
  /**
   * Fresh userconnection
   * @type {UserConnection}
   * @memberof AuthHaloRunV1alpha1UserConnectionApiCreateauthHaloRunV1alpha1UserConnection
   */
  readonly userConnection?: UserConnection;
}

/**
 * Request parameters for deleteauthHaloRunV1alpha1UserConnection operation in AuthHaloRunV1alpha1UserConnectionApi.
 * @export
 * @interface AuthHaloRunV1alpha1UserConnectionApiDeleteauthHaloRunV1alpha1UserConnectionRequest
 */
export interface AuthHaloRunV1alpha1UserConnectionApiDeleteauthHaloRunV1alpha1UserConnectionRequest {
  /**
   * Name of userconnection
   * @type {string}
   * @memberof AuthHaloRunV1alpha1UserConnectionApiDeleteauthHaloRunV1alpha1UserConnection
   */
  readonly name: string;
}

/**
 * Request parameters for getauthHaloRunV1alpha1UserConnection operation in AuthHaloRunV1alpha1UserConnectionApi.
 * @export
 * @interface AuthHaloRunV1alpha1UserConnectionApiGetauthHaloRunV1alpha1UserConnectionRequest
 */
export interface AuthHaloRunV1alpha1UserConnectionApiGetauthHaloRunV1alpha1UserConnectionRequest {
  /**
   * Name of userconnection
   * @type {string}
   * @memberof AuthHaloRunV1alpha1UserConnectionApiGetauthHaloRunV1alpha1UserConnection
   */
  readonly name: string;
}

/**
 * Request parameters for listauthHaloRunV1alpha1UserConnection operation in AuthHaloRunV1alpha1UserConnectionApi.
 * @export
 * @interface AuthHaloRunV1alpha1UserConnectionApiListauthHaloRunV1alpha1UserConnectionRequest
 */
export interface AuthHaloRunV1alpha1UserConnectionApiListauthHaloRunV1alpha1UserConnectionRequest {
  /**
   * Field selector for filtering.
   * @type {Array<string>}
   * @memberof AuthHaloRunV1alpha1UserConnectionApiListauthHaloRunV1alpha1UserConnection
   */
  readonly fieldSelector?: Array<string>;

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

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

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

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

/**
 * Request parameters for updateauthHaloRunV1alpha1UserConnection operation in AuthHaloRunV1alpha1UserConnectionApi.
 * @export
 * @interface AuthHaloRunV1alpha1UserConnectionApiUpdateauthHaloRunV1alpha1UserConnectionRequest
 */
export interface AuthHaloRunV1alpha1UserConnectionApiUpdateauthHaloRunV1alpha1UserConnectionRequest {
  /**
   * Name of userconnection
   * @type {string}
   * @memberof AuthHaloRunV1alpha1UserConnectionApiUpdateauthHaloRunV1alpha1UserConnection
   */
  readonly name: string;

  /**
   * Updated userconnection
   * @type {UserConnection}
   * @memberof AuthHaloRunV1alpha1UserConnectionApiUpdateauthHaloRunV1alpha1UserConnection
   */
  readonly userConnection?: UserConnection;
}

/**
 * AuthHaloRunV1alpha1UserConnectionApi - object-oriented interface
 * @export
 * @class AuthHaloRunV1alpha1UserConnectionApi
 * @extends {BaseAPI}
 */
export class AuthHaloRunV1alpha1UserConnectionApi extends BaseAPI {
  /**
   * Create auth.halo.run/v1alpha1/UserConnection
   * @param {AuthHaloRunV1alpha1UserConnectionApiCreateauthHaloRunV1alpha1UserConnectionRequest} requestParameters Request parameters.
   * @param {*} [options] Override http request option.
   * @throws {RequiredError}
   * @memberof AuthHaloRunV1alpha1UserConnectionApi
   */
  public createauthHaloRunV1alpha1UserConnection(
    requestParameters: AuthHaloRunV1alpha1UserConnectionApiCreateauthHaloRunV1alpha1UserConnectionRequest = {},
    options?: AxiosRequestConfig
  ) {
    return AuthHaloRunV1alpha1UserConnectionApiFp(this.configuration)
      .createauthHaloRunV1alpha1UserConnection(
        requestParameters.userConnection,
        options
      )
      .then((request) => request(this.axios, this.basePath));
  }

  /**
   * Delete auth.halo.run/v1alpha1/UserConnection
   * @param {AuthHaloRunV1alpha1UserConnectionApiDeleteauthHaloRunV1alpha1UserConnectionRequest} requestParameters Request parameters.
   * @param {*} [options] Override http request option.
   * @throws {RequiredError}
   * @memberof AuthHaloRunV1alpha1UserConnectionApi
   */
  public deleteauthHaloRunV1alpha1UserConnection(
    requestParameters: AuthHaloRunV1alpha1UserConnectionApiDeleteauthHaloRunV1alpha1UserConnectionRequest,
    options?: AxiosRequestConfig
  ) {
    return AuthHaloRunV1alpha1UserConnectionApiFp(this.configuration)
      .deleteauthHaloRunV1alpha1UserConnection(requestParameters.name, options)
      .then((request) => request(this.axios, this.basePath));
  }

  /**
   * Get auth.halo.run/v1alpha1/UserConnection
   * @param {AuthHaloRunV1alpha1UserConnectionApiGetauthHaloRunV1alpha1UserConnectionRequest} requestParameters Request parameters.
   * @param {*} [options] Override http request option.
   * @throws {RequiredError}
   * @memberof AuthHaloRunV1alpha1UserConnectionApi
   */
  public getauthHaloRunV1alpha1UserConnection(
    requestParameters: AuthHaloRunV1alpha1UserConnectionApiGetauthHaloRunV1alpha1UserConnectionRequest,
    options?: AxiosRequestConfig
  ) {
    return AuthHaloRunV1alpha1UserConnectionApiFp(this.configuration)
      .getauthHaloRunV1alpha1UserConnection(requestParameters.name, options)
      .then((request) => request(this.axios, this.basePath));
  }

  /**
   * List auth.halo.run/v1alpha1/UserConnection
   * @param {AuthHaloRunV1alpha1UserConnectionApiListauthHaloRunV1alpha1UserConnectionRequest} requestParameters Request parameters.
   * @param {*} [options] Override http request option.
   * @throws {RequiredError}
   * @memberof AuthHaloRunV1alpha1UserConnectionApi
   */
  public listauthHaloRunV1alpha1UserConnection(
    requestParameters: AuthHaloRunV1alpha1UserConnectionApiListauthHaloRunV1alpha1UserConnectionRequest = {},
    options?: AxiosRequestConfig
  ) {
    return AuthHaloRunV1alpha1UserConnectionApiFp(this.configuration)
      .listauthHaloRunV1alpha1UserConnection(
        requestParameters.fieldSelector,
        requestParameters.labelSelector,
        requestParameters.page,
        requestParameters.size,
        requestParameters.sort,
        options
      )
      .then((request) => request(this.axios, this.basePath));
  }

  /**
   * Update auth.halo.run/v1alpha1/UserConnection
   * @param {AuthHaloRunV1alpha1UserConnectionApiUpdateauthHaloRunV1alpha1UserConnectionRequest} requestParameters Request parameters.
   * @param {*} [options] Override http request option.
   * @throws {RequiredError}
   * @memberof AuthHaloRunV1alpha1UserConnectionApi
   */
  public updateauthHaloRunV1alpha1UserConnection(
    requestParameters: AuthHaloRunV1alpha1UserConnectionApiUpdateauthHaloRunV1alpha1UserConnectionRequest,
    options?: AxiosRequestConfig
  ) {
    return AuthHaloRunV1alpha1UserConnectionApiFp(this.configuration)
      .updateauthHaloRunV1alpha1UserConnection(
        requestParameters.name,
        requestParameters.userConnection,
        options
      )
      .then((request) => request(this.axios, this.basePath));
  }
}
