/* 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 { ExtensionPointDefinition } from "../models";
// @ts-ignore
import { ExtensionPointDefinitionList } from "../models";
/**
 * PluginHaloRunV1alpha1ExtensionPointDefinitionApi - axios parameter creator
 * @export
 */
export const PluginHaloRunV1alpha1ExtensionPointDefinitionApiAxiosParamCreator =
  function (configuration?: Configuration) {
    return {
      /**
       * Create plugin.halo.run/v1alpha1/ExtensionPointDefinition
       * @param {ExtensionPointDefinition} [extensionPointDefinition] Fresh extensionpointdefinition
       * @param {*} [options] Override http request option.
       * @throws {RequiredError}
       */
      createpluginHaloRunV1alpha1ExtensionPointDefinition: async (
        extensionPointDefinition?: ExtensionPointDefinition,
        options: AxiosRequestConfig = {}
      ): Promise<RequestArgs> => {
        const localVarPath = `/apis/plugin.halo.run/v1alpha1/extensionpointdefinitions`;
        // 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(
          extensionPointDefinition,
          localVarRequestOptions,
          configuration
        );

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

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

/**
 * PluginHaloRunV1alpha1ExtensionPointDefinitionApi - functional programming interface
 * @export
 */
export const PluginHaloRunV1alpha1ExtensionPointDefinitionApiFp = function (
  configuration?: Configuration
) {
  const localVarAxiosParamCreator =
    PluginHaloRunV1alpha1ExtensionPointDefinitionApiAxiosParamCreator(
      configuration
    );
  return {
    /**
     * Create plugin.halo.run/v1alpha1/ExtensionPointDefinition
     * @param {ExtensionPointDefinition} [extensionPointDefinition] Fresh extensionpointdefinition
     * @param {*} [options] Override http request option.
     * @throws {RequiredError}
     */
    async createpluginHaloRunV1alpha1ExtensionPointDefinition(
      extensionPointDefinition?: ExtensionPointDefinition,
      options?: AxiosRequestConfig
    ): Promise<
      (
        axios?: AxiosInstance,
        basePath?: string
      ) => AxiosPromise<ExtensionPointDefinition>
    > {
      const localVarAxiosArgs =
        await localVarAxiosParamCreator.createpluginHaloRunV1alpha1ExtensionPointDefinition(
          extensionPointDefinition,
          options
        );
      return createRequestFunction(
        localVarAxiosArgs,
        globalAxios,
        BASE_PATH,
        configuration
      );
    },
    /**
     * Delete plugin.halo.run/v1alpha1/ExtensionPointDefinition
     * @param {string} name Name of extensionpointdefinition
     * @param {*} [options] Override http request option.
     * @throws {RequiredError}
     */
    async deletepluginHaloRunV1alpha1ExtensionPointDefinition(
      name: string,
      options?: AxiosRequestConfig
    ): Promise<
      (axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>
    > {
      const localVarAxiosArgs =
        await localVarAxiosParamCreator.deletepluginHaloRunV1alpha1ExtensionPointDefinition(
          name,
          options
        );
      return createRequestFunction(
        localVarAxiosArgs,
        globalAxios,
        BASE_PATH,
        configuration
      );
    },
    /**
     * Get plugin.halo.run/v1alpha1/ExtensionPointDefinition
     * @param {string} name Name of extensionpointdefinition
     * @param {*} [options] Override http request option.
     * @throws {RequiredError}
     */
    async getpluginHaloRunV1alpha1ExtensionPointDefinition(
      name: string,
      options?: AxiosRequestConfig
    ): Promise<
      (
        axios?: AxiosInstance,
        basePath?: string
      ) => AxiosPromise<ExtensionPointDefinition>
    > {
      const localVarAxiosArgs =
        await localVarAxiosParamCreator.getpluginHaloRunV1alpha1ExtensionPointDefinition(
          name,
          options
        );
      return createRequestFunction(
        localVarAxiosArgs,
        globalAxios,
        BASE_PATH,
        configuration
      );
    },
    /**
     * List plugin.halo.run/v1alpha1/ExtensionPointDefinition
     * @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 listpluginHaloRunV1alpha1ExtensionPointDefinition(
      fieldSelector?: Array<string>,
      labelSelector?: Array<string>,
      page?: number,
      size?: number,
      sort?: Array<string>,
      options?: AxiosRequestConfig
    ): Promise<
      (
        axios?: AxiosInstance,
        basePath?: string
      ) => AxiosPromise<ExtensionPointDefinitionList>
    > {
      const localVarAxiosArgs =
        await localVarAxiosParamCreator.listpluginHaloRunV1alpha1ExtensionPointDefinition(
          fieldSelector,
          labelSelector,
          page,
          size,
          sort,
          options
        );
      return createRequestFunction(
        localVarAxiosArgs,
        globalAxios,
        BASE_PATH,
        configuration
      );
    },
    /**
     * Update plugin.halo.run/v1alpha1/ExtensionPointDefinition
     * @param {string} name Name of extensionpointdefinition
     * @param {ExtensionPointDefinition} [extensionPointDefinition] Updated extensionpointdefinition
     * @param {*} [options] Override http request option.
     * @throws {RequiredError}
     */
    async updatepluginHaloRunV1alpha1ExtensionPointDefinition(
      name: string,
      extensionPointDefinition?: ExtensionPointDefinition,
      options?: AxiosRequestConfig
    ): Promise<
      (
        axios?: AxiosInstance,
        basePath?: string
      ) => AxiosPromise<ExtensionPointDefinition>
    > {
      const localVarAxiosArgs =
        await localVarAxiosParamCreator.updatepluginHaloRunV1alpha1ExtensionPointDefinition(
          name,
          extensionPointDefinition,
          options
        );
      return createRequestFunction(
        localVarAxiosArgs,
        globalAxios,
        BASE_PATH,
        configuration
      );
    },
  };
};

/**
 * PluginHaloRunV1alpha1ExtensionPointDefinitionApi - factory interface
 * @export
 */
export const PluginHaloRunV1alpha1ExtensionPointDefinitionApiFactory =
  function (
    configuration?: Configuration,
    basePath?: string,
    axios?: AxiosInstance
  ) {
    const localVarFp =
      PluginHaloRunV1alpha1ExtensionPointDefinitionApiFp(configuration);
    return {
      /**
       * Create plugin.halo.run/v1alpha1/ExtensionPointDefinition
       * @param {PluginHaloRunV1alpha1ExtensionPointDefinitionApiCreatepluginHaloRunV1alpha1ExtensionPointDefinitionRequest} requestParameters Request parameters.
       * @param {*} [options] Override http request option.
       * @throws {RequiredError}
       */
      createpluginHaloRunV1alpha1ExtensionPointDefinition(
        requestParameters: PluginHaloRunV1alpha1ExtensionPointDefinitionApiCreatepluginHaloRunV1alpha1ExtensionPointDefinitionRequest = {},
        options?: AxiosRequestConfig
      ): AxiosPromise<ExtensionPointDefinition> {
        return localVarFp
          .createpluginHaloRunV1alpha1ExtensionPointDefinition(
            requestParameters.extensionPointDefinition,
            options
          )
          .then((request) => request(axios, basePath));
      },
      /**
       * Delete plugin.halo.run/v1alpha1/ExtensionPointDefinition
       * @param {PluginHaloRunV1alpha1ExtensionPointDefinitionApiDeletepluginHaloRunV1alpha1ExtensionPointDefinitionRequest} requestParameters Request parameters.
       * @param {*} [options] Override http request option.
       * @throws {RequiredError}
       */
      deletepluginHaloRunV1alpha1ExtensionPointDefinition(
        requestParameters: PluginHaloRunV1alpha1ExtensionPointDefinitionApiDeletepluginHaloRunV1alpha1ExtensionPointDefinitionRequest,
        options?: AxiosRequestConfig
      ): AxiosPromise<void> {
        return localVarFp
          .deletepluginHaloRunV1alpha1ExtensionPointDefinition(
            requestParameters.name,
            options
          )
          .then((request) => request(axios, basePath));
      },
      /**
       * Get plugin.halo.run/v1alpha1/ExtensionPointDefinition
       * @param {PluginHaloRunV1alpha1ExtensionPointDefinitionApiGetpluginHaloRunV1alpha1ExtensionPointDefinitionRequest} requestParameters Request parameters.
       * @param {*} [options] Override http request option.
       * @throws {RequiredError}
       */
      getpluginHaloRunV1alpha1ExtensionPointDefinition(
        requestParameters: PluginHaloRunV1alpha1ExtensionPointDefinitionApiGetpluginHaloRunV1alpha1ExtensionPointDefinitionRequest,
        options?: AxiosRequestConfig
      ): AxiosPromise<ExtensionPointDefinition> {
        return localVarFp
          .getpluginHaloRunV1alpha1ExtensionPointDefinition(
            requestParameters.name,
            options
          )
          .then((request) => request(axios, basePath));
      },
      /**
       * List plugin.halo.run/v1alpha1/ExtensionPointDefinition
       * @param {PluginHaloRunV1alpha1ExtensionPointDefinitionApiListpluginHaloRunV1alpha1ExtensionPointDefinitionRequest} requestParameters Request parameters.
       * @param {*} [options] Override http request option.
       * @throws {RequiredError}
       */
      listpluginHaloRunV1alpha1ExtensionPointDefinition(
        requestParameters: PluginHaloRunV1alpha1ExtensionPointDefinitionApiListpluginHaloRunV1alpha1ExtensionPointDefinitionRequest = {},
        options?: AxiosRequestConfig
      ): AxiosPromise<ExtensionPointDefinitionList> {
        return localVarFp
          .listpluginHaloRunV1alpha1ExtensionPointDefinition(
            requestParameters.fieldSelector,
            requestParameters.labelSelector,
            requestParameters.page,
            requestParameters.size,
            requestParameters.sort,
            options
          )
          .then((request) => request(axios, basePath));
      },
      /**
       * Update plugin.halo.run/v1alpha1/ExtensionPointDefinition
       * @param {PluginHaloRunV1alpha1ExtensionPointDefinitionApiUpdatepluginHaloRunV1alpha1ExtensionPointDefinitionRequest} requestParameters Request parameters.
       * @param {*} [options] Override http request option.
       * @throws {RequiredError}
       */
      updatepluginHaloRunV1alpha1ExtensionPointDefinition(
        requestParameters: PluginHaloRunV1alpha1ExtensionPointDefinitionApiUpdatepluginHaloRunV1alpha1ExtensionPointDefinitionRequest,
        options?: AxiosRequestConfig
      ): AxiosPromise<ExtensionPointDefinition> {
        return localVarFp
          .updatepluginHaloRunV1alpha1ExtensionPointDefinition(
            requestParameters.name,
            requestParameters.extensionPointDefinition,
            options
          )
          .then((request) => request(axios, basePath));
      },
    };
  };

/**
 * Request parameters for createpluginHaloRunV1alpha1ExtensionPointDefinition operation in PluginHaloRunV1alpha1ExtensionPointDefinitionApi.
 * @export
 * @interface PluginHaloRunV1alpha1ExtensionPointDefinitionApiCreatepluginHaloRunV1alpha1ExtensionPointDefinitionRequest
 */
export interface PluginHaloRunV1alpha1ExtensionPointDefinitionApiCreatepluginHaloRunV1alpha1ExtensionPointDefinitionRequest {
  /**
   * Fresh extensionpointdefinition
   * @type {ExtensionPointDefinition}
   * @memberof PluginHaloRunV1alpha1ExtensionPointDefinitionApiCreatepluginHaloRunV1alpha1ExtensionPointDefinition
   */
  readonly extensionPointDefinition?: ExtensionPointDefinition;
}

/**
 * Request parameters for deletepluginHaloRunV1alpha1ExtensionPointDefinition operation in PluginHaloRunV1alpha1ExtensionPointDefinitionApi.
 * @export
 * @interface PluginHaloRunV1alpha1ExtensionPointDefinitionApiDeletepluginHaloRunV1alpha1ExtensionPointDefinitionRequest
 */
export interface PluginHaloRunV1alpha1ExtensionPointDefinitionApiDeletepluginHaloRunV1alpha1ExtensionPointDefinitionRequest {
  /**
   * Name of extensionpointdefinition
   * @type {string}
   * @memberof PluginHaloRunV1alpha1ExtensionPointDefinitionApiDeletepluginHaloRunV1alpha1ExtensionPointDefinition
   */
  readonly name: string;
}

/**
 * Request parameters for getpluginHaloRunV1alpha1ExtensionPointDefinition operation in PluginHaloRunV1alpha1ExtensionPointDefinitionApi.
 * @export
 * @interface PluginHaloRunV1alpha1ExtensionPointDefinitionApiGetpluginHaloRunV1alpha1ExtensionPointDefinitionRequest
 */
export interface PluginHaloRunV1alpha1ExtensionPointDefinitionApiGetpluginHaloRunV1alpha1ExtensionPointDefinitionRequest {
  /**
   * Name of extensionpointdefinition
   * @type {string}
   * @memberof PluginHaloRunV1alpha1ExtensionPointDefinitionApiGetpluginHaloRunV1alpha1ExtensionPointDefinition
   */
  readonly name: string;
}

/**
 * Request parameters for listpluginHaloRunV1alpha1ExtensionPointDefinition operation in PluginHaloRunV1alpha1ExtensionPointDefinitionApi.
 * @export
 * @interface PluginHaloRunV1alpha1ExtensionPointDefinitionApiListpluginHaloRunV1alpha1ExtensionPointDefinitionRequest
 */
export interface PluginHaloRunV1alpha1ExtensionPointDefinitionApiListpluginHaloRunV1alpha1ExtensionPointDefinitionRequest {
  /**
   * Field selector for filtering.
   * @type {Array<string>}
   * @memberof PluginHaloRunV1alpha1ExtensionPointDefinitionApiListpluginHaloRunV1alpha1ExtensionPointDefinition
   */
  readonly fieldSelector?: Array<string>;

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

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

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

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

/**
 * Request parameters for updatepluginHaloRunV1alpha1ExtensionPointDefinition operation in PluginHaloRunV1alpha1ExtensionPointDefinitionApi.
 * @export
 * @interface PluginHaloRunV1alpha1ExtensionPointDefinitionApiUpdatepluginHaloRunV1alpha1ExtensionPointDefinitionRequest
 */
export interface PluginHaloRunV1alpha1ExtensionPointDefinitionApiUpdatepluginHaloRunV1alpha1ExtensionPointDefinitionRequest {
  /**
   * Name of extensionpointdefinition
   * @type {string}
   * @memberof PluginHaloRunV1alpha1ExtensionPointDefinitionApiUpdatepluginHaloRunV1alpha1ExtensionPointDefinition
   */
  readonly name: string;

  /**
   * Updated extensionpointdefinition
   * @type {ExtensionPointDefinition}
   * @memberof PluginHaloRunV1alpha1ExtensionPointDefinitionApiUpdatepluginHaloRunV1alpha1ExtensionPointDefinition
   */
  readonly extensionPointDefinition?: ExtensionPointDefinition;
}

/**
 * PluginHaloRunV1alpha1ExtensionPointDefinitionApi - object-oriented interface
 * @export
 * @class PluginHaloRunV1alpha1ExtensionPointDefinitionApi
 * @extends {BaseAPI}
 */
export class PluginHaloRunV1alpha1ExtensionPointDefinitionApi extends BaseAPI {
  /**
   * Create plugin.halo.run/v1alpha1/ExtensionPointDefinition
   * @param {PluginHaloRunV1alpha1ExtensionPointDefinitionApiCreatepluginHaloRunV1alpha1ExtensionPointDefinitionRequest} requestParameters Request parameters.
   * @param {*} [options] Override http request option.
   * @throws {RequiredError}
   * @memberof PluginHaloRunV1alpha1ExtensionPointDefinitionApi
   */
  public createpluginHaloRunV1alpha1ExtensionPointDefinition(
    requestParameters: PluginHaloRunV1alpha1ExtensionPointDefinitionApiCreatepluginHaloRunV1alpha1ExtensionPointDefinitionRequest = {},
    options?: AxiosRequestConfig
  ) {
    return PluginHaloRunV1alpha1ExtensionPointDefinitionApiFp(
      this.configuration
    )
      .createpluginHaloRunV1alpha1ExtensionPointDefinition(
        requestParameters.extensionPointDefinition,
        options
      )
      .then((request) => request(this.axios, this.basePath));
  }

  /**
   * Delete plugin.halo.run/v1alpha1/ExtensionPointDefinition
   * @param {PluginHaloRunV1alpha1ExtensionPointDefinitionApiDeletepluginHaloRunV1alpha1ExtensionPointDefinitionRequest} requestParameters Request parameters.
   * @param {*} [options] Override http request option.
   * @throws {RequiredError}
   * @memberof PluginHaloRunV1alpha1ExtensionPointDefinitionApi
   */
  public deletepluginHaloRunV1alpha1ExtensionPointDefinition(
    requestParameters: PluginHaloRunV1alpha1ExtensionPointDefinitionApiDeletepluginHaloRunV1alpha1ExtensionPointDefinitionRequest,
    options?: AxiosRequestConfig
  ) {
    return PluginHaloRunV1alpha1ExtensionPointDefinitionApiFp(
      this.configuration
    )
      .deletepluginHaloRunV1alpha1ExtensionPointDefinition(
        requestParameters.name,
        options
      )
      .then((request) => request(this.axios, this.basePath));
  }

  /**
   * Get plugin.halo.run/v1alpha1/ExtensionPointDefinition
   * @param {PluginHaloRunV1alpha1ExtensionPointDefinitionApiGetpluginHaloRunV1alpha1ExtensionPointDefinitionRequest} requestParameters Request parameters.
   * @param {*} [options] Override http request option.
   * @throws {RequiredError}
   * @memberof PluginHaloRunV1alpha1ExtensionPointDefinitionApi
   */
  public getpluginHaloRunV1alpha1ExtensionPointDefinition(
    requestParameters: PluginHaloRunV1alpha1ExtensionPointDefinitionApiGetpluginHaloRunV1alpha1ExtensionPointDefinitionRequest,
    options?: AxiosRequestConfig
  ) {
    return PluginHaloRunV1alpha1ExtensionPointDefinitionApiFp(
      this.configuration
    )
      .getpluginHaloRunV1alpha1ExtensionPointDefinition(
        requestParameters.name,
        options
      )
      .then((request) => request(this.axios, this.basePath));
  }

  /**
   * List plugin.halo.run/v1alpha1/ExtensionPointDefinition
   * @param {PluginHaloRunV1alpha1ExtensionPointDefinitionApiListpluginHaloRunV1alpha1ExtensionPointDefinitionRequest} requestParameters Request parameters.
   * @param {*} [options] Override http request option.
   * @throws {RequiredError}
   * @memberof PluginHaloRunV1alpha1ExtensionPointDefinitionApi
   */
  public listpluginHaloRunV1alpha1ExtensionPointDefinition(
    requestParameters: PluginHaloRunV1alpha1ExtensionPointDefinitionApiListpluginHaloRunV1alpha1ExtensionPointDefinitionRequest = {},
    options?: AxiosRequestConfig
  ) {
    return PluginHaloRunV1alpha1ExtensionPointDefinitionApiFp(
      this.configuration
    )
      .listpluginHaloRunV1alpha1ExtensionPointDefinition(
        requestParameters.fieldSelector,
        requestParameters.labelSelector,
        requestParameters.page,
        requestParameters.size,
        requestParameters.sort,
        options
      )
      .then((request) => request(this.axios, this.basePath));
  }

  /**
   * Update plugin.halo.run/v1alpha1/ExtensionPointDefinition
   * @param {PluginHaloRunV1alpha1ExtensionPointDefinitionApiUpdatepluginHaloRunV1alpha1ExtensionPointDefinitionRequest} requestParameters Request parameters.
   * @param {*} [options] Override http request option.
   * @throws {RequiredError}
   * @memberof PluginHaloRunV1alpha1ExtensionPointDefinitionApi
   */
  public updatepluginHaloRunV1alpha1ExtensionPointDefinition(
    requestParameters: PluginHaloRunV1alpha1ExtensionPointDefinitionApiUpdatepluginHaloRunV1alpha1ExtensionPointDefinitionRequest,
    options?: AxiosRequestConfig
  ) {
    return PluginHaloRunV1alpha1ExtensionPointDefinitionApiFp(
      this.configuration
    )
      .updatepluginHaloRunV1alpha1ExtensionPointDefinition(
        requestParameters.name,
        requestParameters.extensionPointDefinition,
        options
      )
      .then((request) => request(this.axios, this.basePath));
  }
}
