| 1 |
# -*- coding: utf-8 -*- |
| 2 |
# File generated from our OpenAPI spec |
| 3 |
from importlib import import_module |
| 4 |
from typing_extensions import TYPE_CHECKING |
| 5 |
|
| 6 |
if TYPE_CHECKING: |
| 7 |
from stripe.params.climate._order_cancel_params import ( |
| 8 |
OrderCancelParams as OrderCancelParams, |
| 9 |
) |
| 10 |
from stripe.params.climate._order_create_params import ( |
| 11 |
OrderCreateParams as OrderCreateParams, |
| 12 |
OrderCreateParamsBeneficiary as OrderCreateParamsBeneficiary, |
| 13 |
) |
| 14 |
from stripe.params.climate._order_list_params import ( |
| 15 |
OrderListParams as OrderListParams, |
| 16 |
) |
| 17 |
from stripe.params.climate._order_modify_params import ( |
| 18 |
OrderModifyParams as OrderModifyParams, |
| 19 |
OrderModifyParamsBeneficiary as OrderModifyParamsBeneficiary, |
| 20 |
) |
| 21 |
from stripe.params.climate._order_retrieve_params import ( |
| 22 |
OrderRetrieveParams as OrderRetrieveParams, |
| 23 |
) |
| 24 |
from stripe.params.climate._order_update_params import ( |
| 25 |
OrderUpdateParams as OrderUpdateParams, |
| 26 |
OrderUpdateParamsBeneficiary as OrderUpdateParamsBeneficiary, |
| 27 |
) |
| 28 |
from stripe.params.climate._product_list_params import ( |
| 29 |
ProductListParams as ProductListParams, |
| 30 |
) |
| 31 |
from stripe.params.climate._product_retrieve_params import ( |
| 32 |
ProductRetrieveParams as ProductRetrieveParams, |
| 33 |
) |
| 34 |
from stripe.params.climate._supplier_list_params import ( |
| 35 |
SupplierListParams as SupplierListParams, |
| 36 |
) |
| 37 |
from stripe.params.climate._supplier_retrieve_params import ( |
| 38 |
SupplierRetrieveParams as SupplierRetrieveParams, |
| 39 |
) |
| 40 |
|
| 41 |
# name -> (import_target, is_submodule) |
| 42 |
_import_map = { |
| 43 |
"OrderCancelParams": ("stripe.params.climate._order_cancel_params", False), |
| 44 |
"OrderCreateParams": ("stripe.params.climate._order_create_params", False), |
| 45 |
"OrderCreateParamsBeneficiary": ( |
| 46 |
"stripe.params.climate._order_create_params", |
| 47 |
False, |
| 48 |
), |
| 49 |
"OrderListParams": ("stripe.params.climate._order_list_params", False), |
| 50 |
"OrderModifyParams": ("stripe.params.climate._order_modify_params", False), |
| 51 |
"OrderModifyParamsBeneficiary": ( |
| 52 |
"stripe.params.climate._order_modify_params", |
| 53 |
False, |
| 54 |
), |
| 55 |
"OrderRetrieveParams": ( |
| 56 |
"stripe.params.climate._order_retrieve_params", |
| 57 |
False, |
| 58 |
), |
| 59 |
"OrderUpdateParams": ("stripe.params.climate._order_update_params", False), |
| 60 |
"OrderUpdateParamsBeneficiary": ( |
| 61 |
"stripe.params.climate._order_update_params", |
| 62 |
False, |
| 63 |
), |
| 64 |
"ProductListParams": ("stripe.params.climate._product_list_params", False), |
| 65 |
"ProductRetrieveParams": ( |
| 66 |
"stripe.params.climate._product_retrieve_params", |
| 67 |
False, |
| 68 |
), |
| 69 |
"SupplierListParams": ( |
| 70 |
"stripe.params.climate._supplier_list_params", |
| 71 |
False, |
| 72 |
), |
| 73 |
"SupplierRetrieveParams": ( |
| 74 |
"stripe.params.climate._supplier_retrieve_params", |
| 75 |
False, |
| 76 |
), |
| 77 |
} |
| 78 |
if not TYPE_CHECKING: |
| 79 |
|
| 80 |
def __getattr__(name): |
| 81 |
try: |
| 82 |
target, is_submodule = _import_map[name] |
| 83 |
module = import_module(target) |
| 84 |
if is_submodule: |
| 85 |
return module |
| 86 |
|
| 87 |
return getattr( |
| 88 |
module, |
| 89 |
name, |
| 90 |
) |
| 91 |
except KeyError: |
| 92 |
raise AttributeError() |