# Generated by ariadne-codegen on 2023-07-25 15:34
# Source: ../api-client-schema/src/generated/schema.graphql

from typing import Any, List, Optional

from pydantic import Field

from .base_model import BaseModel
from .enums import (
    AccessDeniedReason,
    AddonSortFields,
    AggregationFunction,
    Alignment,
    ApiKeySortFields,
    BillingAnchor,
    BillingModel,
    BillingPeriod,
    ConditionOperation,
    CouponSortFields,
    CouponStatus,
    CouponType,
    Currency,
    CustomerResourceSortFields,
    CustomerSortFields,
    CustomerSubscriptionSortFields,
    Department,
    EntitlementResetPeriod,
    EntitySelectionMode,
    EnvironmentProvisionStatus,
    EnvironmentSortFields,
    EventLogType,
    ExperimentSortFields,
    ExperimentStatus,
    FeatureSortFields,
    FeatureStatus,
    FeatureType,
    FontWeight,
    HookSortFields,
    HookStatus,
    ImportIntegrationTaskSortFields,
    IntegrationSortFields,
    MemberSortFields,
    MeterType,
    MonthlyAccordingTo,
    PackageDTOSortFields,
    PackageEntitlementSortFields,
    PackageStatus,
    PlanSortFields,
    PriceSortFields,
    PricingType,
    ProductSortFields,
    PromotionalEntitlementPeriod,
    PromotionalEntitlementSortFields,
    PromotionalEntitlementStatus,
    ProrationBehavior,
    PublishMigrationType,
    SortDirection,
    SortNulls,
    SubscriptionAddonSortFields,
    SubscriptionCancellationTime,
    SubscriptionCancelReason,
    SubscriptionEndSetup,
    SubscriptionEntitlementSortFields,
    SubscriptionMigrationTaskSortFields,
    SubscriptionMigrationTime,
    SubscriptionPriceSortFields,
    SubscriptionStartSetup,
    SubscriptionStatus,
    TaskStatus,
    TaskType,
    TrialPeriodUnits,
    UsageMeasurementSortFields,
    UsageUpdateBehavior,
    VendorIdentifier,
    WeeklyAccordingTo,
    WidgetType,
)


class AddCompatibleAddonsToPlanInput(BaseModel):
    id: str
    relation_ids: List[str] = Field(alias="relationIds")


class AddonCreateInput(BaseModel):
    additional_meta_data: Optional[Any] = Field(alias="additionalMetaData")
    billing_id: Optional[str] = Field(alias="billingId")
    description: Optional[str]
    display_name: str = Field(alias="displayName")
    environment_id: Optional[str] = Field(alias="environmentId")
    hidden_from_widgets: Optional[List[WidgetType]] = Field(alias="hiddenFromWidgets")
    product_id: str = Field(alias="productId")
    ref_id: Optional[str] = Field(alias="refId")
    status: Optional[PackageStatus]


class AddonFilter(BaseModel):
    and_: Optional[List["AddonFilter"]] = Field(alias="and")
    billing_id: Optional["StringFieldComparison"] = Field(alias="billingId")
    created_at: Optional["DateFieldComparison"] = Field(alias="createdAt")
    description: Optional["StringFieldComparison"]
    display_name: Optional["StringFieldComparison"] = Field(alias="displayName")
    environment_id: Optional["StringFieldComparison"] = Field(alias="environmentId")
    id: Optional["StringFieldComparison"]
    is_latest: Optional["BooleanFieldComparison"] = Field(alias="isLatest")
    or_: Optional[List["AddonFilter"]] = Field(alias="or")
    pricing_type: Optional["PricingTypeFilterComparison"] = Field(alias="pricingType")
    product_id: Optional["StringFieldComparison"] = Field(alias="productId")
    ref_id: Optional["StringFieldComparison"] = Field(alias="refId")
    status: Optional["PackageStatusFilterComparison"]
    updated_at: Optional["DateFieldComparison"] = Field(alias="updatedAt")
    version_number: Optional["IntFieldComparison"] = Field(alias="versionNumber")


class AddonSort(BaseModel):
    direction: SortDirection
    field: AddonSortFields
    nulls: Optional[SortNulls]


class AddonUpdateInput(BaseModel):
    additional_meta_data: Optional[Any] = Field(alias="additionalMetaData")
    billing_id: Optional[str] = Field(alias="billingId")
    description: Optional[str]
    display_name: str = Field(alias="displayName")
    hidden_from_widgets: Optional[List[WidgetType]] = Field(alias="hiddenFromWidgets")
    id: str
    status: Optional[PackageStatus]


class Address(BaseModel):
    address_line1: Optional[str] = Field(alias="addressLine1")
    address_line2: Optional[str] = Field(alias="addressLine2")
    city: Optional[str]
    country: Optional[str]
    phone_number: Optional[str] = Field(alias="phoneNumber")
    postal_code: Optional[str] = Field(alias="postalCode")
    state: Optional[str]


class AggregatedEventsByCustomerInput(BaseModel):
    aggregation: "MeterAggregation"
    customer_id: Optional[str] = Field(alias="customerId")
    environment_id: str = Field(alias="environmentId")
    filters: List["MeterFilterDefinitionInput"]


class ApiKeyFilter(BaseModel):
    and_: Optional[List["ApiKeyFilter"]] = Field(alias="and")
    id: Optional["StringFieldComparison"]
    or_: Optional[List["ApiKeyFilter"]] = Field(alias="or")


class ApiKeySort(BaseModel):
    direction: SortDirection
    field: ApiKeySortFields
    nulls: Optional[SortNulls]


class ArchiveCouponInput(BaseModel):
    environment_id: Optional[str] = Field(alias="environmentId")
    ref_id: str = Field(alias="refId")


class ArchiveCustomerInput(BaseModel):
    customer_id: str = Field(alias="customerId")
    environment_id: Optional[str] = Field(alias="environmentId")


class ArchivePlanInput(BaseModel):
    environment_id: Optional[str] = Field(alias="environmentId")
    id: str


class AttachCustomerPaymentMethodInput(BaseModel):
    customer_id: Optional[str] = Field(alias="customerId")
    environment_id: Optional[str] = Field(alias="environmentId")
    payment_method_id: str = Field(alias="paymentMethodId")
    ref_id: Optional[str] = Field(alias="refId")
    vendor_identifier: VendorIdentifier = Field(alias="vendorIdentifier")


class BillableFeatureInput(BaseModel):
    feature_id: str = Field(alias="featureId")
    quantity: float


class BillingModelFilterComparison(BaseModel):
    eq: Optional[BillingModel]
    gt: Optional[BillingModel]
    gte: Optional[BillingModel]
    i_like: Optional[BillingModel] = Field(alias="iLike")
    in_: Optional[List[BillingModel]] = Field(alias="in")
    is_: Optional[bool] = Field(alias="is")
    is_not: Optional[bool] = Field(alias="isNot")
    like: Optional[BillingModel]
    lt: Optional[BillingModel]
    lte: Optional[BillingModel]
    neq: Optional[BillingModel]
    not_i_like: Optional[BillingModel] = Field(alias="notILike")
    not_in: Optional[List[BillingModel]] = Field(alias="notIn")
    not_like: Optional[BillingModel] = Field(alias="notLike")


class BillingPeriodFilterComparison(BaseModel):
    eq: Optional[BillingPeriod]
    gt: Optional[BillingPeriod]
    gte: Optional[BillingPeriod]
    i_like: Optional[BillingPeriod] = Field(alias="iLike")
    in_: Optional[List[BillingPeriod]] = Field(alias="in")
    is_: Optional[bool] = Field(alias="is")
    is_not: Optional[bool] = Field(alias="isNot")
    like: Optional[BillingPeriod]
    lt: Optional[BillingPeriod]
    lte: Optional[BillingPeriod]
    neq: Optional[BillingPeriod]
    not_i_like: Optional[BillingPeriod] = Field(alias="notILike")
    not_in: Optional[List[BillingPeriod]] = Field(alias="notIn")
    not_like: Optional[BillingPeriod] = Field(alias="notLike")


class BooleanFieldComparison(BaseModel):
    is_: Optional[bool] = Field(alias="is")
    is_not: Optional[bool] = Field(alias="isNot")


class CheckoutOptions(BaseModel):
    allow_promo_codes: Optional[bool] = Field(alias="allowPromoCodes", default=False)
    allow_tax_id_collection: Optional[bool] = Field(
        alias="allowTaxIdCollection", default=False
    )
    cancel_url: str = Field(alias="cancelUrl")
    collect_billing_address: Optional[bool] = Field(
        alias="collectBillingAddress", default=False
    )
    collect_phone_number: Optional[bool] = Field(
        alias="collectPhoneNumber", default=False
    )
    reference_id: Optional[str] = Field(alias="referenceId")
    success_url: str = Field(alias="successUrl")


class ClearCustomerPersistentCacheInput(BaseModel):
    customer_id: str = Field(alias="customerId")
    environment_id: Optional[str] = Field(alias="environmentId")
    resource_id: Optional[str] = Field(alias="resourceId")


class CouponFilter(BaseModel):
    and_: Optional[List["CouponFilter"]] = Field(alias="and")
    billing_id: Optional["StringFieldComparison"] = Field(alias="billingId")
    created_at: Optional["DateFieldComparison"] = Field(alias="createdAt")
    customers: Optional["CouponFilterCustomerFilter"]
    description: Optional["StringFieldComparison"]
    environment_id: Optional["StringFieldComparison"] = Field(alias="environmentId")
    id: Optional["StringFieldComparison"]
    name: Optional["StringFieldComparison"]
    or_: Optional[List["CouponFilter"]] = Field(alias="or")
    ref_id: Optional["StringFieldComparison"] = Field(alias="refId")
    status: Optional["CouponStatusFilterComparison"]
    type: Optional["CouponTypeFilterComparison"]
    updated_at: Optional["DateFieldComparison"] = Field(alias="updatedAt")


class CouponFilterCustomerFilter(BaseModel):
    and_: Optional[List["CouponFilterCustomerFilter"]] = Field(alias="and")
    billing_id: Optional["StringFieldComparison"] = Field(alias="billingId")
    created_at: Optional["DateFieldComparison"] = Field(alias="createdAt")
    crm_hubspot_company_id: Optional["StringFieldComparison"] = Field(
        alias="crmHubspotCompanyId"
    )
    crm_hubspot_company_url: Optional["StringFieldComparison"] = Field(
        alias="crmHubspotCompanyUrl"
    )
    crm_id: Optional["StringFieldComparison"] = Field(alias="crmId")
    customer_id: Optional["StringFieldComparison"] = Field(alias="customerId")
    deleted_at: Optional["DateFieldComparison"] = Field(alias="deletedAt")
    email: Optional["StringFieldComparison"]
    environment_id: Optional["StringFieldComparison"] = Field(alias="environmentId")
    id: Optional["StringFieldComparison"]
    name: Optional["StringFieldComparison"]
    or_: Optional[List["CouponFilterCustomerFilter"]] = Field(alias="or")
    ref_id: Optional["StringFieldComparison"] = Field(alias="refId")
    updated_at: Optional["DateFieldComparison"] = Field(alias="updatedAt")


class CouponSort(BaseModel):
    direction: SortDirection
    field: CouponSortFields
    nulls: Optional[SortNulls]


class CouponStatusFilterComparison(BaseModel):
    eq: Optional[CouponStatus]
    gt: Optional[CouponStatus]
    gte: Optional[CouponStatus]
    i_like: Optional[CouponStatus] = Field(alias="iLike")
    in_: Optional[List[CouponStatus]] = Field(alias="in")
    is_: Optional[bool] = Field(alias="is")
    is_not: Optional[bool] = Field(alias="isNot")
    like: Optional[CouponStatus]
    lt: Optional[CouponStatus]
    lte: Optional[CouponStatus]
    neq: Optional[CouponStatus]
    not_i_like: Optional[CouponStatus] = Field(alias="notILike")
    not_in: Optional[List[CouponStatus]] = Field(alias="notIn")
    not_like: Optional[CouponStatus] = Field(alias="notLike")


class CouponTypeFilterComparison(BaseModel):
    eq: Optional[CouponType]
    gt: Optional[CouponType]
    gte: Optional[CouponType]
    i_like: Optional[CouponType] = Field(alias="iLike")
    in_: Optional[List[CouponType]] = Field(alias="in")
    is_: Optional[bool] = Field(alias="is")
    is_not: Optional[bool] = Field(alias="isNot")
    like: Optional[CouponType]
    lt: Optional[CouponType]
    lte: Optional[CouponType]
    neq: Optional[CouponType]
    not_i_like: Optional[CouponType] = Field(alias="notILike")
    not_in: Optional[List[CouponType]] = Field(alias="notIn")
    not_like: Optional[CouponType] = Field(alias="notLike")


class CreateCouponInput(BaseModel):
    additional_meta_data: Optional[Any] = Field(alias="additionalMetaData")
    description: Optional[str]
    discount_value: float = Field(alias="discountValue")
    environment_id: Optional[str] = Field(alias="environmentId")
    name: str
    ref_id: str = Field(alias="refId")
    type: CouponType


class CreateEnvironment(BaseModel):
    color: Optional[str]
    created_at: Optional[Any] = Field(alias="createdAt")
    description: Optional[str]
    display_name: Optional[str] = Field(alias="displayName")
    harden_client_access_enabled: Optional[bool] = Field(
        alias="hardenClientAccessEnabled"
    )
    id: Optional[str]
    provision_status: Optional[EnvironmentProvisionStatus] = Field(
        alias="provisionStatus"
    )
    slug: Optional[str]


class CreateEnvironmentOptions(BaseModel):
    create_default_product: Optional[bool] = Field(alias="createDefaultProduct")


class CreateExperimentInput(BaseModel):
    control_group_name: str = Field(alias="controlGroupName")
    description: Optional[str]
    environment_id: Optional[str] = Field(alias="environmentId")
    name: str
    product_id: str = Field(alias="productId")
    product_settings: Optional["ProductSettingsInput"] = Field(alias="productSettings")
    variant_group_name: str = Field(alias="variantGroupName")
    variant_percentage: float = Field(alias="variantPercentage")


class CreateHook(BaseModel):
    created_at: Optional[Any] = Field(alias="createdAt")
    description: Optional[str]
    endpoint: Optional[str]
    environment_id: Optional[str] = Field(alias="environmentId")
    event_log_types: Optional[List[EventLogType]] = Field(alias="eventLogTypes")
    id: Optional[str]
    secret_key: Optional[str] = Field(alias="secretKey")
    status: Optional[HookStatus]


class CreateIntegrationInput(BaseModel):
    environment_id: str = Field(alias="environmentId")
    hubspot_credentials: Optional["HubspotCredentialsInput"] = Field(
        alias="hubspotCredentials"
    )
    stripe_credentials: Optional["StripeCredentialsInput"] = Field(
        alias="stripeCredentials"
    )
    vendor_identifier: VendorIdentifier = Field(alias="vendorIdentifier")
    zuora_credentials: Optional["ZuoraCredentialsInput"] = Field(
        alias="zuoraCredentials"
    )


class CreateManyPackageEntitlementsInput(BaseModel):
    package_entitlements: List["PackageEntitlementInput"] = Field(
        alias="packageEntitlements"
    )


class CreateManyPromotionalEntitlementsInput(BaseModel):
    promotional_entitlements: List["PromotionalEntitlementInput"] = Field(
        alias="promotionalEntitlements"
    )


class CreateMeter(BaseModel):
    aggregation: "MeterAggregation"
    filters: List["MeterFilterDefinitionInput"]


class CreateOneEnvironmentInput(BaseModel):
    environment: "CreateEnvironment"
    options: Optional["CreateEnvironmentOptions"]


class CreateOneFeatureInput(BaseModel):
    feature: "FeatureInput"


class CreateOneHookInput(BaseModel):
    hook: "CreateHook"


class CreateOneIntegrationInput(BaseModel):
    integration: "CreateIntegrationInput"


class CreateOneProductInput(BaseModel):
    product: "ProductCreateInput"


class CursorPaging(BaseModel):
    after: Optional[Any]
    before: Optional[Any]
    first: Optional[int]
    last: Optional[int]


class CustomerBillingInfo(BaseModel):
    billing_address: Optional["Address"] = Field(alias="billingAddress")
    currency: Optional[Currency] = Currency.USD
    customer_name: Optional[str] = Field(alias="customerName")
    invoice_custom_fields: Optional[Any] = Field(alias="invoiceCustomFields")
    language: Optional[str]
    metadata: Optional[Any]
    payment_method_id: Optional[str] = Field(alias="paymentMethodId")
    shipping_address: Optional["Address"] = Field(alias="shippingAddress")
    tax_ids: Optional[List["TaxExempt"]] = Field(alias="taxIds")
    timezone: Optional[str]


