/**
 * Provides utility functions for the [WCSLayer](https://developers.arcgis.com/javascript/latest/api-reference/esri-layers-WCSLayer.html).
 *
 * @since 4.31
 * @see [WCSLayer](https://developers.arcgis.com/javascript/latest/api-reference/esri-layers-WCSLayer.html)
 */
import type { AbortOptions } from "../../core/promiseUtils.js";
import type { CustomParameters } from "../mixins/CustomParametersMixin.js";
import type { WCSVersion } from "../raster/datasets/types.js";
import type { WCSCapabilities } from "../raster/datasets/wcsCapabilitiesParser.js";

/**
 * Fetches the capabilities metadata offered by the WCS service, including supported versions and coverages information.
 *
 * @param url - The URL to the WCS service endpoint.
 * @param options
 * @returns The WCS Capabilities for the service.
 * @example
 * const capabilities = await wcsUtils.getCapabilities(url);
 * // use capabilities information
 */
export function getCapabilities(url: string, options?: GetCapabilitiesOptions): Promise<WCSCapabilities>;

export interface GetCapabilitiesOptions extends AbortOptions {
  /** A list of key-value pairs of parameters to append to the url. */
  customParameters?: CustomParameters | null;
  /** The version of the WCS service. */
  version?: WCSVersion | null;
}