@ticketto/protocol
Version:
Library that defines the interfaces of the ticketto protocol to be implemented on a client
18 lines (17 loc) • 825 B
TypeScript
export type * from "./directory/index.ts";
export type * from "./events/index.ts";
export type * from "./tickets/index.ts";
export type * from "./client.ts";
import type { ClientConfig, TickettoClient, TickettoConsumer } from "./client.ts";
interface ConstructorOf<S, Config, Consumer = TickettoConsumer<S, Config>> {
new (...params: any[]): Consumer;
}
export declare class TickettoClientBuilder<S = Uint8Array, Config = ClientConfig<S>> {
private consumerLike?;
private config?;
constructor();
withConsumer(consumer: ConstructorOf<S, Config> | TickettoConsumer<S, Config>): TickettoClientBuilder<S, Config>;
withConfig(config: Config): TickettoClientBuilder<S, Config>;
isConstructorOf(consumerLike: unknown): consumerLike is ConstructorOf<S, Config>;
build(): Promise<TickettoClient<S>>;
}