// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. import { APIResource } from '../core/resource'; import { APIPromise } from '../core/api-promise'; import { RequestOptions } from '../internal/request-options'; export class Products extends APIResource { /** * List all products for a creator */ list( query: ProductListParams | null | undefined = {}, options?: RequestOptions, ): APIPromise { return this._client.get('/products', { query, ...options }); } } export interface ProductListResponse { data?: ProductListResponse.Data; message?: string; status?: string; } export namespace ProductListResponse { export interface Data { current_page?: number; data?: Array; first_page_url?: string; from?: number; last_page?: number; last_page_url?: string; next_page_url?: string | null; path?: string; per_page?: number; prev_page_url?: string | null; to?: number; total?: number; } export namespace Data { export interface Data { id?: string; description?: string | null; internal_name?: string | null; payment_link?: string; price?: number; title?: string; } } } export interface ProductListParams { /** * Page number for pagination */ page?: number; /** * Number of items per page */ per_page?: number; } export declare namespace Products { export { type ProductListResponse as ProductListResponse, type ProductListParams as ProductListParams }; }