class CustomerFilter(BaseModel):
    and_: Optional[List["CustomerFilter"]] = Field(alias="and")
    billing_id: Optional["StringFieldComparison"] = Field(alias="billingId")
    created_at: Optional["DateFieldComparison"] = Field(alias="createdAt")
    crm_hubspot_company_id: Optional["StringFieldComparison"] = Field(
        alias="crmHubspotCompanyId"
    )
    crm_hubspot_company_url: Optional["StringFieldComparison"] = Field(
        alias="crmHubspotCompanyUrl"
    )
    crm_id: Optional["StringFieldComparison"] = Field(alias="crmId")
    customer_id: Optional["StringFieldComparison"] = Field(alias="customerId")
    deleted_at: Optional["DateFieldComparison"] = Field(alias="deletedAt")
    email: Optional["StringFieldComparison"]
    environment_id: Optional["StringFieldComparison"] = Field(alias="environmentId")
    id: Optional["StringFieldComparison"]
    name: Optional["StringFieldComparison"]
    or_: Optional[List["CustomerFilter"]] = Field(alias="or")
    promotional_entitlements: Optional[
        "CustomerFilterPromotionalEntitlementFilter"
    ] = Field(alias="promotionalEntitlements")
    ref_id: Optional["StringFieldComparison"] = Field(alias="refId")
    subscriptions: Optional["CustomerFilterCustomerSubscriptionFilter"]
    updated_at: Optional["DateFieldComparison"] = Field(alias="updatedAt")


class CustomerFilterCustomerSubscriptionFilter(BaseModel):
    and_: Optional[List["CustomerFilterCustomerSubscriptionFilter"]] = Field(
        alias="and"
    )
    billing_id: Optional["StringFieldComparison"] = Field(alias="billingId")
    cancel_reason: Optional["SubscriptionCancelReasonFilterComparison"] = Field(
        alias="cancelReason"
    )
    cancellation_date: Optional["DateFieldComparison"] = Field(alias="cancellationDate")
    created_at: Optional["DateFieldComparison"] = Field(alias="createdAt")
    crm_id: Optional["StringFieldComparison"] = Field(alias="crmId")
    crm_link_url: Optional["StringFieldComparison"] = Field(alias="crmLinkUrl")
    effective_end_date: Optional["DateFieldComparison"] = Field(
        alias="effectiveEndDate"
    )
    end_date: Optional["DateFieldComparison"] = Field(alias="endDate")
    environment_id: Optional["StringFieldComparison"] = Field(alias="environmentId")
    id: Optional["StringFieldComparison"]
    old_billing_id: Optional["StringFieldComparison"] = Field(alias="oldBillingId")
    or_: Optional[List["CustomerFilterCustomerSubscriptionFilter"]] = Field(alias="or")
    pricing_type: Optional["PricingTypeFilterComparison"] = Field(alias="pricingType")
    ref_id: Optional["StringFieldComparison"] = Field(alias="refId")
    resource_id: Optional["StringFieldComparison"] = Field(alias="resourceId")
    start_date: Optional["DateFieldComparison"] = Field(alias="startDate")
    status: Optional["SubscriptionStatusFilterComparison"]
    subscription_id: Optional["StringFieldComparison"] = Field(alias="subscriptionId")
    trial_end_date: Optional["DateFieldComparison"] = Field(alias="trialEndDate")


class CustomerFilterPromotionalEntitlementFilter(BaseModel):
    and_: Optional[List["CustomerFilterPromotionalEntitlementFilter"]] = Field(
        alias="and"
    )
    created_at: Optional["DateFieldComparison"] = Field(alias="createdAt")
    environment_id: Optional["StringFieldComparison"] = Field(alias="environmentId")
    id: Optional["StringFieldComparison"]
    or_: Optional[List["CustomerFilterPromotionalEntitlementFilter"]] = Field(
        alias="or"
    )
    status: Optional["PromotionalEntitlementStatusFilterComparison"]
    updated_at: Optional["DateFieldComparison"] = Field(alias="updatedAt")


class CustomerInput(BaseModel):
    additional_meta_data: Optional[Any] = Field(alias="additionalMetaData")
    billing_id: Optional[str] = Field(alias="billingId")
    billing_information: Optional["CustomerBillingInfo"] = Field(
        alias="billingInformation"
    )
    coupon_ref_id: Optional[str] = Field(alias="couponRefId")
    created_at: Optional[Any] = Field(alias="createdAt")
    crm_id: Optional[str] = Field(alias="crmId")
    customer_id: Optional[str] = Field(alias="customerId")
    email: Optional[str]
    environment_id: Optional[str] = Field(alias="environmentId")
    name: Optional[str]
    ref_id: Optional[str] = Field(alias="refId")
    should_sync_free: Optional[bool] = Field(alias="shouldSyncFree", default=False)


class CustomerPortalColorsPaletteInput(BaseModel):
    background_color: Optional[str] = Field(alias="backgroundColor")
    border_color: Optional[str] = Field(alias="borderColor")
    current_plan_background: Optional[str] = Field(alias="currentPlanBackground")
    icons_color: Optional[str] = Field(alias="iconsColor")
    paywall_background_color: Optional[str] = Field(alias="paywallBackgroundColor")
    primary: Optional[str]
    text_color: Optional[str] = Field(alias="textColor")


class CustomerPortalConfigurationInput(BaseModel):
    custom_css: Optional[str] = Field(alias="customCss")
    palette: Optional["CustomerPortalColorsPaletteInput"]
    typography: Optional["TypographyConfigurationInput"]


class CustomerPortalInput(BaseModel):
    customer_id: str = Field(alias="customerId")
    product_id: Optional[str] = Field(alias="productId")
    resource_id: Optional[str] = Field(alias="resourceId")


class CustomerResourceFilter(BaseModel):
    and_: Optional[List["CustomerResourceFilter"]] = Field(alias="and")
    created_at: Optional["DateFieldComparison"] = Field(alias="createdAt")
    customer: Optional["CustomerResourceFilterCustomerFilter"]
    environment_id: Optional["StringFieldComparison"] = Field(alias="environmentId")
    or_: Optional[List["CustomerResourceFilter"]] = Field(alias="or")
    resource_id: Optional["StringFieldComparison"] = Field(alias="resourceId")
    subscriptions: Optional["CustomerResourceFilterCustomerSubscriptionFilter"]


class CustomerResourceFilterCustomerFilter(BaseModel):
    and_: Optional[List["CustomerResourceFilterCustomerFilter"]] = Field(alias="and")
    billing_id: Optional["StringFieldComparison"] = Field(alias="billingId")
    created_at: Optional["DateFieldComparison"] = Field(alias="createdAt")
    crm_hubspot_company_id: Optional["StringFieldComparison"] = Field(
        alias="crmHubspotCompanyId"
    )
    crm_hubspot_company_url: Optional["StringFieldComparison"] = Field(
        alias="crmHubspotCompanyUrl"
    )
    crm_id: Optional["StringFieldComparison"] = Field(alias="crmId")
    customer_id: Optional["StringFieldComparison"] = Field(alias="customerId")
    deleted_at: Optional["DateFieldComparison"] = Field(alias="deletedAt")
    email: Optional["StringFieldComparison"]
    environment_id: Optional["StringFieldComparison"] = Field(alias="environmentId")
    id: Optional["StringFieldComparison"]
    name: Optional["StringFieldComparison"]
    or_: Optional[List["CustomerResourceFilterCustomerFilter"]] = Field(alias="or")
    ref_id: Optional["StringFieldComparison"] = Field(alias="refId")
    updated_at: Optional["DateFieldComparison"] = Field(alias="updatedAt")


class CustomerResourceFilterCustomerSubscriptionFilter(BaseModel):
    and_: Optional[List["CustomerResourceFilterCustomerSubscriptionFilter"]] = Field(
        alias="and"
    )
    billing_id: Optional["StringFieldComparison"] = Field(alias="billingId")
    cancel_reason: Optional["SubscriptionCancelReasonFilterComparison"] = Field(
        alias="cancelReason"
    )
    cancellation_date: Optional["DateFieldComparison"] = Field(alias="cancellationDate")
    created_at: Optional["DateFieldComparison"] = Field(alias="createdAt")
    crm_id: Optional["StringFieldComparison"] = Field(alias="crmId")
    crm_link_url: Optional["StringFieldComparison"] = Field(alias="crmLinkUrl")
    effective_end_date: Optional["DateFieldComparison"] = Field(
        alias="effectiveEndDate"
    )
    end_date: Optional["DateFieldComparison"] = Field(alias="endDate")
    environment_id: Optional["StringFieldComparison"] = Field(alias="environmentId")
    id: Optional["StringFieldComparison"]
    old_billing_id: Optional["StringFieldComparison"] = Field(alias="oldBillingId")
    or_: Optional[List["CustomerResourceFilterCustomerSubscriptionFilter"]] = Field(
        alias="or"
    )
    pricing_type: Optional["PricingTypeFilterComparison"] = Field(alias="pricingType")
    ref_id: Optional["StringFieldComparison"] = Field(alias="refId")
    resource_id: Optional["StringFieldComparison"] = Field(alias="resourceId")
    start_date: Optional["DateFieldComparison"] = Field(alias="startDate")
    status: Optional["SubscriptionStatusFilterComparison"]
    subscription_id: Optional["StringFieldComparison"] = Field(alias="subscriptionId")
    trial_end_date: Optional["DateFieldComparison"] = Field(alias="trialEndDate")


class CustomerResourceSort(BaseModel):
    direction: SortDirection
    field: CustomerResourceSortFields
    nulls: Optional[SortNulls]


class CustomerSort(BaseModel):
    direction: SortDirection
    field: CustomerSortFields
    nulls: Optional[SortNulls]


class CustomerSubscriptionFilter(BaseModel):
    addons: Optional["CustomerSubscriptionFilterSubscriptionAddonFilter"]
    and_: Optional[List["CustomerSubscriptionFilter"]] = Field(alias="and")
    billing_id: Optional["StringFieldComparison"] = Field(alias="billingId")
    cancel_reason: Optional["SubscriptionCancelReasonFilterComparison"] = Field(
        alias="cancelReason"
    )
    cancellation_date: Optional["DateFieldComparison"] = Field(alias="cancellationDate")
    created_at: Optional["DateFieldComparison"] = Field(alias="createdAt")
    crm_id: Optional["StringFieldComparison"] = Field(alias="crmId")
    crm_link_url: Optional["StringFieldComparison"] = Field(alias="crmLinkUrl")
    customer: Optional["CustomerSubscriptionFilterCustomerFilter"]
    effective_end_date: Optional["DateFieldComparison"] = Field(
        alias="effectiveEndDate"
    )
    end_date: Optional["DateFieldComparison"] = Field(alias="endDate")
    environment_id: Optional["StringFieldComparison"] = Field(alias="environmentId")
    id: Optional["StringFieldComparison"]
    old_billing_id: Optional["StringFieldComparison"] = Field(alias="oldBillingId")
    or_: Optional[List["CustomerSubscriptionFilter"]] = Field(alias="or")
    plan: Optional["CustomerSubscriptionFilterPlanFilter"]
    prices: Optional["CustomerSubscriptionFilterSubscriptionPriceFilter"]
    pricing_type: Optional["PricingTypeFilterComparison"] = Field(alias="pricingType")
    ref_id: Optional["StringFieldComparison"] = Field(alias="refId")
    resource: Optional["CustomerSubscriptionFilterCustomerResourceFilter"]
    resource_id: Optional["StringFieldComparison"] = Field(alias="resourceId")
    start_date: Optional["DateFieldComparison"] = Field(alias="startDate")
    status: Optional["SubscriptionStatusFilterComparison"]
    subscription_entitlements: Optional[
        "CustomerSubscriptionFilterSubscriptionEntitlementFilter"
    ] = Field(alias="subscriptionEntitlements")
    subscription_id: Optional["StringFieldComparison"] = Field(alias="subscriptionId")
    trial_end_date: Optional["DateFieldComparison"] = Field(alias="trialEndDate")


class CustomerSubscriptionFilterCustomerFilter(BaseModel):
    and_: Optional[List["CustomerSubscriptionFilterCustomerFilter"]] = Field(
        alias="and"
    )
    billing_id: Optional["StringFieldComparison"] = Field(alias="billingId")
    created_at: Optional["DateFieldComparison"] = Field(alias="createdAt")
    crm_hubspot_company_id: Optional["StringFieldComparison"] = Field(
        alias="crmHubspotCompanyId"
    )
    crm_hubspot_company_url: Optional["StringFieldComparison"] = Field(
        alias="crmHubspotCompanyUrl"
    )
    crm_id: Optional["StringFieldComparison"] = Field(alias="crmId")
    customer_id: Optional["StringFieldComparison"] = Field(alias="customerId")
    deleted_at: Optional["DateFieldComparison"] = Field(alias="deletedAt")
    email: Optional["StringFieldComparison"]
    environment_id: Optional["StringFieldComparison"] = Field(alias="environmentId")
    id: Optional["StringFieldComparison"]
    name: Optional["StringFieldComparison"]
    or_: Optional[List["CustomerSubscriptionFilterCustomerFilter"]] = Field(alias="or")
    ref_id: Optional["StringFieldComparison"] = Field(alias="refId")
    updated_at: Optional["DateFieldComparison"] = Field(alias="updatedAt")


class CustomerSubscriptionFilterCustomerResourceFilter(BaseModel):
    and_: Optional[List["CustomerSubscriptionFilterCustomerResourceFilter"]] = Field(
        alias="and"
    )
    created_at: Optional["DateFieldComparison"] = Field(alias="createdAt")
    environment_id: Optional["StringFieldComparison"] = Field(alias="environmentId")
    or_: Optional[List["CustomerSubscriptionFilterCustomerResourceFilter"]] = Field(
        alias="or"
    )
    resource_id: Optional["StringFieldComparison"] = Field(alias="resourceId")


class CustomerSubscriptionFilterPlanFilter(BaseModel):
    and_: Optional[List["CustomerSubscriptionFilterPlanFilter"]] = Field(alias="and")
    billing_id: Optional["StringFieldComparison"] = Field(alias="billingId")
    created_at: Optional["DateFieldComparison"] = Field(alias="createdAt")
    description: Optional["StringFieldComparison"]
    display_name: Optional["StringFieldComparison"] = Field(alias="displayName")
    environment_id: Optional["StringFieldComparison"] = Field(alias="environmentId")
    id: Optional["StringFieldComparison"]
    is_latest: Optional["BooleanFieldComparison"] = Field(alias="isLatest")
    or_: Optional[List["CustomerSubscriptionFilterPlanFilter"]] = Field(alias="or")
    pricing_type: Optional["PricingTypeFilterComparison"] = Field(alias="pricingType")
    product_id: Optional["StringFieldComparison"] = Field(alias="productId")
    ref_id: Optional["StringFieldComparison"] = Field(alias="refId")
    status: Optional["PackageStatusFilterComparison"]
    updated_at: Optional["DateFieldComparison"] = Field(alias="updatedAt")
    version_number: Optional["IntFieldComparison"] = Field(alias="versionNumber")


class CustomerSubscriptionFilterSubscriptionAddonFilter(BaseModel):
    and_: Optional[List["CustomerSubscriptionFilterSubscriptionAddonFilter"]] = Field(
        alias="and"
    )
    created_at: Optional["DateFieldComparison"] = Field(alias="createdAt")
    id: Optional["StringFieldComparison"]
    or_: Optional[List["CustomerSubscriptionFilterSubscriptionAddonFilter"]] = Field(
        alias="or"
    )
    quantity: Optional["NumberFieldComparison"]
    updated_at: Optional["DateFieldComparison"] = Field(alias="updatedAt")


class CustomerSubscriptionFilterSubscriptionEntitlementFilter(BaseModel):
    and_: Optional[
        List["CustomerSubscriptionFilterSubscriptionEntitlementFilter"]
    ] = Field(alias="and")
    created_at: Optional["DateFieldComparison"] = Field(alias="createdAt")
    environment_id: Optional["StringFieldComparison"] = Field(alias="environmentId")
    id: Optional["StringFieldComparison"]
    or_: Optional[
        List["CustomerSubscriptionFilterSubscriptionEntitlementFilter"]
    ] = Field(alias="or")
    subscription_id: Optional["StringFieldComparison"] = Field(alias="subscriptionId")
    updated_at: Optional["DateFieldComparison"] = Field(alias="updatedAt")


class CustomerSubscriptionFilterSubscriptionPriceFilter(BaseModel):
    and_: Optional[List["CustomerSubscriptionFilterSubscriptionPriceFilter"]] = Field(
        alias="and"
    )
    billing_model: Optional["BillingModelFilterComparison"] = Field(
        alias="billingModel"
    )
    created_at: Optional["DateFieldComparison"] = Field(alias="createdAt")
    feature_id: Optional["StringFieldComparison"] = Field(alias="featureId")
    id: Optional["StringFieldComparison"]
    or_: Optional[List["CustomerSubscriptionFilterSubscriptionPriceFilter"]] = Field(
        alias="or"
    )
    updated_at: Optional["DateFieldComparison"] = Field(alias="updatedAt")
    usage_limit: Optional["NumberFieldComparison"] = Field(alias="usageLimit")


class CustomerSubscriptionSort(BaseModel):
    direction: SortDirection
    field: CustomerSubscriptionSortFields
    nulls: Optional[SortNulls]


