import * as z from "zod/v4-mini";
import { Result as SafeParseResult } from "../../types/fp.js";
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
import { AttachedCustomField, AttachedCustomField$Outbound } from "./attachedcustomfield.js";
import { Benefit, Benefit$Outbound } from "./benefit.js";
import { LegacyRecurringProductPrice, LegacyRecurringProductPrice$Outbound } from "./legacyrecurringproductprice.js";
import { MetadataOutputType, MetadataOutputType$Outbound } from "./metadataoutputtype.js";
import { ProductMediaFileRead, ProductMediaFileRead$Outbound } from "./productmediafileread.js";
import { ProductPrice, ProductPrice$Outbound } from "./productprice.js";
import { ProductVisibility } from "./productvisibility.js";
import { RecurringInterval } from "./recurringinterval.js";
import { TrialInterval } from "./trialinterval.js";
export type Prices = LegacyRecurringProductPrice | ProductPrice;
/**
 * A product.
 */
export type Product = {
    /**
     * The ID of the object.
     */
    id: string;
    /**
     * Creation timestamp of the object.
     */
    createdAt: Date;
    /**
     * Last modification timestamp of the object.
     */
    modifiedAt: Date | null;
    /**
     * The interval unit for the trial period.
     */
    trialInterval: TrialInterval | null;
    /**
     * The number of interval units for the trial period.
     */
    trialIntervalCount: number | null;
    /**
     * The name of the product.
     */
    name: string;
    /**
     * The description of the product.
     */
    description: string | null;
    visibility: ProductVisibility;
    /**
     * The recurring interval of the product. If `None`, the product is a one-time purchase.
     */
    recurringInterval: RecurringInterval | null;
    /**
     * Number of interval units of the subscription. If this is set to 1 the charge will happen every interval (e.g. every month), if set to 2 it will be every other month, and so on. None for one-time products.
     */
    recurringIntervalCount: number | null;
    /**
     * The meter cycle of the product, independent of the billing interval. If `None`, metered concerns follow the billing interval.
     */
    meterInterval: RecurringInterval | null;
    /**
     * Number of meter interval units. None when no meter cycle is set.
     */
    meterIntervalCount: number | null;
    /**
     * Whether the product is a subscription.
     */
    isRecurring: boolean;
    /**
     * Whether the product is archived and no longer available.
     */
    isArchived: boolean;
    /**
     * The ID of the organization owning the product.
     */
    organizationId: string;
    metadata: {
        [k: string]: MetadataOutputType;
    };
    /**
     * List of prices for this product.
     */
    prices: Array<LegacyRecurringProductPrice | ProductPrice>;
    /**
     * List of benefits granted by the product.
     */
    benefits: Array<Benefit>;
    /**
     * List of medias associated to the product.
     */
    medias: Array<ProductMediaFileRead>;
    /**
     * List of custom fields attached to the product.
     */
    attachedCustomFields: Array<AttachedCustomField>;
};
/** @internal */
export declare const Prices$inboundSchema: z.ZodMiniType<Prices, unknown>;
/** @internal */
export type Prices$Outbound = LegacyRecurringProductPrice$Outbound | ProductPrice$Outbound;
/** @internal */
export declare const Prices$outboundSchema: z.ZodMiniType<Prices$Outbound, Prices>;
export declare function pricesToJSON(prices: Prices): string;
export declare function pricesFromJSON(jsonString: string): SafeParseResult<Prices, SDKValidationError>;
/** @internal */
export declare const Product$inboundSchema: z.ZodMiniType<Product, unknown>;
/** @internal */
export type Product$Outbound = {
    id: string;
    created_at: string;
    modified_at: string | null;
    trial_interval: string | null;
    trial_interval_count: number | null;
    name: string;
    description: string | null;
    visibility: string;
    recurring_interval: string | null;
    recurring_interval_count: number | null;
    meter_interval: string | null;
    meter_interval_count: number | null;
    is_recurring: boolean;
    is_archived: boolean;
    organization_id: string;
    metadata: {
        [k: string]: MetadataOutputType$Outbound;
    };
    prices: Array<LegacyRecurringProductPrice$Outbound | ProductPrice$Outbound>;
    benefits: Array<Benefit$Outbound>;
    medias: Array<ProductMediaFileRead$Outbound>;
    attached_custom_fields: Array<AttachedCustomField$Outbound>;
};
/** @internal */
export declare const Product$outboundSchema: z.ZodMiniType<Product$Outbound, Product>;
export declare function productToJSON(product: Product): string;
export declare function productFromJSON(jsonString: string): SafeParseResult<Product, SDKValidationError>;
//# sourceMappingURL=product.d.ts.map