import type { BaseClientOptions, BaseRequestOptions } from "../../../../BaseClient.mjs"; import { type NormalizedClientOptionsWithAuth } from "../../../../BaseClient.mjs"; import * as core from "../../../../core/index.mjs"; import * as Whop from "../../../index.mjs"; export declare namespace PartnerReferralRequestsClient { type Options = BaseClientOptions; interface RequestOptions extends BaseRequestOptions { } } /** * A Partner Referral Request is a partner's referral link, or a request to be credited as the referrer of an existing business or user. An attribution request takes effect only when the recipient accepts it. * * Use the Partner Referral Requests API to create referral links, send attribution requests, list the links and requests you've sent or received, and accept, decline, or cancel a pending request. */ export declare class PartnerReferralRequestsClient { protected readonly _options: NormalizedClientOptionsWithAuth; constructor(options?: PartnerReferralRequestsClient.Options); /** * Lists your referral links and attribution requests, including incoming requests for you or businesses you own, with filters for recipient, partner, type, and status. * * @param {Whop.ListPartnerReferralRequestsRequest} request * @param {PartnerReferralRequestsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Whop.BadRequestError} * @throws {@link Whop.UnauthorizedError} * @throws {@link Whop.ForbiddenError} * @throws {@link errors.WhopError} * @throws {@link errors.WhopTimeoutError} * * @example * await client.partnerReferralRequests.list() */ list(request?: Whop.ListPartnerReferralRequestsRequest, requestOptions?: PartnerReferralRequestsClient.RequestOptions): Promise>; /** * Creates a referral link, or sends an attribution request to an existing business or user for approval. Links require an enrolled partner who is not suspended; attribution requests require an enrolled, verified partner. Recipients do not need to join the partner program. * * @param {Whop.CreatePartnerReferralRequestsRequestBody} request * @param {PartnerReferralRequestsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Whop.BadRequestError} * @throws {@link Whop.UnauthorizedError} * @throws {@link Whop.ForbiddenError} * @throws {@link Whop.NotFoundError} * @throws {@link Whop.ConflictError} * @throws {@link errors.WhopError} * @throws {@link errors.WhopTimeoutError} * * @example * await client.partnerReferralRequests.create({ * account_id: "biz_xxxxxxxxxxxxxx" * }) */ create(request: Whop.CreatePartnerReferralRequestsRequestBody, requestOptions?: PartnerReferralRequestsClient.RequestOptions): core.HttpResponsePromise; private __create; /** * Retrieves a referral link or attribution request by ID, including its partner, recipient, approval status, and referral code when present. * * @param {Whop.RetrievePartnerReferralRequestsRequest} request * @param {PartnerReferralRequestsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Whop.UnauthorizedError} * @throws {@link Whop.ForbiddenError} * @throws {@link Whop.NotFoundError} * @throws {@link errors.WhopError} * @throws {@link errors.WhopTimeoutError} * * @example * await client.partnerReferralRequests.retrieve({ * id: "id" * }) */ retrieve(request: Whop.RetrievePartnerReferralRequestsRequest, requestOptions?: PartnerReferralRequestsClient.RequestOptions): core.HttpResponsePromise; private __retrieve; /** * Accepts a pending attribution request as the receiving user or business owner, assigning the requesting partner as that user's or business's referrer. * * @param {Whop.AcceptPartnerReferralRequestsRequest} request * @param {PartnerReferralRequestsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Whop.UnauthorizedError} * @throws {@link Whop.ForbiddenError} * @throws {@link Whop.NotFoundError} * @throws {@link Whop.ConflictError} * @throws {@link errors.WhopError} * @throws {@link errors.WhopTimeoutError} * * @example * await client.partnerReferralRequests.accept({ * id: "id" * }) */ accept(request: Whop.AcceptPartnerReferralRequestsRequest, requestOptions?: PartnerReferralRequestsClient.RequestOptions): core.HttpResponsePromise; private __accept; /** * Cancels a pending attribution request you sent so the recipient can no longer accept it, and returns the cancelled request. * * @param {Whop.CancelPartnerReferralRequestsRequest} request * @param {PartnerReferralRequestsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Whop.UnauthorizedError} * @throws {@link Whop.ForbiddenError} * @throws {@link Whop.NotFoundError} * @throws {@link Whop.ConflictError} * @throws {@link errors.WhopError} * @throws {@link errors.WhopTimeoutError} * * @example * await client.partnerReferralRequests.cancel({ * id: "id" * }) */ cancel(request: Whop.CancelPartnerReferralRequestsRequest, requestOptions?: PartnerReferralRequestsClient.RequestOptions): core.HttpResponsePromise; private __cancel; /** * Declines a pending attribution request for you or a business you own, marking it as denied without assigning the requesting partner as a referrer. * * @param {Whop.DeclinePartnerReferralRequestsRequest} request * @param {PartnerReferralRequestsClient.RequestOptions} requestOptions - Request-specific configuration. * * @throws {@link Whop.UnauthorizedError} * @throws {@link Whop.ForbiddenError} * @throws {@link Whop.NotFoundError} * @throws {@link Whop.ConflictError} * @throws {@link errors.WhopError} * @throws {@link errors.WhopTimeoutError} * * @example * await client.partnerReferralRequests.decline({ * id: "id" * }) */ decline(request: Whop.DeclinePartnerReferralRequestsRequest, requestOptions?: PartnerReferralRequestsClient.RequestOptions): core.HttpResponsePromise; private __decline; }