class DateFieldComparison(BaseModel):
    between: Optional["DateFieldComparisonBetween"]
    eq: Optional[Any]
    gt: Optional[Any]
    gte: Optional[Any]
    in_: Optional[List[Any]] = Field(alias="in")
    is_: Optional[bool] = Field(alias="is")
    is_not: Optional[bool] = Field(alias="isNot")
    lt: Optional[Any]
    lte: Optional[Any]
    neq: Optional[Any]
    not_between: Optional["DateFieldComparisonBetween"] = Field(alias="notBetween")
    not_in: Optional[List[Any]] = Field(alias="notIn")


class DateFieldComparisonBetween(BaseModel):
    lower: Any
    upper: Any


class DefaultTrialConfigInputDTO(BaseModel):
    duration: Optional[float]
    units: Optional[TrialPeriodUnits]


class DeleteFeatureInput(BaseModel):
    environment_id: Optional[str] = Field(alias="environmentId")
    id: str


class DeleteOneAddonInput(BaseModel):
    id: str


class DeleteOneEnvironmentInput(BaseModel):
    id: str


class DeleteOneHookInput(BaseModel):
    id: str


class DeleteOneIntegrationInput(BaseModel):
    id: str


class DeleteOnePackageEntitlementInput(BaseModel):
    id: str


class DeleteOnePriceInput(BaseModel):
    id: str


class DeleteOneProductInput(BaseModel):
    id: str


class DeleteOnePromotionalEntitlementInput(BaseModel):
    id: str


class DiscardPackageDraftInput(BaseModel):
    environment_id: str = Field(alias="environmentId")
    ref_id: str = Field(alias="refId")


class EntitlementCheckRequested(BaseModel):
    customer_id: str = Field(alias="customerId")
    entitlement_check_result: "EntitlementCheckResult" = Field(
        alias="entitlementCheckResult"
    )
    environment_id: Optional[str] = Field(alias="environmentId")
    feature_id: str = Field(alias="featureId")
    requested_usage: Optional[float] = Field(alias="requestedUsage")
    resource_id: Optional[str] = Field(alias="resourceId")


class EntitlementCheckResult(BaseModel):
    access_denied_reason: Optional[AccessDeniedReason] = Field(
        alias="accessDeniedReason"
    )
    current_usage: Optional[float] = Field(alias="currentUsage")
    has_access: bool = Field(alias="hasAccess")
    has_unlimited_usage: Optional[bool] = Field(
        alias="hasUnlimitedUsage", default=False
    )
    monthly_reset_period_configuration: Optional[
        "MonthlyResetPeriodConfigInput"
    ] = Field(alias="monthlyResetPeriodConfiguration")
    next_reset_date: Optional[Any] = Field(alias="nextResetDate")
    requested_usage: Optional[float] = Field(alias="requestedUsage")
    reset_period: Optional[EntitlementResetPeriod] = Field(alias="resetPeriod")
    usage_limit: Optional[float] = Field(alias="usageLimit")
    weekly_reset_period_configuration: Optional["WeeklyResetPeriodConfigInput"] = Field(
        alias="weeklyResetPeriodConfiguration"
    )


class EntitlementOptions(BaseModel):
    requested_usage: Optional[float] = Field(alias="requestedUsage")
    should_track: Optional[bool] = Field(alias="shouldTrack", default=False)


class EnvironmentFilter(BaseModel):
    and_: Optional[List["EnvironmentFilter"]] = Field(alias="and")
    created_at: Optional["DateFieldComparison"] = Field(alias="createdAt")
    display_name: Optional["StringFieldComparison"] = Field(alias="displayName")
    id: Optional["StringFieldComparison"]
    or_: Optional[List["EnvironmentFilter"]] = Field(alias="or")
    slug: Optional["StringFieldComparison"]


class EnvironmentInput(BaseModel):
    color: Optional[str]
    description: Optional[str]
    display_name: Optional[str] = Field(alias="displayName")
    harden_client_access_enabled: Optional[bool] = Field(
        alias="hardenClientAccessEnabled"
    )
    provision_status: Optional[EnvironmentProvisionStatus] = Field(
        alias="provisionStatus"
    )


class EnvironmentSort(BaseModel):
    direction: SortDirection
    field: EnvironmentSortFields
    nulls: Optional[SortNulls]


class EstimateSubscriptionInput(BaseModel):
    addons: Optional[List["SubscriptionAddonInput"]]
    billable_features: Optional[List["BillableFeatureInput"]] = Field(
        alias="billableFeatures"
    )
    billing_country_code: Optional[str] = Field(alias="billingCountryCode")
    billing_information: Optional["SubscriptionBillingInfo"] = Field(
        alias="billingInformation"
    )
    billing_period: Optional[BillingPeriod] = Field(alias="billingPeriod")
    customer_id: str = Field(alias="customerId")
    environment_id: Optional[str] = Field(alias="environmentId")
    plan_id: str = Field(alias="planId")
    price_unit_amount: Optional[float] = Field(alias="priceUnitAmount")
    promotion_code: Optional[str] = Field(alias="promotionCode")
    resource_id: Optional[str] = Field(alias="resourceId")
    skip_trial: Optional[bool] = Field(alias="skipTrial", default=False)
    start_date: Optional[Any] = Field(alias="startDate")
    unit_quantity: Optional[float] = Field(alias="unitQuantity", default=-1)


class EstimateSubscriptionUpdateInput(BaseModel):
    addons: Optional[List["SubscriptionAddonInput"]]
    billable_features: Optional[List["BillableFeatureInput"]] = Field(
        alias="billableFeatures"
    )
    environment_id: Optional[str] = Field(alias="environmentId")
    promotion_code: Optional[str] = Field(alias="promotionCode")
    subscription_id: str = Field(alias="subscriptionId")
    unit_quantity: Optional[float] = Field(alias="unitQuantity")


class EventsFieldsInput(BaseModel):
    environment_id: str = Field(alias="environmentId")
    filters: Optional[List["MeterFilterDefinitionInput"]]


class ExperimentFilter(BaseModel):
    and_: Optional[List["ExperimentFilter"]] = Field(alias="and")
    created_at: Optional["DateFieldComparison"] = Field(alias="createdAt")
    customers: Optional["ExperimentFilterCustomerFilter"]
    environment_id: Optional["StringFieldComparison"] = Field(alias="environmentId")
    id: Optional["StringFieldComparison"]
    name: Optional["StringFieldComparison"]
    or_: Optional[List["ExperimentFilter"]] = Field(alias="or")
    product_id: Optional["StringFieldComparison"] = Field(alias="productId")
    ref_id: Optional["StringFieldComparison"] = Field(alias="refId")
    status: Optional["ExperimentStatusFilterComparison"]


class ExperimentFilterCustomerFilter(BaseModel):
    and_: Optional[List["ExperimentFilterCustomerFilter"]] = Field(alias="and")
    billing_id: Optional["StringFieldComparison"] = Field(alias="billingId")
    created_at: Optional["DateFieldComparison"] = Field(alias="createdAt")
    crm_hubspot_company_id: Optional["StringFieldComparison"] = Field(
        alias="crmHubspotCompanyId"
    )
    crm_hubspot_company_url: Optional["StringFieldComparison"] = Field(
        alias="crmHubspotCompanyUrl"
    )
    crm_id: Optional["StringFieldComparison"] = Field(alias="crmId")
    customer_id: Optional["StringFieldComparison"] = Field(alias="customerId")
    deleted_at: Optional["DateFieldComparison"] = Field(alias="deletedAt")
    email: Optional["StringFieldComparison"]
    environment_id: Optional["StringFieldComparison"] = Field(alias="environmentId")
    id: Optional["StringFieldComparison"]
    name: Optional["StringFieldComparison"]
    or_: Optional[List["ExperimentFilterCustomerFilter"]] = Field(alias="or")
    ref_id: Optional["StringFieldComparison"] = Field(alias="refId")
    updated_at: Optional["DateFieldComparison"] = Field(alias="updatedAt")


class ExperimentSort(BaseModel):
    direction: SortDirection
    field: ExperimentSortFields
    nulls: Optional[SortNulls]


class ExperimentStatsQuery(BaseModel):
    environment_id: Optional[str] = Field(alias="environmentId")
    experiment_ref_id: str = Field(alias="experimentRefId")


class ExperimentStatusFilterComparison(BaseModel):
    eq: Optional[ExperimentStatus]
    gt: Optional[ExperimentStatus]
    gte: Optional[ExperimentStatus]
    i_like: Optional[ExperimentStatus] = Field(alias="iLike")
    in_: Optional[List[ExperimentStatus]] = Field(alias="in")
    is_: Optional[bool] = Field(alias="is")
    is_not: Optional[bool] = Field(alias="isNot")
    like: Optional[ExperimentStatus]
    lt: Optional[ExperimentStatus]
    lte: Optional[ExperimentStatus]
    neq: Optional[ExperimentStatus]
    not_i_like: Optional[ExperimentStatus] = Field(alias="notILike")
    not_in: Optional[List[ExperimentStatus]] = Field(alias="notIn")
    not_like: Optional[ExperimentStatus] = Field(alias="notLike")


class FeatureFilter(BaseModel):
    and_: Optional[List["FeatureFilter"]] = Field(alias="and")
    created_at: Optional["DateFieldComparison"] = Field(alias="createdAt")
    description: Optional["StringFieldComparison"]
    display_name: Optional["StringFieldComparison"] = Field(alias="displayName")
    environment_id: Optional["StringFieldComparison"] = Field(alias="environmentId")
    feature_status: Optional["FeatureStatusFilterComparison"] = Field(
        alias="featureStatus"
    )
    feature_type: Optional["FeatureTypeFilterComparison"] = Field(alias="featureType")
    id: Optional["StringFieldComparison"]
    meter_type: Optional["MeterTypeFilterComparison"] = Field(alias="meterType")
    or_: Optional[List["FeatureFilter"]] = Field(alias="or")
    ref_id: Optional["StringFieldComparison"] = Field(alias="refId")
    updated_at: Optional["DateFieldComparison"] = Field(alias="updatedAt")


class FeatureInput(BaseModel):
    additional_meta_data: Optional[Any] = Field(alias="additionalMetaData")
    description: Optional[str]
    display_name: str = Field(alias="displayName")
    environment_id: str = Field(alias="environmentId")
    feature_status: Optional[FeatureStatus] = Field(alias="featureStatus")
    feature_type: FeatureType = Field(alias="featureType")
    feature_units: Optional[str] = Field(alias="featureUnits")
    feature_units_plural: Optional[str] = Field(alias="featureUnitsPlural")
    meter: Optional["CreateMeter"]
    meter_type: Optional[MeterType] = Field(alias="meterType")
    ref_id: str = Field(alias="refId")


class FeatureSort(BaseModel):
    direction: SortDirection
    field: FeatureSortFields
    nulls: Optional[SortNulls]


class FeatureStatusFilterComparison(BaseModel):
    eq: Optional[FeatureStatus]
    gt: Optional[FeatureStatus]
    gte: Optional[FeatureStatus]
    i_like: Optional[FeatureStatus] = Field(alias="iLike")
    in_: Optional[List[FeatureStatus]] = Field(alias="in")
    is_: Optional[bool] = Field(alias="is")
    is_not: Optional[bool] = Field(alias="isNot")
    like: Optional[FeatureStatus]
    lt: Optional[FeatureStatus]
    lte: Optional[FeatureStatus]
    neq: Optional[FeatureStatus]
    not_i_like: Optional[FeatureStatus] = Field(alias="notILike")
    not_in: Optional[List[FeatureStatus]] = Field(alias="notIn")
    not_like: Optional[FeatureStatus] = Field(alias="notLike")


class FeatureTypeFilterComparison(BaseModel):
    eq: Optional[FeatureType]
    gt: Optional[FeatureType]
    gte: Optional[FeatureType]
    i_like: Optional[FeatureType] = Field(alias="iLike")
    in_: Optional[List[FeatureType]] = Field(alias="in")
    is_: Optional[bool] = Field(alias="is")
    is_not: Optional[bool] = Field(alias="isNot")
    like: Optional[FeatureType]
    lt: Optional[FeatureType]
    lte: Optional[FeatureType]
    neq: Optional[FeatureType]
    not_i_like: Optional[FeatureType] = Field(alias="notILike")
    not_in: Optional[List[FeatureType]] = Field(alias="notIn")
    not_like: Optional[FeatureType] = Field(alias="notLike")


class FetchEntitlementQuery(BaseModel):
    customer_id: str = Field(alias="customerId")
    environment_id: Optional[str] = Field(alias="environmentId")
    feature_id: str = Field(alias="featureId")
    options: Optional["EntitlementOptions"]
    resource_id: Optional[str] = Field(alias="resourceId")


class FetchEntitlementsQuery(BaseModel):
    customer_id: str = Field(alias="customerId")
    environment_id: Optional[str] = Field(alias="environmentId")
    resource_id: Optional[str] = Field(alias="resourceId")


class FontVariantInput(BaseModel):
    font_size: Optional[float] = Field(alias="fontSize")
    font_weight: Optional[FontWeight] = Field(alias="fontWeight")


class GetActiveSubscriptionsInput(BaseModel):
    customer_id: str = Field(alias="customerId")
    environment_id: Optional[str] = Field(alias="environmentId")
    resource_id: Optional[str] = Field(alias="resourceId")
    resource_ids: Optional[List[str]] = Field(alias="resourceIds")


class GetCustomerByRefIdInput(BaseModel):
    customer_id: str = Field(alias="customerId")
    environment_id: Optional[str] = Field(alias="environmentId")


class GetPackageByRefIdInput(BaseModel):
    environment_id: str = Field(alias="environmentId")
    ref_id: str = Field(alias="refId")
    version_number: Optional[float] = Field(alias="versionNumber")


class GetPaywallInput(BaseModel):
    billing_country_code: Optional[str] = Field(alias="billingCountryCode")
    context: Optional[WidgetType]
    customer_id: Optional[str] = Field(alias="customerId")
    environment_id: Optional[str] = Field(alias="environmentId")
    fetch_all_countries_prices: Optional[bool] = Field(
        alias="fetchAllCountriesPrices", default=False
    )
    product_id: Optional[str] = Field(alias="productId")
    resource_id: Optional[str] = Field(alias="resourceId")


class GetWidgetConfigurationInput(BaseModel):
    environment_id: Optional[str] = Field(alias="environmentId")


class HookFilter(BaseModel):
    and_: Optional[List["HookFilter"]] = Field(alias="and")
    created_at: Optional["DateFieldComparison"] = Field(alias="createdAt")
    endpoint: Optional["StringFieldComparison"]
    environment_id: Optional["StringFieldComparison"] = Field(alias="environmentId")
    id: Optional["StringFieldComparison"]
    or_: Optional[List["HookFilter"]] = Field(alias="or")
    status: Optional["HookStatusFilterComparison"]


class HookSort(BaseModel):
    direction: SortDirection
    field: HookSortFields
    nulls: Optional[SortNulls]


class HookStatusFilterComparison(BaseModel):
    eq: Optional[HookStatus]
    gt: Optional[HookStatus]
    gte: Optional[HookStatus]
    i_like: Optional[HookStatus] = Field(alias="iLike")
    in_: Optional[List[HookStatus]] = Field(alias="in")
    is_: Optional[bool] = Field(alias="is")
    is_not: Optional[bool] = Field(alias="isNot")
    like: Optional[HookStatus]
    lt: Optional[HookStatus]
    lte: Optional[HookStatus]
    neq: Optional[HookStatus]
    not_i_like: Optional[HookStatus] = Field(alias="notILike")
    not_in: Optional[List[HookStatus]] = Field(alias="notIn")
    not_like: Optional[HookStatus] = Field(alias="notLike")


class HubspotCredentialsInput(BaseModel):
    authorization_code: str = Field(alias="authorizationCode")
    refresh_token: Optional[str] = Field(alias="refreshToken")


class ImportCustomerBulk(BaseModel):
    customers: List["ImportCustomerInput"]
    environment_id: Optional[str] = Field(alias="environmentId")


class ImportCustomerInput(BaseModel):
    additional_meta_data: Optional[Any] = Field(alias="additionalMetaData")
    billing_id: Optional[str] = Field(alias="billingId")
    customer_id: Optional[str] = Field(alias="customerId")
    email: Optional[str]
    environment_id: Optional[str] = Field(alias="environmentId")
    name: Optional[str]
    payment_method_id: Optional[str] = Field(alias="paymentMethodId")
    ref_id: Optional[str] = Field(alias="refId")


class ImportIntegrationCatalogInput(BaseModel):
    billing_model: Optional[BillingModel] = Field(alias="billingModel")
    entity_selection_mode: EntitySelectionMode = Field(alias="entitySelectionMode")
    environment_id: str = Field(alias="environmentId")
    feature_unit_name: Optional[str] = Field(alias="featureUnitName")
    feature_unit_plural_name: Optional[str] = Field(alias="featureUnitPluralName")
    plans_selection_blacklist: Optional[List[str]] = Field(
        alias="plansSelectionBlacklist"
    )
    plans_selection_whitelist: Optional[List[str]] = Field(
        alias="plansSelectionWhitelist"
    )
    product_id: str = Field(alias="productId")
    selected_addon_billing_ids: List[str] = Field(alias="selectedAddonBillingIds")
    vendor_identifier: VendorIdentifier = Field(alias="vendorIdentifier")


