# This file was auto-generated by Fern from our API Definition.

# isort: skip_file

import typing
from importlib import import_module

if typing.TYPE_CHECKING:
    from .count_billing_products_params import CountBillingProductsParams
    from .count_billing_products_response import CountBillingProductsResponse
    from .count_customers_params import CountCustomersParams
    from .count_customers_response import CountCustomersResponse
    from .delete_billing_product_response import DeleteBillingProductResponse
    from .delete_product_price_response import DeleteProductPriceResponse
    from .list_billing_prices_params import ListBillingPricesParams
    from .list_billing_prices_response import ListBillingPricesResponse
    from .list_billing_product_prices_params import ListBillingProductPricesParams
    from .list_billing_product_prices_response import ListBillingProductPricesResponse
    from .list_billing_products_params import ListBillingProductsParams
    from .list_billing_products_response import ListBillingProductsResponse
    from .list_coupons_params import ListCouponsParams
    from .list_coupons_response import ListCouponsResponse
    from .list_customers_with_subscriptions_params import ListCustomersWithSubscriptionsParams
    from .list_customers_with_subscriptions_response import ListCustomersWithSubscriptionsResponse
    from .list_invoices_params import ListInvoicesParams
    from .list_invoices_response import ListInvoicesResponse
    from .list_meters_params import ListMetersParams
    from .list_meters_response import ListMetersResponse
    from .list_payment_methods_params import ListPaymentMethodsParams
    from .list_payment_methods_response import ListPaymentMethodsResponse
    from .upsert_billing_coupon_response import UpsertBillingCouponResponse
    from .upsert_billing_customer_response import UpsertBillingCustomerResponse
    from .upsert_billing_meter_response import UpsertBillingMeterResponse
    from .upsert_billing_price_response import UpsertBillingPriceResponse
    from .upsert_billing_product_response import UpsertBillingProductResponse
    from .upsert_billing_subscription_response import UpsertBillingSubscriptionResponse
    from .upsert_invoice_response import UpsertInvoiceResponse
    from .upsert_payment_method_response import UpsertPaymentMethodResponse
_dynamic_imports: typing.Dict[str, str] = {
    "CountBillingProductsParams": ".count_billing_products_params",
    "CountBillingProductsResponse": ".count_billing_products_response",
    "CountCustomersParams": ".count_customers_params",
    "CountCustomersResponse": ".count_customers_response",
    "DeleteBillingProductResponse": ".delete_billing_product_response",
    "DeleteProductPriceResponse": ".delete_product_price_response",
    "ListBillingPricesParams": ".list_billing_prices_params",
    "ListBillingPricesResponse": ".list_billing_prices_response",
    "ListBillingProductPricesParams": ".list_billing_product_prices_params",
    "ListBillingProductPricesResponse": ".list_billing_product_prices_response",
    "ListBillingProductsParams": ".list_billing_products_params",
    "ListBillingProductsResponse": ".list_billing_products_response",
    "ListCouponsParams": ".list_coupons_params",
    "ListCouponsResponse": ".list_coupons_response",
    "ListCustomersWithSubscriptionsParams": ".list_customers_with_subscriptions_params",
    "ListCustomersWithSubscriptionsResponse": ".list_customers_with_subscriptions_response",
    "ListInvoicesParams": ".list_invoices_params",
    "ListInvoicesResponse": ".list_invoices_response",
    "ListMetersParams": ".list_meters_params",
    "ListMetersResponse": ".list_meters_response",
    "ListPaymentMethodsParams": ".list_payment_methods_params",
    "ListPaymentMethodsResponse": ".list_payment_methods_response",
    "UpsertBillingCouponResponse": ".upsert_billing_coupon_response",
    "UpsertBillingCustomerResponse": ".upsert_billing_customer_response",
    "UpsertBillingMeterResponse": ".upsert_billing_meter_response",
    "UpsertBillingPriceResponse": ".upsert_billing_price_response",
    "UpsertBillingProductResponse": ".upsert_billing_product_response",
    "UpsertBillingSubscriptionResponse": ".upsert_billing_subscription_response",
    "UpsertInvoiceResponse": ".upsert_invoice_response",
    "UpsertPaymentMethodResponse": ".upsert_payment_method_response",
}


def __getattr__(attr_name: str) -> typing.Any:
    module_name = _dynamic_imports.get(attr_name)
    if module_name is None:
        raise AttributeError(f"No {attr_name} found in _dynamic_imports for module name -> {__name__}")
    try:
        module = import_module(module_name, __package__)
        if module_name == f".{attr_name}":
            return module
        else:
            return getattr(module, attr_name)
    except ImportError as e:
        raise ImportError(f"Failed to import {attr_name} from {module_name}: {e}") from e
    except AttributeError as e:
        raise AttributeError(f"Failed to get {attr_name} from {module_name}: {e}") from e


def __dir__():
    lazy_attrs = list(_dynamic_imports.keys())
    return sorted(lazy_attrs)


__all__ = [
    "CountBillingProductsParams",
    "CountBillingProductsResponse",
    "CountCustomersParams",
    "CountCustomersResponse",
    "DeleteBillingProductResponse",
    "DeleteProductPriceResponse",
    "ListBillingPricesParams",
    "ListBillingPricesResponse",
    "ListBillingProductPricesParams",
    "ListBillingProductPricesResponse",
    "ListBillingProductsParams",
    "ListBillingProductsResponse",
    "ListCouponsParams",
    "ListCouponsResponse",
    "ListCustomersWithSubscriptionsParams",
    "ListCustomersWithSubscriptionsResponse",
    "ListInvoicesParams",
    "ListInvoicesResponse",
    "ListMetersParams",
    "ListMetersResponse",
    "ListPaymentMethodsParams",
    "ListPaymentMethodsResponse",
    "UpsertBillingCouponResponse",
    "UpsertBillingCustomerResponse",
    "UpsertBillingMeterResponse",
    "UpsertBillingPriceResponse",
    "UpsertBillingProductResponse",
    "UpsertBillingSubscriptionResponse",
    "UpsertInvoiceResponse",
    "UpsertPaymentMethodResponse",
]
