import type { BaseClientOptions, BaseRequestOptions } from "../../../../BaseClient.js"; import { type NormalizedClientOptionsWithAuth } from "../../../../BaseClient.js"; import * as core from "../../../../core/index.js"; import * as Whop from "../../../index.js"; export declare namespace LeadsClient { type Options = BaseClientOptions; interface RequestOptions extends BaseRequestOptions { } } export declare class LeadsClient { protected readonly _options: NormalizedClientOptionsWithAuth; constructor(options?: LeadsClient.Options); /** * Lists an account's leads, newest first. * * Required permissions: * - `lead:basic:read` * - `member:email:read` * - `access_pass:basic:read` * - `member:basic:read` * * @param {Whop.ListLeadsRequest} request * @param {LeadsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Whop.BadRequestError} * @throws {@link Whop.UnauthorizedError} * @throws {@link Whop.ForbiddenError} * @throws {@link Whop.NotFoundError} * @throws {@link Whop.UnprocessableEntityError} * @throws {@link Whop.TooManyRequestsError} * @throws {@link Whop.InternalServerError} * @throws {@link errors.WhopError} * @throws {@link errors.WhopTimeoutError} * * @example * await client.leads.list({ * first: 42, * last: 42, * created_after: "2023-12-01T05:00:00Z", * created_before: "2023-12-01T05:00:00Z", * account_id: "biz_xxxxxxxxxxxxxx" * }) */ list(request: Whop.ListLeadsRequest, requestOptions?: LeadsClient.RequestOptions): Promise>; /** * Records a lead: a potential customer's interest in an account or one of its products. * * Required permissions: * - `lead:manage` * - `member:email:read` * - `access_pass:basic:read` * - `member:basic:read` * * @param {Whop.CreateLeadsRequest} request * @param {LeadsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Whop.BadRequestError} * @throws {@link Whop.UnauthorizedError} * @throws {@link Whop.ForbiddenError} * @throws {@link Whop.NotFoundError} * @throws {@link Whop.UnprocessableEntityError} * @throws {@link Whop.TooManyRequestsError} * @throws {@link Whop.InternalServerError} * @throws {@link errors.WhopError} * @throws {@link errors.WhopTimeoutError} * * @example * await client.leads.create({ * account_id: "biz_xxxxxxxxxxxxxx" * }) */ create(request: Whop.CreateLeadsRequest, requestOptions?: LeadsClient.RequestOptions): core.HttpResponsePromise; private __create; /** * Retrieves the details of an existing lead. * * Required permissions: * - `lead:basic:read` * - `member:email:read` * - `access_pass:basic:read` * - `member:basic:read` * * @param {Whop.RetrieveLeadsRequest} request * @param {LeadsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Whop.BadRequestError} * @throws {@link Whop.UnauthorizedError} * @throws {@link Whop.ForbiddenError} * @throws {@link Whop.NotFoundError} * @throws {@link Whop.UnprocessableEntityError} * @throws {@link Whop.TooManyRequestsError} * @throws {@link Whop.InternalServerError} * @throws {@link errors.WhopError} * @throws {@link errors.WhopTimeoutError} * * @example * await client.leads.retrieve({ * id: "lead_xxxxxxxxxxxxx" * }) */ retrieve(request: Whop.RetrieveLeadsRequest, requestOptions?: LeadsClient.RequestOptions): core.HttpResponsePromise; private __retrieve; /** * Updates a lead's `metadata` or `referrer`. * * Required permissions: * - `lead:manage` * - `member:email:read` * - `access_pass:basic:read` * - `member:basic:read` * * @param {Whop.UpdateLeadsRequest} request * @param {LeadsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Whop.BadRequestError} * @throws {@link Whop.UnauthorizedError} * @throws {@link Whop.ForbiddenError} * @throws {@link Whop.NotFoundError} * @throws {@link Whop.UnprocessableEntityError} * @throws {@link Whop.TooManyRequestsError} * @throws {@link Whop.InternalServerError} * @throws {@link errors.WhopError} * @throws {@link errors.WhopTimeoutError} * * @example * await client.leads.update({ * id: "lead_xxxxxxxxxxxxx" * }) */ update(request: Whop.UpdateLeadsRequest, requestOptions?: LeadsClient.RequestOptions): core.HttpResponsePromise; private __update; }