class ImportIntegrationCustomersInput(BaseModel):
    customers_selection_blacklist: Optional[List[str]] = Field(
        alias="customersSelectionBlacklist"
    )
    customers_selection_whitelist: Optional[List[str]] = Field(
        alias="customersSelectionWhitelist"
    )
    entity_selection_mode: EntitySelectionMode = Field(alias="entitySelectionMode")
    environment_id: str = Field(alias="environmentId")
    product_id: str = Field(alias="productId")
    vendor_identifier: VendorIdentifier = Field(alias="vendorIdentifier")


class ImportIntegrationTaskFilter(BaseModel):
    and_: Optional[List["ImportIntegrationTaskFilter"]] = Field(alias="and")
    created_at: Optional["DateFieldComparison"] = Field(alias="createdAt")
    environment_id: Optional["StringFieldComparison"] = Field(alias="environmentId")
    id: Optional["StringFieldComparison"]
    or_: Optional[List["ImportIntegrationTaskFilter"]] = Field(alias="or")
    status: Optional["TaskStatusFilterComparison"]
    task_type: Optional["TaskTypeFilterComparison"] = Field(alias="taskType")


class ImportIntegrationTaskSort(BaseModel):
    direction: SortDirection
    field: ImportIntegrationTaskSortFields
    nulls: Optional[SortNulls]


class ImportSubscriptionInput(BaseModel):
    additional_meta_data: Optional[Any] = Field(alias="additionalMetaData")
    billing_id: Optional[str] = Field(alias="billingId")
    billing_period: Optional[BillingPeriod] = Field(alias="billingPeriod")
    customer_id: str = Field(alias="customerId")
    plan_id: str = Field(alias="planId")
    resource_id: Optional[str] = Field(alias="resourceId")
    start_date: Optional[Any] = Field(alias="startDate")
    unit_quantity: Optional[float] = Field(alias="unitQuantity")


class ImportSubscriptionsBulk(BaseModel):
    environment_id: Optional[str] = Field(alias="environmentId")
    subscriptions: List["ImportSubscriptionInput"]


class InitAddStripeCustomerPaymentMethodInput(BaseModel):
    customer_ref_id: str = Field(alias="customerRefId")
    environment_id: Optional[str] = Field(alias="environmentId")


class IntFieldComparison(BaseModel):
    between: Optional["IntFieldComparisonBetween"]
    eq: Optional[int]
    gt: Optional[int]
    gte: Optional[int]
    in_: Optional[List[int]] = Field(alias="in")
    is_: Optional[bool] = Field(alias="is")
    is_not: Optional[bool] = Field(alias="isNot")
    lt: Optional[int]
    lte: Optional[int]
    neq: Optional[int]
    not_between: Optional["IntFieldComparisonBetween"] = Field(alias="notBetween")
    not_in: Optional[List[int]] = Field(alias="notIn")


class IntFieldComparisonBetween(BaseModel):
    lower: int
    upper: int


class IntegrationFilter(BaseModel):
    and_: Optional[List["IntegrationFilter"]] = Field(alias="and")
    created_at: Optional["DateFieldComparison"] = Field(alias="createdAt")
    environment_id: Optional["StringFieldComparison"] = Field(alias="environmentId")
    id: Optional["StringFieldComparison"]
    or_: Optional[List["IntegrationFilter"]] = Field(alias="or")
    vendor_identifier: Optional["VendorIdentifierFilterComparison"] = Field(
        alias="vendorIdentifier"
    )


class IntegrationSort(BaseModel):
    direction: SortDirection
    field: IntegrationSortFields
    nulls: Optional[SortNulls]


class MemberFilter(BaseModel):
    and_: Optional[List["MemberFilter"]] = Field(alias="and")
    created_at: Optional["DateFieldComparison"] = Field(alias="createdAt")
    id: Optional["StringFieldComparison"]
    or_: Optional[List["MemberFilter"]] = Field(alias="or")


class MemberSort(BaseModel):
    direction: SortDirection
    field: MemberSortFields
    nulls: Optional[SortNulls]


class MeterAggregation(BaseModel):
    field: Optional[str]
    function: AggregationFunction


class MeterConditionInput(BaseModel):
    field: str
    operation: ConditionOperation
    value: Optional[str]


class MeterFilterDefinitionInput(BaseModel):
    conditions: List["MeterConditionInput"]


class MeterTypeFilterComparison(BaseModel):
    eq: Optional[MeterType]
    gt: Optional[MeterType]
    gte: Optional[MeterType]
    i_like: Optional[MeterType] = Field(alias="iLike")
    in_: Optional[List[MeterType]] = Field(alias="in")
    is_: Optional[bool] = Field(alias="is")
    is_not: Optional[bool] = Field(alias="isNot")
    like: Optional[MeterType]
    lt: Optional[MeterType]
    lte: Optional[MeterType]
    neq: Optional[MeterType]
    not_i_like: Optional[MeterType] = Field(alias="notILike")
    not_in: Optional[List[MeterType]] = Field(alias="notIn")
    not_like: Optional[MeterType] = Field(alias="notLike")


class MoneyInputDTO(BaseModel):
    amount: float
    currency: Optional[Currency]


class MonthlyResetPeriodConfigInput(BaseModel):
    according_to: MonthlyAccordingTo = Field(alias="accordingTo")


class NumberFieldComparison(BaseModel):
    between: Optional["NumberFieldComparisonBetween"]
    eq: Optional[float]
    gt: Optional[float]
    gte: Optional[float]
    in_: Optional[List[float]] = Field(alias="in")
    is_: Optional[bool] = Field(alias="is")
    is_not: Optional[bool] = Field(alias="isNot")
    lt: Optional[float]
    lte: Optional[float]
    neq: Optional[float]
    not_between: Optional["NumberFieldComparisonBetween"] = Field(alias="notBetween")
    not_in: Optional[List[float]] = Field(alias="notIn")


class NumberFieldComparisonBetween(BaseModel):
    lower: float
    upper: float


class PackageDTOFilter(BaseModel):
    and_: Optional[List["PackageDTOFilter"]] = Field(alias="and")
    billing_id: Optional["StringFieldComparison"] = Field(alias="billingId")
    created_at: Optional["DateFieldComparison"] = Field(alias="createdAt")
    description: Optional["StringFieldComparison"]
    display_name: Optional["StringFieldComparison"] = Field(alias="displayName")
    environment_id: Optional["StringFieldComparison"] = Field(alias="environmentId")
    id: Optional["StringFieldComparison"]
    is_latest: Optional["BooleanFieldComparison"] = Field(alias="isLatest")
    or_: Optional[List["PackageDTOFilter"]] = Field(alias="or")
    pricing_type: Optional["PricingTypeFilterComparison"] = Field(alias="pricingType")
    product_id: Optional["StringFieldComparison"] = Field(alias="productId")
    ref_id: Optional["StringFieldComparison"] = Field(alias="refId")
    status: Optional["PackageStatusFilterComparison"]
    updated_at: Optional["DateFieldComparison"] = Field(alias="updatedAt")
    version_number: Optional["IntFieldComparison"] = Field(alias="versionNumber")


class PackageDTOSort(BaseModel):
    direction: SortDirection
    field: PackageDTOSortFields
    nulls: Optional[SortNulls]


class PackageEntitlementFilter(BaseModel):
    and_: Optional[List["PackageEntitlementFilter"]] = Field(alias="and")
    created_at: Optional["DateFieldComparison"] = Field(alias="createdAt")
    environment_id: Optional["StringFieldComparison"] = Field(alias="environmentId")
    feature: Optional["PackageEntitlementFilterFeatureFilter"]
    id: Optional["StringFieldComparison"]
    or_: Optional[List["PackageEntitlementFilter"]] = Field(alias="or")
    package: Optional["PackageEntitlementFilterPackageDTOFilter"]
    package_id: Optional["StringFieldComparison"] = Field(alias="packageId")
    updated_at: Optional["DateFieldComparison"] = Field(alias="updatedAt")


class PackageEntitlementFilterFeatureFilter(BaseModel):
    and_: Optional[List["PackageEntitlementFilterFeatureFilter"]] = Field(alias="and")
    created_at: Optional["DateFieldComparison"] = Field(alias="createdAt")
    description: Optional["StringFieldComparison"]
    display_name: Optional["StringFieldComparison"] = Field(alias="displayName")
    environment_id: Optional["StringFieldComparison"] = Field(alias="environmentId")
    feature_status: Optional["FeatureStatusFilterComparison"] = Field(
        alias="featureStatus"
    )
    feature_type: Optional["FeatureTypeFilterComparison"] = Field(alias="featureType")
    id: Optional["StringFieldComparison"]
    meter_type: Optional["MeterTypeFilterComparison"] = Field(alias="meterType")
    or_: Optional[List["PackageEntitlementFilterFeatureFilter"]] = Field(alias="or")
    ref_id: Optional["StringFieldComparison"] = Field(alias="refId")
    updated_at: Optional["DateFieldComparison"] = Field(alias="updatedAt")


class PackageEntitlementFilterPackageDTOFilter(BaseModel):
    and_: Optional[List["PackageEntitlementFilterPackageDTOFilter"]] = Field(
        alias="and"
    )
    billing_id: Optional["StringFieldComparison"] = Field(alias="billingId")
    created_at: Optional["DateFieldComparison"] = Field(alias="createdAt")
    description: Optional["StringFieldComparison"]
    display_name: Optional["StringFieldComparison"] = Field(alias="displayName")
    environment_id: Optional["StringFieldComparison"] = Field(alias="environmentId")
    id: Optional["StringFieldComparison"]
    is_latest: Optional["BooleanFieldComparison"] = Field(alias="isLatest")
    or_: Optional[List["PackageEntitlementFilterPackageDTOFilter"]] = Field(alias="or")
    pricing_type: Optional["PricingTypeFilterComparison"] = Field(alias="pricingType")
    product_id: Optional["StringFieldComparison"] = Field(alias="productId")
    ref_id: Optional["StringFieldComparison"] = Field(alias="refId")
    status: Optional["PackageStatusFilterComparison"]
    updated_at: Optional["DateFieldComparison"] = Field(alias="updatedAt")
    version_number: Optional["IntFieldComparison"] = Field(alias="versionNumber")


class PackageEntitlementInput(BaseModel):
    description: Optional[str]
    display_name_override: Optional[str] = Field(alias="displayNameOverride")
    environment_id: str = Field(alias="environmentId")
    feature_id: str = Field(alias="featureId")
    has_unlimited_usage: Optional[bool] = Field(alias="hasUnlimitedUsage")
    hidden_from_widgets: Optional[List[WidgetType]] = Field(alias="hiddenFromWidgets")
    is_custom: Optional[bool] = Field(alias="isCustom")
    monthly_reset_period_configuration: Optional[
        "MonthlyResetPeriodConfigInput"
    ] = Field(alias="monthlyResetPeriodConfiguration")
    order: Optional[float]
    package_id: str = Field(alias="packageId")
    reset_period: Optional[EntitlementResetPeriod] = Field(alias="resetPeriod")
    usage_limit: Optional[float] = Field(alias="usageLimit")
    weekly_reset_period_configuration: Optional["WeeklyResetPeriodConfigInput"] = Field(
        alias="weeklyResetPeriodConfiguration"
    )


class PackageEntitlementSort(BaseModel):
    direction: SortDirection
    field: PackageEntitlementSortFields
    nulls: Optional[SortNulls]


class PackageEntitlementUpdateInput(BaseModel):
    description: Optional[str]
    display_name_override: Optional[str] = Field(alias="displayNameOverride")
    has_unlimited_usage: Optional[bool] = Field(alias="hasUnlimitedUsage")
    hidden_from_widgets: Optional[List[WidgetType]] = Field(alias="hiddenFromWidgets")
    is_custom: Optional[bool] = Field(alias="isCustom")
    monthly_reset_period_configuration: Optional[
        "MonthlyResetPeriodConfigInput"
    ] = Field(alias="monthlyResetPeriodConfiguration")
    order: Optional[float]
    reset_period: Optional[EntitlementResetPeriod] = Field(alias="resetPeriod")
    usage_limit: Optional[float] = Field(alias="usageLimit")
    weekly_reset_period_configuration: Optional["WeeklyResetPeriodConfigInput"] = Field(
        alias="weeklyResetPeriodConfiguration"
    )


class PackagePricingInput(BaseModel):
    environment_id: str = Field(alias="environmentId")
    package_id: str = Field(alias="packageId")
    pricing_model: Optional["PricingModelCreateInput"] = Field(alias="pricingModel")
    pricing_models: Optional[List["PricingModelCreateInput"]] = Field(
        alias="pricingModels"
    )
    pricing_type: PricingType = Field(alias="pricingType")


class PackagePublishInput(BaseModel):
    id: str
    migration_type: PublishMigrationType = Field(alias="migrationType")


class PackageStatusFilterComparison(BaseModel):
    eq: Optional[PackageStatus]
    gt: Optional[PackageStatus]
    gte: Optional[PackageStatus]
    i_like: Optional[PackageStatus] = Field(alias="iLike")
    in_: Optional[List[PackageStatus]] = Field(alias="in")
    is_: Optional[bool] = Field(alias="is")
    is_not: Optional[bool] = Field(alias="isNot")
    like: Optional[PackageStatus]
    lt: Optional[PackageStatus]
    lte: Optional[PackageStatus]
    neq: Optional[PackageStatus]
    not_i_like: Optional[PackageStatus] = Field(alias="notILike")
    not_in: Optional[List[PackageStatus]] = Field(alias="notIn")
    not_like: Optional[PackageStatus] = Field(alias="notLike")


class PaywallColorsPaletteInput(BaseModel):
    background_color: Optional[str] = Field(alias="backgroundColor")
    border_color: Optional[str] = Field(alias="borderColor")
    current_plan_background: Optional[str] = Field(alias="currentPlanBackground")
    primary: Optional[str]
    text_color: Optional[str] = Field(alias="textColor")


class PaywallConfigurationInput(BaseModel):
    custom_css: Optional[str] = Field(alias="customCss")
    layout: Optional["PaywallLayoutConfigurationInput"]
    palette: Optional["PaywallColorsPaletteInput"]
    typography: Optional["TypographyConfigurationInput"]


class PaywallLayoutConfigurationInput(BaseModel):
    alignment: Optional[Alignment]
    plan_margin: Optional[float] = Field(alias="planMargin")
    plan_padding: Optional[float] = Field(alias="planPadding")
    plan_width: Optional[float] = Field(alias="planWidth")


class PlanCreateInput(BaseModel):
    additional_meta_data: Optional[Any] = Field(alias="additionalMetaData")
    billing_id: Optional[str] = Field(alias="billingId")
    description: Optional[str]
    display_name: str = Field(alias="displayName")
    environment_id: Optional[str] = Field(alias="environmentId")
    hidden_from_widgets: Optional[List[WidgetType]] = Field(alias="hiddenFromWidgets")
    parent_plan_id: Optional[str] = Field(alias="parentPlanId")
    product_id: str = Field(alias="productId")
    ref_id: Optional[str] = Field(alias="refId")
    status: Optional[PackageStatus]


class PlanFilter(BaseModel):
    and_: Optional[List["PlanFilter"]] = Field(alias="and")
    billing_id: Optional["StringFieldComparison"] = Field(alias="billingId")
    compatible_addons: Optional["PlanFilterAddonFilter"] = Field(
        alias="compatibleAddons"
    )
    created_at: Optional["DateFieldComparison"] = Field(alias="createdAt")
    description: Optional["StringFieldComparison"]
    display_name: Optional["StringFieldComparison"] = Field(alias="displayName")
    environment_id: Optional["StringFieldComparison"] = Field(alias="environmentId")
    id: Optional["StringFieldComparison"]
    is_latest: Optional["BooleanFieldComparison"] = Field(alias="isLatest")
    or_: Optional[List["PlanFilter"]] = Field(alias="or")
    pricing_type: Optional["PricingTypeFilterComparison"] = Field(alias="pricingType")
    product: Optional["PlanFilterProductFilter"]
    product_id: Optional["StringFieldComparison"] = Field(alias="productId")
    ref_id: Optional["StringFieldComparison"] = Field(alias="refId")
    status: Optional["PackageStatusFilterComparison"]
    updated_at: Optional["DateFieldComparison"] = Field(alias="updatedAt")
    version_number: Optional["IntFieldComparison"] = Field(alias="versionNumber")


