/// <amd-module name="file:///home/runner/work/hyperliquid/hyperliquid/src/api/subscription/_methods/fastAssetCtxs.ts" />
import * as v from "valibot";
/**
 * Subscription to mark and mid price events for all assets.
 * @see https://hyperliquid.gitbook.io/hyperliquid-docs/for-developers/api/websocket/subscriptions
 */
export declare const FastAssetCtxsRequest: v.ObjectSchema<{
    /** Type of subscription. */
    readonly type: v.LiteralSchema<"fastAssetCtxs", undefined>;
}, undefined>;
export type FastAssetCtxsRequest = v.InferOutput<typeof FastAssetCtxsRequest>;
/**
 * Event of mark and mid prices, keyed by coin.
 *
 * The first message after subscribing is a full snapshot; later messages contain only the changed coins.
 * @see https://hyperliquid.gitbook.io/hyperliquid-docs/for-developers/api/websocket/subscriptions
 */
export type FastAssetCtxsEvent = {
    /** Mark and mid prices for a single asset. */
    [coin: string]: {
        /**
         * Mark price.
         * @pattern ^[0-9]+(\.[0-9]+)?$
         */
        markPx?: string;
        /**
         * Mid price.
         * @pattern ^[0-9]+(\.[0-9]+)?$
         */
        midPx?: string | null;
    };
};
import type { ISubscription } from "../../../transport/mod.js";
import type { SubscriptionConfig, SubscriptionOptions } from "./_base/mod.js";
/**
 * Subscribe to mark and mid prices for all assets.
 *
 * @param config General configuration for Subscription API subscriptions.
 * @param listener A callback function to be called when the event is received.
 * @param options Options to control the subscription lifecycle.
 * @return A request-promise that resolves with a {@link ISubscription} object to manage the subscription lifecycle.
 *
 * @throws {ValidationError} When the request parameters fail validation (before sending).
 * @throws {TransportError} When the transport layer throws an error.
 *
 * @example
 * ```ts
 * import { WebSocketTransport } from "@nktkas/hyperliquid";
 * import { fastAssetCtxs } from "@nktkas/hyperliquid/api/subscription";
 *
 * const transport = new WebSocketTransport();
 *
 * const sub = await fastAssetCtxs(
 *   { transport },
 *   (data) => console.log(data),
 * );
 * ```
 *
 * @see https://hyperliquid.gitbook.io/hyperliquid-docs/for-developers/api/websocket/subscriptions
 */
export declare function fastAssetCtxs(config: SubscriptionConfig, listener: (data: FastAssetCtxsEvent) => void, options?: SubscriptionOptions): Promise<ISubscription>;
