Debian Codegraph @

stripe/params/entitlements/__init__.py

raw
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.entitlements._active_entitlement_list_params import (
8 ActiveEntitlementListParams as ActiveEntitlementListParams,
9 )
10 from stripe.params.entitlements._active_entitlement_retrieve_params import (
11 ActiveEntitlementRetrieveParams as ActiveEntitlementRetrieveParams,
12 )
13 from stripe.params.entitlements._feature_create_params import (
14 FeatureCreateParams as FeatureCreateParams,
15 )
16 from stripe.params.entitlements._feature_list_params import (
17 FeatureListParams as FeatureListParams,
18 )
19 from stripe.params.entitlements._feature_modify_params import (
20 FeatureModifyParams as FeatureModifyParams,
21 )
22 from stripe.params.entitlements._feature_retrieve_params import (
23 FeatureRetrieveParams as FeatureRetrieveParams,
24 )
25 from stripe.params.entitlements._feature_update_params import (
26 FeatureUpdateParams as FeatureUpdateParams,
27 )
28
29 # name -> (import_target, is_submodule)
30 _import_map = {
31 "ActiveEntitlementListParams": (
32 "stripe.params.entitlements._active_entitlement_list_params",
33 False,
34 ),
35 "ActiveEntitlementRetrieveParams": (
36 "stripe.params.entitlements._active_entitlement_retrieve_params",
37 False,
38 ),
39 "FeatureCreateParams": (
40 "stripe.params.entitlements._feature_create_params",
41 False,
42 ),
43 "FeatureListParams": (
44 "stripe.params.entitlements._feature_list_params",
45 False,
46 ),
47 "FeatureModifyParams": (
48 "stripe.params.entitlements._feature_modify_params",
49 False,
50 ),
51 "FeatureRetrieveParams": (
52 "stripe.params.entitlements._feature_retrieve_params",
53 False,
54 ),
55 "FeatureUpdateParams": (
56 "stripe.params.entitlements._feature_update_params",
57 False,
58 ),
59 }
60 if not TYPE_CHECKING:
61
62 def __getattr__(name):
63 try:
64 target, is_submodule = _import_map[name]
65 module = import_module(target)
66 if is_submodule:
67 return module
68
69 return getattr(
70 module,
71 name,
72 )
73 except KeyError:
74 raise AttributeError()