import PortalItem from "@arcgis/core/portal/PortalItem";
/**
 * A Portal URI, which is a special URI in the form "portal://item-id" or
 * "portal://portal-id/item-id".
 */
export declare class PortalUri {
    /**
     * The item's id.
     */
    itemId: string;
    /**
     * The unique ID of the portal where the item is located. See
     * {@link config!Config.portals}.
     */
    portalId: string;
    /**
     * Creates a new PortalUri object.
     *
     * @param uri An optional string representation of a portal:// URI to build
     *   from.
     */
    constructor(uri?: string);
    /**
     * Returns a PortalItem object corresponding to this URI.
     */
    toPortalItem(): PortalItem;
    /**
     * Converts the URI to a string.
     */
    toString(): string;
    /**
     * Returns a new URI that is fully qualified with the given portal ID if
     * this URI does not already have an explicit portal ID.
     *
     * @param portalId The unique ID of the portal.
     */
    toFullyQualifiedUri(portalId: string): PortalUri;
    /**
     * Fetches the item data associated with a given portal item URI.
     *
     * @param responseType The expected type of response.
     */
    fetchData(responseType?: "text"): Promise<string>;
    /**
     * Fetches the item data associated with a given portal item URI.
     *
     * @param responseType The expected type of response.
     */
    fetchData(responseType?: "json" | "xml" | "text" | "blob" | "array-buffer" | "document"): Promise<unknown>;
    private _parseUri;
}
/**
 * Determines whether the given string is a valid portal:// URI.
 *
 * @param value The value to check.
 */
export declare function isPortalUri(value: string): boolean;
/**
 * Determines whether the given string is a fully qualified portal:// URI.
 *
 * @param value The value to check.
 */
export declare function isFullyQualifiedPortalUri(value: string): boolean;
/**
 * Create a fully qualified portal item uri from a short-form portal item URI
 * and its portal's ID.
 *
 * @param uri The short-form portal item URI, e.g.
 *   "portal://139e251e16554cf794fe194081bd2066".
 * @param portalId The ID of the portal within which the portal item exists.
 */
export declare function toFullyQualifiedPortalUri(uri: string, portalId: string): string;