class PlanFilterAddonFilter(BaseModel):
    and_: Optional[List["PlanFilterAddonFilter"]] = Field(alias="and")
    billing_id: Optional["StringFieldComparison"] = Field(alias="billingId")
    created_at: Optional["DateFieldComparison"] = Field(alias="createdAt")
    description: Optional["StringFieldComparison"]
    display_name: Optional["StringFieldComparison"] = Field(alias="displayName")
    environment_id: Optional["StringFieldComparison"] = Field(alias="environmentId")
    id: Optional["StringFieldComparison"]
    is_latest: Optional["BooleanFieldComparison"] = Field(alias="isLatest")
    or_: Optional[List["PlanFilterAddonFilter"]] = Field(alias="or")
    pricing_type: Optional["PricingTypeFilterComparison"] = Field(alias="pricingType")
    product_id: Optional["StringFieldComparison"] = Field(alias="productId")
    ref_id: Optional["StringFieldComparison"] = Field(alias="refId")
    status: Optional["PackageStatusFilterComparison"]
    updated_at: Optional["DateFieldComparison"] = Field(alias="updatedAt")
    version_number: Optional["IntFieldComparison"] = Field(alias="versionNumber")


class PlanFilterProductFilter(BaseModel):
    and_: Optional[List["PlanFilterProductFilter"]] = Field(alias="and")
    created_at: Optional["DateFieldComparison"] = Field(alias="createdAt")
    description: Optional["StringFieldComparison"]
    display_name: Optional["StringFieldComparison"] = Field(alias="displayName")
    environment_id: Optional["StringFieldComparison"] = Field(alias="environmentId")
    id: Optional["StringFieldComparison"]
    is_default_product: Optional["BooleanFieldComparison"] = Field(
        alias="isDefaultProduct"
    )
    or_: Optional[List["PlanFilterProductFilter"]] = Field(alias="or")
    ref_id: Optional["StringFieldComparison"] = Field(alias="refId")
    updated_at: Optional["DateFieldComparison"] = Field(alias="updatedAt")


class PlanSort(BaseModel):
    direction: SortDirection
    field: PlanSortFields
    nulls: Optional[SortNulls]


class PlanUpdateInput(BaseModel):
    additional_meta_data: Optional[Any] = Field(alias="additionalMetaData")
    billing_id: Optional[str] = Field(alias="billingId")
    default_trial_config: Optional["DefaultTrialConfigInputDTO"] = Field(
        alias="defaultTrialConfig"
    )
    description: Optional[str]
    display_name: Optional[str] = Field(alias="displayName")
    hidden_from_widgets: Optional[List[WidgetType]] = Field(alias="hiddenFromWidgets")
    id: str
    parent_plan_id: Optional[str] = Field(alias="parentPlanId")
    status: Optional[PackageStatus]


class PriceFilter(BaseModel):
    and_: Optional[List["PriceFilter"]] = Field(alias="and")
    billing_id: Optional["StringFieldComparison"] = Field(alias="billingId")
    billing_model: Optional["BillingModelFilterComparison"] = Field(
        alias="billingModel"
    )
    billing_period: Optional["BillingPeriodFilterComparison"] = Field(
        alias="billingPeriod"
    )
    created_at: Optional["DateFieldComparison"] = Field(alias="createdAt")
    id: Optional["StringFieldComparison"]
    or_: Optional[List["PriceFilter"]] = Field(alias="or")
    package: Optional["PriceFilterPackageDTOFilter"]


class PriceFilterPackageDTOFilter(BaseModel):
    and_: Optional[List["PriceFilterPackageDTOFilter"]] = Field(alias="and")
    billing_id: Optional["StringFieldComparison"] = Field(alias="billingId")
    created_at: Optional["DateFieldComparison"] = Field(alias="createdAt")
    description: Optional["StringFieldComparison"]
    display_name: Optional["StringFieldComparison"] = Field(alias="displayName")
    environment_id: Optional["StringFieldComparison"] = Field(alias="environmentId")
    id: Optional["StringFieldComparison"]
    is_latest: Optional["BooleanFieldComparison"] = Field(alias="isLatest")
    or_: Optional[List["PriceFilterPackageDTOFilter"]] = Field(alias="or")
    pricing_type: Optional["PricingTypeFilterComparison"] = Field(alias="pricingType")
    product_id: Optional["StringFieldComparison"] = Field(alias="productId")
    ref_id: Optional["StringFieldComparison"] = Field(alias="refId")
    status: Optional["PackageStatusFilterComparison"]
    updated_at: Optional["DateFieldComparison"] = Field(alias="updatedAt")
    version_number: Optional["IntFieldComparison"] = Field(alias="versionNumber")


class PricePeriodInput(BaseModel):
    billing_country_code: Optional[str] = Field(alias="billingCountryCode")
    billing_period: BillingPeriod = Field(alias="billingPeriod")
    price: "MoneyInputDTO"


class PriceSort(BaseModel):
    direction: SortDirection
    field: PriceSortFields
    nulls: Optional[SortNulls]


class PricingModelCreateInput(BaseModel):
    billing_model: BillingModel = Field(alias="billingModel")
    feature_id: Optional[str] = Field(alias="featureId")
    max_unit_quantity: Optional[float] = Field(alias="maxUnitQuantity")
    min_unit_quantity: Optional[float] = Field(alias="minUnitQuantity")
    price_periods: List["PricePeriodInput"] = Field(alias="pricePeriods")


class PricingTypeFilterComparison(BaseModel):
    eq: Optional[PricingType]
    gt: Optional[PricingType]
    gte: Optional[PricingType]
    i_like: Optional[PricingType] = Field(alias="iLike")
    in_: Optional[List[PricingType]] = Field(alias="in")
    is_: Optional[bool] = Field(alias="is")
    is_not: Optional[bool] = Field(alias="isNot")
    like: Optional[PricingType]
    lt: Optional[PricingType]
    lte: Optional[PricingType]
    neq: Optional[PricingType]
    not_i_like: Optional[PricingType] = Field(alias="notILike")
    not_in: Optional[List[PricingType]] = Field(alias="notIn")
    not_like: Optional[PricingType] = Field(alias="notLike")


class ProductCreateInput(BaseModel):
    additional_meta_data: Optional[Any] = Field(alias="additionalMetaData")
    description: Optional[str]
    display_name: Optional[str] = Field(alias="displayName")
    environment_id: str = Field(alias="environmentId")
    multiple_subscriptions: Optional[bool] = Field(
        alias="multipleSubscriptions", default=False
    )
    ref_id: str = Field(alias="refId")


class ProductFilter(BaseModel):
    and_: Optional[List["ProductFilter"]] = Field(alias="and")
    created_at: Optional["DateFieldComparison"] = Field(alias="createdAt")
    description: Optional["StringFieldComparison"]
    display_name: Optional["StringFieldComparison"] = Field(alias="displayName")
    environment_id: Optional["StringFieldComparison"] = Field(alias="environmentId")
    id: Optional["StringFieldComparison"]
    is_default_product: Optional["BooleanFieldComparison"] = Field(
        alias="isDefaultProduct"
    )
    or_: Optional[List["ProductFilter"]] = Field(alias="or")
    ref_id: Optional["StringFieldComparison"] = Field(alias="refId")
    updated_at: Optional["DateFieldComparison"] = Field(alias="updatedAt")


class ProductSettingsInput(BaseModel):
    downgrade_at_end_of_billing_period: Optional[str] = Field(
        alias="downgradeAtEndOfBillingPeriod"
    )
    downgrade_plan_id: Optional[str] = Field(alias="downgradePlanId")
    subscription_cancellation_time: SubscriptionCancellationTime = Field(
        alias="subscriptionCancellationTime"
    )
    subscription_end_setup: SubscriptionEndSetup = Field(alias="subscriptionEndSetup")
    subscription_start_plan_id: Optional[str] = Field(alias="subscriptionStartPlanId")
    subscription_start_setup: SubscriptionStartSetup = Field(
        alias="subscriptionStartSetup"
    )


class ProductSort(BaseModel):
    direction: SortDirection
    field: ProductSortFields
    nulls: Optional[SortNulls]


class ProductUpdateInput(BaseModel):
    additional_meta_data: Optional[Any] = Field(alias="additionalMetaData")
    description: Optional[str]
    display_name: Optional[str] = Field(alias="displayName")
    multiple_subscriptions: Optional[bool] = Field(alias="multipleSubscriptions")
    product_settings: Optional["ProductSettingsInput"] = Field(alias="productSettings")


class PromotionalEntitlementFilter(BaseModel):
    and_: Optional[List["PromotionalEntitlementFilter"]] = Field(alias="and")
    created_at: Optional["DateFieldComparison"] = Field(alias="createdAt")
    environment_id: Optional["StringFieldComparison"] = Field(alias="environmentId")
    id: Optional["StringFieldComparison"]
    or_: Optional[List["PromotionalEntitlementFilter"]] = Field(alias="or")
    status: Optional["PromotionalEntitlementStatusFilterComparison"]
    updated_at: Optional["DateFieldComparison"] = Field(alias="updatedAt")


class PromotionalEntitlementInput(BaseModel):
    customer_id: str = Field(alias="customerId")
    description: Optional[str]
    end_date: Optional[Any] = Field(alias="endDate")
    environment_id: str = Field(alias="environmentId")
    feature_id: str = Field(alias="featureId")
    has_unlimited_usage: Optional[bool] = Field(alias="hasUnlimitedUsage")
    is_visible: bool = Field(alias="isVisible")
    monthly_reset_period_configuration: Optional[
        "MonthlyResetPeriodConfigInput"
    ] = Field(alias="monthlyResetPeriodConfiguration")
    period: PromotionalEntitlementPeriod
    reset_period: Optional[EntitlementResetPeriod] = Field(alias="resetPeriod")
    usage_limit: Optional[float] = Field(alias="usageLimit")
    weekly_reset_period_configuration: Optional["WeeklyResetPeriodConfigInput"] = Field(
        alias="weeklyResetPeriodConfiguration"
    )


class PromotionalEntitlementSort(BaseModel):
    direction: SortDirection
    field: PromotionalEntitlementSortFields
    nulls: Optional[SortNulls]


class PromotionalEntitlementStatusFilterComparison(BaseModel):
    eq: Optional[PromotionalEntitlementStatus]
    gt: Optional[PromotionalEntitlementStatus]
    gte: Optional[PromotionalEntitlementStatus]
    i_like: Optional[PromotionalEntitlementStatus] = Field(alias="iLike")
    in_: Optional[List[PromotionalEntitlementStatus]] = Field(alias="in")
    is_: Optional[bool] = Field(alias="is")
    is_not: Optional[bool] = Field(alias="isNot")
    like: Optional[PromotionalEntitlementStatus]
    lt: Optional[PromotionalEntitlementStatus]
    lte: Optional[PromotionalEntitlementStatus]
    neq: Optional[PromotionalEntitlementStatus]
    not_i_like: Optional[PromotionalEntitlementStatus] = Field(alias="notILike")
    not_in: Optional[List[PromotionalEntitlementStatus]] = Field(alias="notIn")
    not_like: Optional[PromotionalEntitlementStatus] = Field(alias="notLike")


class PromotionalEntitlementUpdateInput(BaseModel):
    description: Optional[str]
    end_date: Optional[Any] = Field(alias="endDate")
    has_unlimited_usage: Optional[bool] = Field(alias="hasUnlimitedUsage")
    is_visible: bool = Field(alias="isVisible")
    monthly_reset_period_configuration: Optional[
        "MonthlyResetPeriodConfigInput"
    ] = Field(alias="monthlyResetPeriodConfiguration")
    period: PromotionalEntitlementPeriod
    reset_period: Optional[EntitlementResetPeriod] = Field(alias="resetPeriod")
    usage_limit: Optional[float] = Field(alias="usageLimit")
    weekly_reset_period_configuration: Optional["WeeklyResetPeriodConfigInput"] = Field(
        alias="weeklyResetPeriodConfiguration"
    )


class ProvisionCustomerInput(BaseModel):
    additional_meta_data: Optional[Any] = Field(alias="additionalMetaData")
    billing_id: Optional[str] = Field(alias="billingId")
    billing_information: Optional["CustomerBillingInfo"] = Field(
        alias="billingInformation"
    )
    coupon_ref_id: Optional[str] = Field(alias="couponRefId")
    created_at: Optional[Any] = Field(alias="createdAt")
    crm_id: Optional[str] = Field(alias="crmId")
    customer_id: Optional[str] = Field(alias="customerId")
    email: Optional[str]
    environment_id: Optional[str] = Field(alias="environmentId")
    exclude_from_experiment: Optional[bool] = Field(
        alias="excludeFromExperiment", default=False
    )
    name: Optional[str]
    ref_id: Optional[str] = Field(alias="refId")
    should_sync_free: Optional[bool] = Field(alias="shouldSyncFree", default=False)
    subscription_params: Optional["ProvisionCustomerSubscriptionInput"] = Field(
        alias="subscriptionParams"
    )


class ProvisionCustomerSubscriptionInput(BaseModel):
    additional_meta_data: Optional[Any] = Field(alias="additionalMetaData")
    addons: Optional[List["SubscriptionAddonInput"]]
    await_payment_confirmation: Optional[bool] = Field(
        alias="awaitPaymentConfirmation", default=True
    )
    billable_features: Optional[List["BillableFeatureInput"]] = Field(
        alias="billableFeatures"
    )
    billing_country_code: Optional[str] = Field(alias="billingCountryCode")
    billing_id: Optional[str] = Field(alias="billingId")
    billing_information: Optional["SubscriptionBillingInfo"] = Field(
        alias="billingInformation"
    )
    billing_period: Optional[BillingPeriod] = Field(alias="billingPeriod")
    plan_id: str = Field(alias="planId")
    price_unit_amount: Optional[float] = Field(alias="priceUnitAmount")
    promotion_code: Optional[str] = Field(alias="promotionCode")
    ref_id: Optional[str] = Field(alias="refId")
    resource_id: Optional[str] = Field(alias="resourceId")
    start_date: Optional[Any] = Field(alias="startDate")
    subscription_id: Optional[str] = Field(alias="subscriptionId")
    unit_quantity: Optional[float] = Field(alias="unitQuantity", default=-1)


class ProvisionSandboxInput(BaseModel):
    billing_model: BillingModel = Field(alias="billingModel")
    display_name: str = Field(alias="displayName")


class ProvisionSubscription(BaseModel):
    additional_meta_data: Optional[Any] = Field(alias="additionalMetaData")
    addons: Optional[List["SubscriptionAddonInput"]]
    await_payment_confirmation: Optional[bool] = Field(
        alias="awaitPaymentConfirmation", default=True
    )
    billable_features: Optional[List["BillableFeatureInput"]] = Field(
        alias="billableFeatures"
    )
    billing_country_code: Optional[str] = Field(alias="billingCountryCode")
    billing_id: Optional[str] = Field(alias="billingId")
    billing_information: Optional["SubscriptionBillingInfo"] = Field(
        alias="billingInformation"
    )
    billing_period: Optional[BillingPeriod] = Field(alias="billingPeriod")
    checkout_options: Optional["CheckoutOptions"] = Field(alias="checkoutOptions")
    customer_id: str = Field(alias="customerId")
    plan_id: str = Field(alias="planId")
    price_unit_amount: Optional[float] = Field(alias="priceUnitAmount")
    promotion_code: Optional[str] = Field(alias="promotionCode")
    ref_id: Optional[str] = Field(alias="refId")
    resource_id: Optional[str] = Field(alias="resourceId")
    skip_trial: Optional[bool] = Field(alias="skipTrial", default=False)
    start_date: Optional[Any] = Field(alias="startDate")
    subscription_id: Optional[str] = Field(alias="subscriptionId")
    unit_quantity: Optional[float] = Field(alias="unitQuantity", default=-1)


class ProvisionSubscriptionInput(BaseModel):
    additional_meta_data: Optional[Any] = Field(alias="additionalMetaData")
    addons: Optional[List["SubscriptionAddonInput"]]
    await_payment_confirmation: Optional[bool] = Field(
        alias="awaitPaymentConfirmation", default=True
    )
    billable_features: Optional[List["BillableFeatureInput"]] = Field(
        alias="billableFeatures"
    )
    billing_country_code: Optional[str] = Field(alias="billingCountryCode")
    billing_id: Optional[str] = Field(alias="billingId")
    billing_information: Optional["SubscriptionBillingInfo"] = Field(
        alias="billingInformation"
    )
    billing_period: Optional[BillingPeriod] = Field(alias="billingPeriod")
    checkout_options: Optional["CheckoutOptions"] = Field(alias="checkoutOptions")
    customer_id: str = Field(alias="customerId")
    plan_id: str = Field(alias="planId")
    price_unit_amount: Optional[float] = Field(alias="priceUnitAmount")
    promotion_code: Optional[str] = Field(alias="promotionCode")
    ref_id: Optional[str] = Field(alias="refId")
    resource_id: Optional[str] = Field(alias="resourceId")
    skip_trial: Optional[bool] = Field(alias="skipTrial", default=False)
    start_date: Optional[Any] = Field(alias="startDate")
    subscription_id: Optional[str] = Field(alias="subscriptionId")
    unit_quantity: Optional[float] = Field(alias="unitQuantity", default=-1)


class RecalculateEntitlementsInput(BaseModel):
    customer_ids: Optional[List[str]] = Field(alias="customerIds")
    environment_id: str = Field(alias="environmentId")
    for_all_customers: Optional[bool] = Field(alias="forAllCustomers", default=False)
    last_calculation_before: Optional[Any] = Field(alias="lastCalculationBefore")
    max_batches: Optional[int] = Field(alias="maxBatches")


