import { APIResource } from "../../core/resource.mjs"; import { APIPromise } from "../../core/api-promise.mjs"; import { RequestOptions } from "../../internal/request-options.mjs"; export declare class Subscriptions extends APIResource { /** * Cancel a specific subscription for a checkout session */ cancel(subscriptionID: string, params: SubscriptionCancelParams, options?: RequestOptions): APIPromise; /** * Get subscriptions for a specific checkout session */ listForSession(checkoutSessionID: string, query?: SubscriptionListForSessionParams | null | undefined, options?: RequestOptions): APIPromise; } export interface SubscriptionCancelResponse { data?: SubscriptionCancelResponse.Data; message?: string; status?: string; } export declare namespace SubscriptionCancelResponse { interface Data { /** * AgencyServiceSubscriber ID */ id?: string; cancelled_at?: string; /** * Same as id, for backwards compatibility */ subscription_id?: string; subscription_status?: string; } } export interface SubscriptionListForSessionResponse { data?: SubscriptionListForSessionResponse.Data; message?: string; status?: string; } export declare namespace SubscriptionListForSessionResponse { interface Data { pagination?: Data.Pagination; subscriptions?: Array; } namespace Data { interface Pagination { current_page?: number; has_more?: boolean; per_page?: number; total_items?: number; total_pages?: number; } interface Subscription { id?: string; country_code?: string | null; created_at?: string; email?: string | null; first_name?: string | null; last_name?: string | null; next_renewal_date?: string; phone?: string | null; subscription_status?: string; } } } export interface SubscriptionCancelParams { /** * ID of the checkout session */ checkoutSessionId: string; } export interface SubscriptionListForSessionParams { /** * Page number for pagination */ page?: number; /** * Number of items per page */ per_page?: number; } export declare namespace Subscriptions { export { type SubscriptionCancelResponse as SubscriptionCancelResponse, type SubscriptionListForSessionResponse as SubscriptionListForSessionResponse, type SubscriptionCancelParams as SubscriptionCancelParams, type SubscriptionListForSessionParams as SubscriptionListForSessionParams, }; } //# sourceMappingURL=subscriptions.d.mts.map