import { FeedUpdateOptions } from '../modules/feed';
import { BatchId, BytesReference, FEED_INDEX_HEX_LENGTH, FeedReader, FeedWriter, Ky, PlainBytesReference, Reference, Signer, Topic, UploadOptions } from '../types';
import { Bytes } from '../utils/bytes';
import { HexString } from '../utils/hex';
import { EthAddress, HexEthAddress } from '../utils/eth';
import type { FeedType } from './type';
export interface Epoch {
    time: number;
    level: number;
}
/**
 * Bytes of Feed's Index.
 * For Sequential Feeds this is numeric value in big-endian.
 */
export declare type IndexBytes = Bytes<8>;
export declare type Index = number | Epoch | IndexBytes | string;
export interface FeedUploadOptions extends UploadOptions, FeedUpdateOptions {
}
export interface FeedUpdate {
    timestamp: number;
    reference: BytesReference;
}
export declare function findNextIndex(ky: Ky, owner: HexEthAddress, topic: Topic, options?: FeedUpdateOptions): Promise<HexString<typeof FEED_INDEX_HEX_LENGTH>>;
export declare function updateFeed(ky: Ky, signer: Signer, topic: Topic, reference: BytesReference, postageBatchId: BatchId, options?: FeedUploadOptions, index?: Index): Promise<Reference>;
export declare function getFeedUpdateChunkReference(owner: EthAddress, topic: Topic, index: Index): PlainBytesReference;
export declare function downloadFeedUpdate(ky: Ky, owner: EthAddress, topic: Topic, index: Index): Promise<FeedUpdate>;
export declare function makeFeedReader(ky: Ky, type: FeedType, topic: Topic, owner: HexEthAddress): FeedReader;
export declare function makeFeedWriter(ky: Ky, type: FeedType, topic: Topic, signer: Signer): FeedWriter;