class RemoveBasePlanFromPlanInput(BaseModel):
    id: str
    relation_id: str = Field(alias="relationId")


class RemoveCompatibleAddonsFromPlanInput(BaseModel):
    id: str
    relation_ids: List[str] = Field(alias="relationIds")


class RemoveCouponFromCustomerInput(BaseModel):
    id: str
    relation_id: str = Field(alias="relationId")


class RemoveCouponFromCustomerSubscriptionInput(BaseModel):
    id: str
    relation_id: str = Field(alias="relationId")


class RemoveExperimentFromCustomerInput(BaseModel):
    id: str
    relation_id: str = Field(alias="relationId")


class RemoveExperimentFromCustomerSubscriptionInput(BaseModel):
    id: str
    relation_id: str = Field(alias="relationId")


class ReportUsageInput(BaseModel):
    created_at: Optional[Any] = Field(alias="createdAt")
    customer_id: str = Field(alias="customerId")
    environment_id: Optional[str] = Field(alias="environmentId")
    feature_id: str = Field(alias="featureId")
    resource_id: Optional[str] = Field(alias="resourceId")
    update_behavior: Optional[UsageUpdateBehavior] = Field(
        alias="updateBehavior", default=UsageUpdateBehavior.DELTA
    )
    value: float


class ResyncIntegrationInput(BaseModel):
    environment_id: str = Field(alias="environmentId")
    vendor_identifier: VendorIdentifier = Field(alias="vendorIdentifier")


class SetBasePlanOnPlanInput(BaseModel):
    id: str
    relation_id: str = Field(alias="relationId")


class SetCompatibleAddonsOnPlanInput(BaseModel):
    id: str
    relation_ids: List[str] = Field(alias="relationIds")


class SetCouponOnCustomerInput(BaseModel):
    id: str
    relation_id: str = Field(alias="relationId")


class SetCouponOnCustomerSubscriptionInput(BaseModel):
    id: str
    relation_id: str = Field(alias="relationId")


class SetExperimentOnCustomerInput(BaseModel):
    id: str
    relation_id: str = Field(alias="relationId")


class SetExperimentOnCustomerSubscriptionInput(BaseModel):
    id: str
    relation_id: str = Field(alias="relationId")


class StartExperimentInput(BaseModel):
    environment_id: Optional[str] = Field(alias="environmentId")
    ref_id: str = Field(alias="refId")


class StopExperimentInput(BaseModel):
    environment_id: Optional[str] = Field(alias="environmentId")
    ref_id: str = Field(alias="refId")


class StringFieldComparison(BaseModel):
    eq: Optional[str]
    gt: Optional[str]
    gte: Optional[str]
    i_like: Optional[str] = Field(alias="iLike")
    in_: Optional[List[str]] = Field(alias="in")
    is_: Optional[bool] = Field(alias="is")
    is_not: Optional[bool] = Field(alias="isNot")
    like: Optional[str]
    lt: Optional[str]
    lte: Optional[str]
    neq: Optional[str]
    not_i_like: Optional[str] = Field(alias="notILike")
    not_in: Optional[List[str]] = Field(alias="notIn")
    not_like: Optional[str] = Field(alias="notLike")


class StripeCredentialsInput(BaseModel):
    account_id: Optional[str] = Field(alias="accountId")
    authorization_code: str = Field(alias="authorizationCode")
    is_test_mode: bool = Field(alias="isTestMode")


class StripeCustomerSearchInput(BaseModel):
    customer_name: Optional[str] = Field(alias="customerName")
    environment_id: str = Field(alias="environmentId")
    next_page: Optional[str] = Field(alias="nextPage")


class StripeProductSearchInput(BaseModel):
    environment_id: str = Field(alias="environmentId")
    next_page: Optional[str] = Field(alias="nextPage")
    product_name: Optional[str] = Field(alias="productName")


class StripeSubscriptionSearchInput(BaseModel):
    environment_id: str = Field(alias="environmentId")
    next_page: Optional[str] = Field(alias="nextPage")


class SubscriptionAddonFilter(BaseModel):
    addon: Optional["SubscriptionAddonFilterAddonFilter"]
    and_: Optional[List["SubscriptionAddonFilter"]] = Field(alias="and")
    created_at: Optional["DateFieldComparison"] = Field(alias="createdAt")
    id: Optional["StringFieldComparison"]
    or_: Optional[List["SubscriptionAddonFilter"]] = Field(alias="or")
    price: Optional["SubscriptionAddonFilterPriceFilter"]
    quantity: Optional["NumberFieldComparison"]
    subscription: Optional["SubscriptionAddonFilterCustomerSubscriptionFilter"]
    updated_at: Optional["DateFieldComparison"] = Field(alias="updatedAt")


class SubscriptionAddonFilterAddonFilter(BaseModel):
    and_: Optional[List["SubscriptionAddonFilterAddonFilter"]] = Field(alias="and")
    billing_id: Optional["StringFieldComparison"] = Field(alias="billingId")
    created_at: Optional["DateFieldComparison"] = Field(alias="createdAt")
    description: Optional["StringFieldComparison"]
    display_name: Optional["StringFieldComparison"] = Field(alias="displayName")
    environment_id: Optional["StringFieldComparison"] = Field(alias="environmentId")
    id: Optional["StringFieldComparison"]
    is_latest: Optional["BooleanFieldComparison"] = Field(alias="isLatest")
    or_: Optional[List["SubscriptionAddonFilterAddonFilter"]] = Field(alias="or")
    pricing_type: Optional["PricingTypeFilterComparison"] = Field(alias="pricingType")
    product_id: Optional["StringFieldComparison"] = Field(alias="productId")
    ref_id: Optional["StringFieldComparison"] = Field(alias="refId")
    status: Optional["PackageStatusFilterComparison"]
    updated_at: Optional["DateFieldComparison"] = Field(alias="updatedAt")
    version_number: Optional["IntFieldComparison"] = Field(alias="versionNumber")


class SubscriptionAddonFilterCustomerSubscriptionFilter(BaseModel):
    and_: Optional[List["SubscriptionAddonFilterCustomerSubscriptionFilter"]] = Field(
        alias="and"
    )
    billing_id: Optional["StringFieldComparison"] = Field(alias="billingId")
    cancel_reason: Optional["SubscriptionCancelReasonFilterComparison"] = Field(
        alias="cancelReason"
    )
    cancellation_date: Optional["DateFieldComparison"] = Field(alias="cancellationDate")
    created_at: Optional["DateFieldComparison"] = Field(alias="createdAt")
    crm_id: Optional["StringFieldComparison"] = Field(alias="crmId")
    crm_link_url: Optional["StringFieldComparison"] = Field(alias="crmLinkUrl")
    effective_end_date: Optional["DateFieldComparison"] = Field(
        alias="effectiveEndDate"
    )
    end_date: Optional["DateFieldComparison"] = Field(alias="endDate")
    environment_id: Optional["StringFieldComparison"] = Field(alias="environmentId")
    id: Optional["StringFieldComparison"]
    old_billing_id: Optional["StringFieldComparison"] = Field(alias="oldBillingId")
    or_: Optional[List["SubscriptionAddonFilterCustomerSubscriptionFilter"]] = Field(
        alias="or"
    )
    pricing_type: Optional["PricingTypeFilterComparison"] = Field(alias="pricingType")
    ref_id: Optional["StringFieldComparison"] = Field(alias="refId")
    resource_id: Optional["StringFieldComparison"] = Field(alias="resourceId")
    start_date: Optional["DateFieldComparison"] = Field(alias="startDate")
    status: Optional["SubscriptionStatusFilterComparison"]
    subscription_id: Optional["StringFieldComparison"] = Field(alias="subscriptionId")
    trial_end_date: Optional["DateFieldComparison"] = Field(alias="trialEndDate")


class SubscriptionAddonFilterPriceFilter(BaseModel):
    and_: Optional[List["SubscriptionAddonFilterPriceFilter"]] = Field(alias="and")
    billing_id: Optional["StringFieldComparison"] = Field(alias="billingId")
    billing_model: Optional["BillingModelFilterComparison"] = Field(
        alias="billingModel"
    )
    billing_period: Optional["BillingPeriodFilterComparison"] = Field(
        alias="billingPeriod"
    )
    created_at: Optional["DateFieldComparison"] = Field(alias="createdAt")
    id: Optional["StringFieldComparison"]
    or_: Optional[List["SubscriptionAddonFilterPriceFilter"]] = Field(alias="or")


class SubscriptionAddonInput(BaseModel):
    addon_id: str = Field(alias="addonId")
    quantity: Optional[int] = 1


class SubscriptionAddonSort(BaseModel):
    direction: SortDirection
    field: SubscriptionAddonSortFields
    nulls: Optional[SortNulls]


class SubscriptionBillingInfo(BaseModel):
    tax_rate_ids: Optional[List[str]] = Field(alias="taxRateIds")


class SubscriptionCancelReasonFilterComparison(BaseModel):
    eq: Optional[SubscriptionCancelReason]
    gt: Optional[SubscriptionCancelReason]
    gte: Optional[SubscriptionCancelReason]
    i_like: Optional[SubscriptionCancelReason] = Field(alias="iLike")
    in_: Optional[List[SubscriptionCancelReason]] = Field(alias="in")
    is_: Optional[bool] = Field(alias="is")
    is_not: Optional[bool] = Field(alias="isNot")
    like: Optional[SubscriptionCancelReason]
    lt: Optional[SubscriptionCancelReason]
    lte: Optional[SubscriptionCancelReason]
    neq: Optional[SubscriptionCancelReason]
    not_i_like: Optional[SubscriptionCancelReason] = Field(alias="notILike")
    not_in: Optional[List[SubscriptionCancelReason]] = Field(alias="notIn")
    not_like: Optional[SubscriptionCancelReason] = Field(alias="notLike")


class SubscriptionCancellationInput(BaseModel):
    end_date: Optional[Any] = Field(alias="endDate")
    environment_id: Optional[str] = Field(alias="environmentId")
    subscription_cancellation_time: Optional[SubscriptionCancellationTime] = Field(
        alias="subscriptionCancellationTime"
    )
    subscription_ref_id: str = Field(alias="subscriptionRefId")


class SubscriptionEntitlementFilter(BaseModel):
    and_: Optional[List["SubscriptionEntitlementFilter"]] = Field(alias="and")
    created_at: Optional["DateFieldComparison"] = Field(alias="createdAt")
    environment_id: Optional["StringFieldComparison"] = Field(alias="environmentId")
    feature: Optional["SubscriptionEntitlementFilterFeatureFilter"]
    id: Optional["StringFieldComparison"]
    or_: Optional[List["SubscriptionEntitlementFilter"]] = Field(alias="or")
    subscription: Optional["SubscriptionEntitlementFilterCustomerSubscriptionFilter"]
    subscription_id: Optional["StringFieldComparison"] = Field(alias="subscriptionId")
    updated_at: Optional["DateFieldComparison"] = Field(alias="updatedAt")


class SubscriptionEntitlementFilterCustomerSubscriptionFilter(BaseModel):
    and_: Optional[
        List["SubscriptionEntitlementFilterCustomerSubscriptionFilter"]
    ] = Field(alias="and")
    billing_id: Optional["StringFieldComparison"] = Field(alias="billingId")
    cancel_reason: Optional["SubscriptionCancelReasonFilterComparison"] = Field(
        alias="cancelReason"
    )
    cancellation_date: Optional["DateFieldComparison"] = Field(alias="cancellationDate")
    created_at: Optional["DateFieldComparison"] = Field(alias="createdAt")
    crm_id: Optional["StringFieldComparison"] = Field(alias="crmId")
    crm_link_url: Optional["StringFieldComparison"] = Field(alias="crmLinkUrl")
    effective_end_date: Optional["DateFieldComparison"] = Field(
        alias="effectiveEndDate"
    )
    end_date: Optional["DateFieldComparison"] = Field(alias="endDate")
    environment_id: Optional["StringFieldComparison"] = Field(alias="environmentId")
    id: Optional["StringFieldComparison"]
    old_billing_id: Optional["StringFieldComparison"] = Field(alias="oldBillingId")
    or_: Optional[
        List["SubscriptionEntitlementFilterCustomerSubscriptionFilter"]
    ] = Field(alias="or")
    pricing_type: Optional["PricingTypeFilterComparison"] = Field(alias="pricingType")
    ref_id: Optional["StringFieldComparison"] = Field(alias="refId")
    resource_id: Optional["StringFieldComparison"] = Field(alias="resourceId")
    start_date: Optional["DateFieldComparison"] = Field(alias="startDate")
    status: Optional["SubscriptionStatusFilterComparison"]
    subscription_id: Optional["StringFieldComparison"] = Field(alias="subscriptionId")
    trial_end_date: Optional["DateFieldComparison"] = Field(alias="trialEndDate")


class SubscriptionEntitlementFilterFeatureFilter(BaseModel):
    and_: Optional[List["SubscriptionEntitlementFilterFeatureFilter"]] = Field(
        alias="and"
    )
    created_at: Optional["DateFieldComparison"] = Field(alias="createdAt")
    description: Optional["StringFieldComparison"]
    display_name: Optional["StringFieldComparison"] = Field(alias="displayName")
    environment_id: Optional["StringFieldComparison"] = Field(alias="environmentId")
    feature_status: Optional["FeatureStatusFilterComparison"] = Field(
        alias="featureStatus"
    )
    feature_type: Optional["FeatureTypeFilterComparison"] = Field(alias="featureType")
    id: Optional["StringFieldComparison"]
    meter_type: Optional["MeterTypeFilterComparison"] = Field(alias="meterType")
    or_: Optional[List["SubscriptionEntitlementFilterFeatureFilter"]] = Field(
        alias="or"
    )
    ref_id: Optional["StringFieldComparison"] = Field(alias="refId")
    updated_at: Optional["DateFieldComparison"] = Field(alias="updatedAt")


class SubscriptionEntitlementInput(BaseModel):
    description: Optional[str]
    feature_id: str = Field(alias="featureId")
    has_unlimited_usage: Optional[bool] = Field(alias="hasUnlimitedUsage")
    monthly_reset_period_configuration: Optional[
        "MonthlyResetPeriodConfigInput"
    ] = Field(alias="monthlyResetPeriodConfiguration")
    reset_period: Optional[EntitlementResetPeriod] = Field(alias="resetPeriod")
    usage_limit: Optional[float] = Field(alias="usageLimit")
    weekly_reset_period_configuration: Optional["WeeklyResetPeriodConfigInput"] = Field(
        alias="weeklyResetPeriodConfiguration"
    )


class SubscriptionEntitlementSort(BaseModel):
    direction: SortDirection
    field: SubscriptionEntitlementSortFields
    nulls: Optional[SortNulls]


class SubscriptionInput(BaseModel):
    additional_meta_data: Optional[Any] = Field(alias="additionalMetaData")
    addons: Optional[List["SubscriptionAddonInput"]]
    await_payment_confirmation: Optional[bool] = Field(
        alias="awaitPaymentConfirmation", default=True
    )
    billable_features: Optional[List["BillableFeatureInput"]] = Field(
        alias="billableFeatures"
    )
    billing_country_code: Optional[str] = Field(alias="billingCountryCode")
    billing_id: Optional[str] = Field(alias="billingId")
    billing_information: Optional["SubscriptionBillingInfo"] = Field(
        alias="billingInformation"
    )
    billing_period: Optional[BillingPeriod] = Field(alias="billingPeriod")
    crm_id: Optional[str] = Field(alias="crmId")
    customer_id: str = Field(alias="customerId")
    end_date: Optional[Any] = Field(alias="endDate")
    environment_id: Optional[str] = Field(alias="environmentId")
    is_custom_price_subscription: Optional[bool] = Field(
        alias="isCustomPriceSubscription", default=False
    )
    is_overriding_trial_config: Optional[bool] = Field(
        alias="isOverridingTrialConfig", default=False
    )
    is_trial: Optional[bool] = Field(alias="isTrial")
    plan_id: str = Field(alias="planId")
    price_unit_amount: Optional[float] = Field(alias="priceUnitAmount")
    promotion_code: Optional[str] = Field(alias="promotionCode")
    ref_id: Optional[str] = Field(alias="refId")
    resource_id: Optional[str] = Field(alias="resourceId")
    start_date: Optional[Any] = Field(alias="startDate")
    subscription_entitlements: Optional[List["SubscriptionEntitlementInput"]] = Field(
        alias="subscriptionEntitlements"
    )
    subscription_id: Optional[str] = Field(alias="subscriptionId")
    unit_quantity: Optional[float] = Field(alias="unitQuantity", default=-1)


class SubscriptionMigrationInput(BaseModel):
    environment_id: Optional[str] = Field(alias="environmentId")
    subscription_id: str = Field(alias="subscriptionId")
    subscription_migration_time: Optional[SubscriptionMigrationTime] = Field(
        alias="subscriptionMigrationTime"
    )


class SubscriptionMigrationTaskFilter(BaseModel):
    and_: Optional[List["SubscriptionMigrationTaskFilter"]] = Field(alias="and")
    created_at: Optional["DateFieldComparison"] = Field(alias="createdAt")
    environment_id: Optional["StringFieldComparison"] = Field(alias="environmentId")
    id: Optional["StringFieldComparison"]
    or_: Optional[List["SubscriptionMigrationTaskFilter"]] = Field(alias="or")
    status: Optional["TaskStatusFilterComparison"]
    task_type: Optional["TaskTypeFilterComparison"] = Field(alias="taskType")


class SubscriptionMigrationTaskSort(BaseModel):
    direction: SortDirection
    field: SubscriptionMigrationTaskSortFields
    nulls: Optional[SortNulls]


class SubscriptionPriceFilter(BaseModel):
    and_: Optional[List["SubscriptionPriceFilter"]] = Field(alias="and")
    billing_model: Optional["BillingModelFilterComparison"] = Field(
        alias="billingModel"
    )
    created_at: Optional["DateFieldComparison"] = Field(alias="createdAt")
    feature_id: Optional["StringFieldComparison"] = Field(alias="featureId")
    id: Optional["StringFieldComparison"]
    or_: Optional[List["SubscriptionPriceFilter"]] = Field(alias="or")
    price: Optional["SubscriptionPriceFilterPriceFilter"]
    subscription: Optional["SubscriptionPriceFilterCustomerSubscriptionFilter"]
    updated_at: Optional["DateFieldComparison"] = Field(alias="updatedAt")
    usage_limit: Optional["NumberFieldComparison"] = Field(alias="usageLimit")


class SubscriptionPriceFilterCustomerSubscriptionFilter(BaseModel):
    and_: Optional[List["SubscriptionPriceFilterCustomerSubscriptionFilter"]] = Field(
        alias="and"
    )
    billing_id: Optional["StringFieldComparison"] = Field(alias="billingId")
    cancel_reason: Optional["SubscriptionCancelReasonFilterComparison"] = Field(
        alias="cancelReason"
    )
    cancellation_date: Optional["DateFieldComparison"] = Field(alias="cancellationDate")
    created_at: Optional["DateFieldComparison"] = Field(alias="createdAt")
    crm_id: Optional["StringFieldComparison"] = Field(alias="crmId")
    crm_link_url: Optional["StringFieldComparison"] = Field(alias="crmLinkUrl")
    effective_end_date: Optional["DateFieldComparison"] = Field(
        alias="effectiveEndDate"
    )
    end_date: Optional["DateFieldComparison"] = Field(alias="endDate")
    environment_id: Optional["StringFieldComparison"] = Field(alias="environmentId")
    id: Optional["StringFieldComparison"]
    old_billing_id: Optional["StringFieldComparison"] = Field(alias="oldBillingId")
    or_: Optional[List["SubscriptionPriceFilterCustomerSubscriptionFilter"]] = Field(
        alias="or"
    )
    pricing_type: Optional["PricingTypeFilterComparison"] = Field(alias="pricingType")
    ref_id: Optional["StringFieldComparison"] = Field(alias="refId")
    resource_id: Optional["StringFieldComparison"] = Field(alias="resourceId")
    start_date: Optional["DateFieldComparison"] = Field(alias="startDate")
    status: Optional["SubscriptionStatusFilterComparison"]
    subscription_id: Optional["StringFieldComparison"] = Field(alias="subscriptionId")
    trial_end_date: Optional["DateFieldComparison"] = Field(alias="trialEndDate")


class SubscriptionPriceFilterPriceFilter(BaseModel):
    and_: Optional[List["SubscriptionPriceFilterPriceFilter"]] = Field(alias="and")
    billing_id: Optional["StringFieldComparison"] = Field(alias="billingId")
    billing_model: Optional["BillingModelFilterComparison"] = Field(
        alias="billingModel"
    )
    billing_period: Optional["BillingPeriodFilterComparison"] = Field(
        alias="billingPeriod"
    )
    created_at: Optional["DateFieldComparison"] = Field(alias="createdAt")
    id: Optional["StringFieldComparison"]
    or_: Optional[List["SubscriptionPriceFilterPriceFilter"]] = Field(alias="or")


class SubscriptionPriceSort(BaseModel):
    direction: SortDirection
    field: SubscriptionPriceSortFields
    nulls: Optional[SortNulls]


class SubscriptionStatusFilterComparison(BaseModel):
    eq: Optional[SubscriptionStatus]
    gt: Optional[SubscriptionStatus]
    gte: Optional[SubscriptionStatus]
    i_like: Optional[SubscriptionStatus] = Field(alias="iLike")
    in_: Optional[List[SubscriptionStatus]] = Field(alias="in")
    is_: Optional[bool] = Field(alias="is")
    is_not: Optional[bool] = Field(alias="isNot")
    like: Optional[SubscriptionStatus]
    lt: Optional[SubscriptionStatus]
    lte: Optional[SubscriptionStatus]
    neq: Optional[SubscriptionStatus]
    not_i_like: Optional[SubscriptionStatus] = Field(alias="notILike")
    not_in: Optional[List[SubscriptionStatus]] = Field(alias="notIn")
    not_like: Optional[SubscriptionStatus] = Field(alias="notLike")


class SubscriptionUpdateScheduleCancellationInput(BaseModel):
    environment_id: Optional[str] = Field(alias="environmentId")
    subscription_id: str = Field(alias="subscriptionId")


class SyncTaxRatesInput(BaseModel):
    environment_id: Optional[str] = Field(alias="environmentId")


class TaskStatusFilterComparison(BaseModel):
    eq: Optional[TaskStatus]
    gt: Optional[TaskStatus]
    gte: Optional[TaskStatus]
    i_like: Optional[TaskStatus] = Field(alias="iLike")
    in_: Optional[List[TaskStatus]] = Field(alias="in")
    is_: Optional[bool] = Field(alias="is")
    is_not: Optional[bool] = Field(alias="isNot")
    like: Optional[TaskStatus]
    lt: Optional[TaskStatus]
    lte: Optional[TaskStatus]
    neq: Optional[TaskStatus]
    not_i_like: Optional[TaskStatus] = Field(alias="notILike")
    not_in: Optional[List[TaskStatus]] = Field(alias="notIn")
    not_like: Optional[TaskStatus] = Field(alias="notLike")


class TaskTypeFilterComparison(BaseModel):
    eq: Optional[TaskType]
    gt: Optional[TaskType]
    gte: Optional[TaskType]
    i_like: Optional[TaskType] = Field(alias="iLike")
    in_: Optional[List[TaskType]] = Field(alias="in")
    is_: Optional[bool] = Field(alias="is")
    is_not: Optional[bool] = Field(alias="isNot")
    like: Optional[TaskType]
    lt: Optional[TaskType]
    lte: Optional[TaskType]
    neq: Optional[TaskType]
    not_i_like: Optional[TaskType] = Field(alias="notILike")
    not_in: Optional[List[TaskType]] = Field(alias="notIn")
    not_like: Optional[TaskType] = Field(alias="notLike")


class TaxExempt(BaseModel):
    type: str
    value: str


class TestHookInput(BaseModel):
    endpoint_url: str = Field(alias="endpointUrl")
    environment_id: str = Field(alias="environmentId")
    hook_event_type: EventLogType = Field(alias="hookEventType")


class TypographyConfigurationInput(BaseModel):
    body: Optional["FontVariantInput"]
    font_family: Optional[str] = Field(alias="fontFamily")
    h1: Optional["FontVariantInput"]
    h2: Optional["FontVariantInput"]
    h3: Optional["FontVariantInput"]


class UpdateAccountInput(BaseModel):
    display_name: str = Field(alias="displayName")
    id: Optional[str]
    subscription_billing_anchor: Optional[BillingAnchor] = Field(
        alias="subscriptionBillingAnchor"
    )
    subscription_proration_behavior: Optional[ProrationBehavior] = Field(
        alias="subscriptionProrationBehavior"
    )
    timezone: Optional[str]


class UpdateCouponInput(BaseModel):
    additional_meta_data: Optional[Any] = Field(alias="additionalMetaData")
    description: Optional[str]
    environment_id: Optional[str] = Field(alias="environmentId")
    name: str
    ref_id: str = Field(alias="refId")


class UpdateCustomerInput(BaseModel):
    additional_meta_data: Optional[Any] = Field(alias="additionalMetaData")
    billing_id: Optional[str] = Field(alias="billingId")
    billing_information: Optional["CustomerBillingInfo"] = Field(
        alias="billingInformation"
    )
    coupon_ref_id: Optional[str] = Field(alias="couponRefId")
    crm_id: Optional[str] = Field(alias="crmId")
    customer_id: Optional[str] = Field(alias="customerId")
    email: Optional[str]
    environment_id: Optional[str] = Field(alias="environmentId")
    name: Optional[str]
    ref_id: Optional[str] = Field(alias="refId")


class UpdateExperimentInput(BaseModel):
    control_group_name: Optional[str] = Field(alias="controlGroupName")
    description: Optional[str]
    environment_id: Optional[str] = Field(alias="environmentId")
    name: Optional[str]
    product_id: Optional[str] = Field(alias="productId")
    product_settings: Optional["ProductSettingsInput"] = Field(alias="productSettings")
    ref_id: str = Field(alias="refId")
    variant_group_name: Optional[str] = Field(alias="variantGroupName")
    variant_percentage: Optional[float] = Field(alias="variantPercentage")


class UpdateFeature(BaseModel):
    additional_meta_data: Optional[Any] = Field(alias="additionalMetaData")
    created_at: Optional[Any] = Field(alias="createdAt")
    description: Optional[str]
    display_name: Optional[str] = Field(alias="displayName")
    environment_id: Optional[str] = Field(alias="environmentId")
    feature_status: Optional[FeatureStatus] = Field(alias="featureStatus")
    feature_type: Optional[FeatureType] = Field(alias="featureType")
    feature_units: Optional[str] = Field(alias="featureUnits")
    feature_units_plural: Optional[str] = Field(alias="featureUnitsPlural")
    id: Optional[str]
    meter_type: Optional[MeterType] = Field(alias="meterType")
    ref_id: Optional[str] = Field(alias="refId")
    updated_at: Optional[Any] = Field(alias="updatedAt")


class UpdateFeatureInput(BaseModel):
    additional_meta_data: Optional[Any] = Field(alias="additionalMetaData")
    description: Optional[str]
    display_name: Optional[str] = Field(alias="displayName")
    environment_id: str = Field(alias="environmentId")
    feature_units: Optional[str] = Field(alias="featureUnits")
    feature_units_plural: Optional[str] = Field(alias="featureUnitsPlural")
    meter: Optional["CreateMeter"]
    ref_id: str = Field(alias="refId")


class UpdateHook(BaseModel):
    created_at: Optional[Any] = Field(alias="createdAt")
    description: Optional[str]
    endpoint: Optional[str]
    environment_id: Optional[str] = Field(alias="environmentId")
    event_log_types: Optional[List[EventLogType]] = Field(alias="eventLogTypes")
    id: Optional[str]
    secret_key: Optional[str] = Field(alias="secretKey")
    status: Optional[HookStatus]


class UpdateIntegrationInput(BaseModel):
    stripe_credentials: Optional["StripeCredentialsInput"] = Field(
        alias="stripeCredentials"
    )
    vendor_identifier: VendorIdentifier = Field(alias="vendorIdentifier")
    zuora_credentials: Optional["ZuoraCredentialsInput"] = Field(
        alias="zuoraCredentials"
    )


class UpdateOneEnvironmentInput(BaseModel):
    id: str
    update: "EnvironmentInput"


class UpdateOneFeatureInput(BaseModel):
    id: str
    update: "UpdateFeature"


class UpdateOneHookInput(BaseModel):
    id: str
    update: "UpdateHook"


class UpdateOneIntegrationInput(BaseModel):
    id: str
    update: "UpdateIntegrationInput"


class UpdateOnePackageEntitlementInput(BaseModel):
    id: str
    update: "PackageEntitlementUpdateInput"


class UpdateOneProductInput(BaseModel):
    id: str
    update: "ProductUpdateInput"


class UpdateOnePromotionalEntitlementInput(BaseModel):
    id: str
    update: "PromotionalEntitlementUpdateInput"


class UpdatePackageEntitlementOrderInput(BaseModel):
    entitlements: List["UpdatePackageEntitlementOrderItemInput"]
    environment_id: Optional[str] = Field(alias="environmentId")
    package_id: str = Field(alias="packageId")


class UpdatePackageEntitlementOrderItemInput(BaseModel):
    id: str
    order: Optional[float]


class UpdateSubscriptionEntitlementInput(BaseModel):
    has_unlimited_usage: Optional[bool] = Field(alias="hasUnlimitedUsage")
    id: str
    monthly_reset_period_configuration: Optional[
        "MonthlyResetPeriodConfigInput"
    ] = Field(alias="monthlyResetPeriodConfiguration")
    reset_period: Optional[EntitlementResetPeriod] = Field(alias="resetPeriod")
    usage_limit: Optional[float] = Field(alias="usageLimit")
    weekly_reset_period_configuration: Optional["WeeklyResetPeriodConfigInput"] = Field(
        alias="weeklyResetPeriodConfiguration"
    )


class UpdateSubscriptionInput(BaseModel):
    additional_meta_data: Optional[Any] = Field(alias="additionalMetaData")
    addons: Optional[List["SubscriptionAddonInput"]]
    billable_features: Optional[List["BillableFeatureInput"]] = Field(
        alias="billableFeatures"
    )
    billing_period: Optional[BillingPeriod] = Field(alias="billingPeriod")
    environment_id: Optional[str] = Field(alias="environmentId")
    promotion_code: Optional[str] = Field(alias="promotionCode")
    ref_id: Optional[str] = Field(alias="refId")
    subscription_entitlements: Optional[
        List["UpdateSubscriptionEntitlementInput"]
    ] = Field(alias="subscriptionEntitlements")
    subscription_id: Optional[str] = Field(alias="subscriptionId")
    trial_end_date: Optional[Any] = Field(alias="trialEndDate")
    unit_quantity: Optional[float] = Field(alias="unitQuantity")


class UpdateUserInput(BaseModel):
    department: Optional[Department]
    name: str


class UsageEventReportInput(BaseModel):
    customer_id: str = Field(alias="customerId")
    dimensions: Optional[Any]
    event_name: str = Field(alias="eventName")
    idempotency_key: str = Field(alias="idempotencyKey")
    resource_id: Optional[str] = Field(alias="resourceId")
    timestamp: Optional[Any]


class UsageEventsInput(BaseModel):
    environment_id: str = Field(alias="environmentId")
    filters: List["MeterFilterDefinitionInput"]


class UsageEventsReportInput(BaseModel):
    environment_id: Optional[str] = Field(alias="environmentId")
    usage_events: List["UsageEventReportInput"] = Field(alias="usageEvents")


class UsageHistoryInput(BaseModel):
    customer_ref_id: str = Field(alias="customerRefId")
    end_date: Optional[Any] = Field(alias="endDate")
    environment_id: Optional[str] = Field(alias="environmentId")
    feature_ref_id: str = Field(alias="featureRefId")
    monthly_reset_period_configuration: Optional[
        "MonthlyResetPeriodConfigInput"
    ] = Field(alias="monthlyResetPeriodConfiguration")
    reset_period: Optional[EntitlementResetPeriod] = Field(alias="resetPeriod")
    resource_ref_id: Optional[str] = Field(alias="resourceRefId")
    start_date: Any = Field(alias="startDate")
    weekly_reset_period_configuration: Optional["WeeklyResetPeriodConfigInput"] = Field(
        alias="weeklyResetPeriodConfiguration"
    )


class UsageMeasurementCreateInput(BaseModel):
    created_at: Optional[Any] = Field(alias="createdAt")
    customer_id: str = Field(alias="customerId")
    environment_id: Optional[str] = Field(alias="environmentId")
    feature_id: str = Field(alias="featureId")
    resource_id: Optional[str] = Field(alias="resourceId")
    update_behavior: Optional[UsageUpdateBehavior] = Field(
        alias="updateBehavior", default=UsageUpdateBehavior.DELTA
    )
    value: float


class UsageMeasurementFilter(BaseModel):
    and_: Optional[List["UsageMeasurementFilter"]] = Field(alias="and")
    created_at: Optional["DateFieldComparison"] = Field(alias="createdAt")
    customer: Optional["UsageMeasurementFilterCustomerFilter"]
    environment_id: Optional["StringFieldComparison"] = Field(alias="environmentId")
    feature: Optional["UsageMeasurementFilterFeatureFilter"]
    id: Optional["StringFieldComparison"]
    or_: Optional[List["UsageMeasurementFilter"]] = Field(alias="or")


class UsageMeasurementFilterCustomerFilter(BaseModel):
    and_: Optional[List["UsageMeasurementFilterCustomerFilter"]] = Field(alias="and")
    billing_id: Optional["StringFieldComparison"] = Field(alias="billingId")
    created_at: Optional["DateFieldComparison"] = Field(alias="createdAt")
    crm_hubspot_company_id: Optional["StringFieldComparison"] = Field(
        alias="crmHubspotCompanyId"
    )
    crm_hubspot_company_url: Optional["StringFieldComparison"] = Field(
        alias="crmHubspotCompanyUrl"
    )
    crm_id: Optional["StringFieldComparison"] = Field(alias="crmId")
    customer_id: Optional["StringFieldComparison"] = Field(alias="customerId")
    deleted_at: Optional["DateFieldComparison"] = Field(alias="deletedAt")
    email: Optional["StringFieldComparison"]
    environment_id: Optional["StringFieldComparison"] = Field(alias="environmentId")
    id: Optional["StringFieldComparison"]
    name: Optional["StringFieldComparison"]
    or_: Optional[List["UsageMeasurementFilterCustomerFilter"]] = Field(alias="or")
    ref_id: Optional["StringFieldComparison"] = Field(alias="refId")
    updated_at: Optional["DateFieldComparison"] = Field(alias="updatedAt")


class UsageMeasurementFilterFeatureFilter(BaseModel):
    and_: Optional[List["UsageMeasurementFilterFeatureFilter"]] = Field(alias="and")
    created_at: Optional["DateFieldComparison"] = Field(alias="createdAt")
    description: Optional["StringFieldComparison"]
    display_name: Optional["StringFieldComparison"] = Field(alias="displayName")
    environment_id: Optional["StringFieldComparison"] = Field(alias="environmentId")
    feature_status: Optional["FeatureStatusFilterComparison"] = Field(
        alias="featureStatus"
    )
    feature_type: Optional["FeatureTypeFilterComparison"] = Field(alias="featureType")
    id: Optional["StringFieldComparison"]
    meter_type: Optional["MeterTypeFilterComparison"] = Field(alias="meterType")
    or_: Optional[List["UsageMeasurementFilterFeatureFilter"]] = Field(alias="or")
    ref_id: Optional["StringFieldComparison"] = Field(alias="refId")
    updated_at: Optional["DateFieldComparison"] = Field(alias="updatedAt")


class UsageMeasurementSort(BaseModel):
    direction: SortDirection
    field: UsageMeasurementSortFields
    nulls: Optional[SortNulls]


class VendorIdentifierFilterComparison(BaseModel):
    eq: Optional[VendorIdentifier]
    gt: Optional[VendorIdentifier]
    gte: Optional[VendorIdentifier]
    i_like: Optional[VendorIdentifier] = Field(alias="iLike")
    in_: Optional[List[VendorIdentifier]] = Field(alias="in")
    is_: Optional[bool] = Field(alias="is")
    is_not: Optional[bool] = Field(alias="isNot")
    like: Optional[VendorIdentifier]
    lt: Optional[VendorIdentifier]
    lte: Optional[VendorIdentifier]
    neq: Optional[VendorIdentifier]
    not_i_like: Optional[VendorIdentifier] = Field(alias="notILike")
    not_in: Optional[List[VendorIdentifier]] = Field(alias="notIn")
    not_like: Optional[VendorIdentifier] = Field(alias="notLike")


class WeeklyResetPeriodConfigInput(BaseModel):
    according_to: WeeklyAccordingTo = Field(alias="accordingTo")


class WidgetConfigurationUpdateInput(BaseModel):
    customer_portal_configuration: Optional["CustomerPortalConfigurationInput"] = Field(
        alias="customerPortalConfiguration"
    )
    environment_id: Optional[str] = Field(alias="environmentId")
    paywall_configuration: Optional["PaywallConfigurationInput"] = Field(
        alias="paywallConfiguration"
    )


class ZuoraCredentialsInput(BaseModel):
    base_url: str = Field(alias="baseUrl")
    client_id: str = Field(alias="clientId")
    client_secret: str = Field(alias="clientSecret")


AddCompatibleAddonsToPlanInput.update_forward_refs()
AddonCreateInput.update_forward_refs()
AddonFilter.update_forward_refs()
AddonSort.update_forward_refs()
AddonUpdateInput.update_forward_refs()
Address.update_forward_refs()
AggregatedEventsByCustomerInput.update_forward_refs()
ApiKeyFilter.update_forward_refs()
ApiKeySort.update_forward_refs()
ArchiveCouponInput.update_forward_refs()
ArchiveCustomerInput.update_forward_refs()
ArchivePlanInput.update_forward_refs()
AttachCustomerPaymentMethodInput.update_forward_refs()
BillableFeatureInput.update_forward_refs()
BillingModelFilterComparison.update_forward_refs()
BillingPeriodFilterComparison.update_forward_refs()
BooleanFieldComparison.update_forward_refs()
CheckoutOptions.update_forward_refs()
ClearCustomerPersistentCacheInput.update_forward_refs()
CouponFilter.update_forward_refs()
CouponFilterCustomerFilter.update_forward_refs()
CouponSort.update_forward_refs()
CouponStatusFilterComparison.update_forward_refs()
CouponTypeFilterComparison.update_forward_refs()
CreateCouponInput.update_forward_refs()
CreateEnvironment.update_forward_refs()
CreateEnvironmentOptions.update_forward_refs()
CreateExperimentInput.update_forward_refs()
CreateHook.update_forward_refs()
CreateIntegrationInput.update_forward_refs()
CreateManyPackageEntitlementsInput.update_forward_refs()
CreateManyPromotionalEntitlementsInput.update_forward_refs()
CreateMeter.update_forward_refs()
CreateOneEnvironmentInput.update_forward_refs()
CreateOneFeatureInput.update_forward_refs()
CreateOneHookInput.update_forward_refs()
CreateOneIntegrationInput.update_forward_refs()
CreateOneProductInput.update_forward_refs()
CursorPaging.update_forward_refs()
CustomerBillingInfo.update_forward_refs()
CustomerFilter.update_forward_refs()
CustomerFilterCustomerSubscriptionFilter.update_forward_refs()
CustomerFilterPromotionalEntitlementFilter.update_forward_refs()
CustomerInput.update_forward_refs()
CustomerPortalColorsPaletteInput.update_forward_refs()
CustomerPortalConfigurationInput.update_forward_refs()
CustomerPortalInput.update_forward_refs()
CustomerResourceFilter.update_forward_refs()
CustomerResourceFilterCustomerFilter.update_forward_refs()
CustomerResourceFilterCustomerSubscriptionFilter.update_forward_refs()
CustomerResourceSort.update_forward_refs()
CustomerSort.update_forward_refs()
CustomerSubscriptionFilter.update_forward_refs()
CustomerSubscriptionFilterCustomerFilter.update_forward_refs()
CustomerSubscriptionFilterCustomerResourceFilter.update_forward_refs()
CustomerSubscriptionFilterPlanFilter.update_forward_refs()
CustomerSubscriptionFilterSubscriptionAddonFilter.update_forward_refs()
CustomerSubscriptionFilterSubscriptionEntitlementFilter.update_forward_refs()
CustomerSubscriptionFilterSubscriptionPriceFilter.update_forward_refs()
CustomerSubscriptionSort.update_forward_refs()
DateFieldComparison.update_forward_refs()
DateFieldComparisonBetween.update_forward_refs()
DefaultTrialConfigInputDTO.update_forward_refs()
DeleteFeatureInput.update_forward_refs()
DeleteOneAddonInput.update_forward_refs()
DeleteOneEnvironmentInput.update_forward_refs()
DeleteOneHookInput.update_forward_refs()
DeleteOneIntegrationInput.update_forward_refs()
DeleteOnePackageEntitlementInput.update_forward_refs()
DeleteOnePriceInput.update_forward_refs()
DeleteOneProductInput.update_forward_refs()
DeleteOnePromotionalEntitlementInput.update_forward_refs()
DiscardPackageDraftInput.update_forward_refs()
EntitlementCheckRequested.update_forward_refs()
EntitlementCheckResult.update_forward_refs()
EntitlementOptions.update_forward_refs()
EnvironmentFilter.update_forward_refs()
EnvironmentInput.update_forward_refs()
EnvironmentSort.update_forward_refs()
EstimateSubscriptionInput.update_forward_refs()
EstimateSubscriptionUpdateInput.update_forward_refs()
EventsFieldsInput.update_forward_refs()
ExperimentFilter.update_forward_refs()
ExperimentFilterCustomerFilter.update_forward_refs()
ExperimentSort.update_forward_refs()
ExperimentStatsQuery.update_forward_refs()
ExperimentStatusFilterComparison.update_forward_refs()
FeatureFilter.update_forward_refs()
FeatureInput.update_forward_refs()
FeatureSort.update_forward_refs()
FeatureStatusFilterComparison.update_forward_refs()
FeatureTypeFilterComparison.update_forward_refs()
FetchEntitlementQuery.update_forward_refs()
FetchEntitlementsQuery.update_forward_refs()
FontVariantInput.update_forward_refs()
GetActiveSubscriptionsInput.update_forward_refs()
GetCustomerByRefIdInput.update_forward_refs()
GetPackageByRefIdInput.update_forward_refs()
GetPaywallInput.update_forward_refs()
GetWidgetConfigurationInput.update_forward_refs()
HookFilter.update_forward_refs()
HookSort.update_forward_refs()
HookStatusFilterComparison.update_forward_refs()
HubspotCredentialsInput.update_forward_refs()
ImportCustomerBulk.update_forward_refs()
ImportCustomerInput.update_forward_refs()
ImportIntegrationCatalogInput.update_forward_refs()
ImportIntegrationCustomersInput.update_forward_refs()
ImportIntegrationTaskFilter.update_forward_refs()
ImportIntegrationTaskSort.update_forward_refs()
ImportSubscriptionInput.update_forward_refs()
ImportSubscriptionsBulk.update_forward_refs()
InitAddStripeCustomerPaymentMethodInput.update_forward_refs()
IntFieldComparison.update_forward_refs()
IntFieldComparisonBetween.update_forward_refs()
IntegrationFilter.update_forward_refs()
IntegrationSort.update_forward_refs()
MemberFilter.update_forward_refs()
MemberSort.update_forward_refs()
MeterAggregation.update_forward_refs()
MeterConditionInput.update_forward_refs()
MeterFilterDefinitionInput.update_forward_refs()
MeterTypeFilterComparison.update_forward_refs()
MoneyInputDTO.update_forward_refs()
MonthlyResetPeriodConfigInput.update_forward_refs()
NumberFieldComparison.update_forward_refs()
NumberFieldComparisonBetween.update_forward_refs()
PackageDTOFilter.update_forward_refs()
PackageDTOSort.update_forward_refs()
PackageEntitlementFilter.update_forward_refs()
PackageEntitlementFilterFeatureFilter.update_forward_refs()
PackageEntitlementFilterPackageDTOFilter.update_forward_refs()
PackageEntitlementInput.update_forward_refs()
PackageEntitlementSort.update_forward_refs()
PackageEntitlementUpdateInput.update_forward_refs()
PackagePricingInput.update_forward_refs()
PackagePublishInput.update_forward_refs()
PackageStatusFilterComparison.update_forward_refs()
PaywallColorsPaletteInput.update_forward_refs()
PaywallConfigurationInput.update_forward_refs()
PaywallLayoutConfigurationInput.update_forward_refs()
PlanCreateInput.update_forward_refs()
PlanFilter.update_forward_refs()
PlanFilterAddonFilter.update_forward_refs()
PlanFilterProductFilter.update_forward_refs()
PlanSort.update_forward_refs()
PlanUpdateInput.update_forward_refs()
PriceFilter.update_forward_refs()
PriceFilterPackageDTOFilter.update_forward_refs()
PricePeriodInput.update_forward_refs()
PriceSort.update_forward_refs()
PricingModelCreateInput.update_forward_refs()
PricingTypeFilterComparison.update_forward_refs()
ProductCreateInput.update_forward_refs()
ProductFilter.update_forward_refs()
ProductSettingsInput.update_forward_refs()
ProductSort.update_forward_refs()
ProductUpdateInput.update_forward_refs()
PromotionalEntitlementFilter.update_forward_refs()
PromotionalEntitlementInput.update_forward_refs()
PromotionalEntitlementSort.update_forward_refs()
PromotionalEntitlementStatusFilterComparison.update_forward_refs()
PromotionalEntitlementUpdateInput.update_forward_refs()
ProvisionCustomerInput.update_forward_refs()
ProvisionCustomerSubscriptionInput.update_forward_refs()
ProvisionSandboxInput.update_forward_refs()
ProvisionSubscription.update_forward_refs()
ProvisionSubscriptionInput.update_forward_refs()
RecalculateEntitlementsInput.update_forward_refs()
RemoveBasePlanFromPlanInput.update_forward_refs()
RemoveCompatibleAddonsFromPlanInput.update_forward_refs()
RemoveCouponFromCustomerInput.update_forward_refs()
RemoveCouponFromCustomerSubscriptionInput.update_forward_refs()
RemoveExperimentFromCustomerInput.update_forward_refs()
RemoveExperimentFromCustomerSubscriptionInput.update_forward_refs()
ReportUsageInput.update_forward_refs()
ResyncIntegrationInput.update_forward_refs()
SetBasePlanOnPlanInput.update_forward_refs()
SetCompatibleAddonsOnPlanInput.update_forward_refs()
SetCouponOnCustomerInput.update_forward_refs()
SetCouponOnCustomerSubscriptionInput.update_forward_refs()
SetExperimentOnCustomerInput.update_forward_refs()
SetExperimentOnCustomerSubscriptionInput.update_forward_refs()
StartExperimentInput.update_forward_refs()
StopExperimentInput.update_forward_refs()
StringFieldComparison.update_forward_refs()
StripeCredentialsInput.update_forward_refs()
StripeCustomerSearchInput.update_forward_refs()
StripeProductSearchInput.update_forward_refs()
StripeSubscriptionSearchInput.update_forward_refs()
SubscriptionAddonFilter.update_forward_refs()
SubscriptionAddonFilterAddonFilter.update_forward_refs()
SubscriptionAddonFilterCustomerSubscriptionFilter.update_forward_refs()
SubscriptionAddonFilterPriceFilter.update_forward_refs()
SubscriptionAddonInput.update_forward_refs()
SubscriptionAddonSort.update_forward_refs()
SubscriptionBillingInfo.update_forward_refs()
SubscriptionCancelReasonFilterComparison.update_forward_refs()
SubscriptionCancellationInput.update_forward_refs()
SubscriptionEntitlementFilter.update_forward_refs()
SubscriptionEntitlementFilterCustomerSubscriptionFilter.update_forward_refs()
SubscriptionEntitlementFilterFeatureFilter.update_forward_refs()
SubscriptionEntitlementInput.update_forward_refs()
SubscriptionEntitlementSort.update_forward_refs()
SubscriptionInput.update_forward_refs()
SubscriptionMigrationInput.update_forward_refs()
SubscriptionMigrationTaskFilter.update_forward_refs()
SubscriptionMigrationTaskSort.update_forward_refs()
SubscriptionPriceFilter.update_forward_refs()
SubscriptionPriceFilterCustomerSubscriptionFilter.update_forward_refs()
SubscriptionPriceFilterPriceFilter.update_forward_refs()
SubscriptionPriceSort.update_forward_refs()
SubscriptionStatusFilterComparison.update_forward_refs()
SubscriptionUpdateScheduleCancellationInput.update_forward_refs()
SyncTaxRatesInput.update_forward_refs()
TaskStatusFilterComparison.update_forward_refs()
TaskTypeFilterComparison.update_forward_refs()
TaxExempt.update_forward_refs()
TestHookInput.update_forward_refs()
TypographyConfigurationInput.update_forward_refs()
UpdateAccountInput.update_forward_refs()
UpdateCouponInput.update_forward_refs()
UpdateCustomerInput.update_forward_refs()
UpdateExperimentInput.update_forward_refs()
UpdateFeature.update_forward_refs()
UpdateFeatureInput.update_forward_refs()
UpdateHook.update_forward_refs()
UpdateIntegrationInput.update_forward_refs()
UpdateOneEnvironmentInput.update_forward_refs()
UpdateOneFeatureInput.update_forward_refs()
UpdateOneHookInput.update_forward_refs()
UpdateOneIntegrationInput.update_forward_refs()
UpdateOnePackageEntitlementInput.update_forward_refs()
UpdateOneProductInput.update_forward_refs()
UpdateOnePromotionalEntitlementInput.update_forward_refs()
UpdatePackageEntitlementOrderInput.update_forward_refs()
UpdatePackageEntitlementOrderItemInput.update_forward_refs()
UpdateSubscriptionEntitlementInput.update_forward_refs()
UpdateSubscriptionInput.update_forward_refs()
UpdateUserInput.update_forward_refs()
UsageEventReportInput.update_forward_refs()
UsageEventsInput.update_forward_refs()
UsageEventsReportInput.update_forward_refs()
UsageHistoryInput.update_forward_refs()
UsageMeasurementCreateInput.update_forward_refs()
UsageMeasurementFilter.update_forward_refs()
UsageMeasurementFilterCustomerFilter.update_forward_refs()
UsageMeasurementFilterFeatureFilter.update_forward_refs()
UsageMeasurementSort.update_forward_refs()
VendorIdentifierFilterComparison.update_forward_refs()
WeeklyResetPeriodConfigInput.update_forward_refs()
WidgetConfigurationUpdateInput.update_forward_refs()
ZuoraCredentialsInput.update_forward_refs()
