dodopayments 1.44.0__py3-none-any.whl → 1.49.0__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of dodopayments might be problematic. Click here for more details.

Files changed (49) hide show
  1. dodopayments/_client.py +20 -0
  2. dodopayments/_version.py +1 -1
  3. dodopayments/pagination.py +64 -1
  4. dodopayments/resources/__init__.py +28 -0
  5. dodopayments/resources/discounts.py +24 -0
  6. dodopayments/resources/products/products.py +17 -1
  7. dodopayments/resources/subscriptions.py +4 -0
  8. dodopayments/resources/webhooks/__init__.py +33 -0
  9. dodopayments/resources/webhooks/headers.py +255 -0
  10. dodopayments/resources/webhooks/webhooks.py +755 -0
  11. dodopayments/resources/your_webhook_url.py +224 -0
  12. dodopayments/types/__init__.py +18 -1
  13. dodopayments/types/addon_cart_response_item_param.py +13 -0
  14. dodopayments/types/customer_limited_details_param.py +18 -0
  15. dodopayments/types/customer_request_param.py +2 -2
  16. dodopayments/types/discount.py +7 -0
  17. dodopayments/types/discount_create_params.py +7 -0
  18. dodopayments/types/discount_update_params.py +7 -0
  19. dodopayments/types/dispute_param.py +45 -0
  20. dodopayments/types/get_dispute_param.py +52 -0
  21. dodopayments/types/license_key_param.py +53 -0
  22. dodopayments/types/new_customer_param.py +16 -0
  23. dodopayments/types/payment_param.py +131 -0
  24. dodopayments/types/product.py +4 -1
  25. dodopayments/types/product_create_params.py +4 -1
  26. dodopayments/types/product_list_response.py +4 -1
  27. dodopayments/types/product_update_params.py +4 -1
  28. dodopayments/types/refund_param.py +42 -0
  29. dodopayments/types/subscription.py +3 -0
  30. dodopayments/types/subscription_list_response.py +3 -0
  31. dodopayments/types/subscription_param.py +97 -0
  32. dodopayments/types/subscription_update_params.py +2 -0
  33. dodopayments/types/webhook_create_params.py +40 -0
  34. dodopayments/types/webhook_create_response.py +42 -0
  35. dodopayments/types/webhook_list_params.py +16 -0
  36. dodopayments/types/webhook_list_response.py +42 -0
  37. dodopayments/types/webhook_retrieve_response.py +42 -0
  38. dodopayments/types/webhook_retrieve_secret_response.py +9 -0
  39. dodopayments/types/webhook_update_params.py +33 -0
  40. dodopayments/types/webhook_update_response.py +42 -0
  41. dodopayments/types/webhooks/__init__.py +6 -0
  42. dodopayments/types/webhooks/header_retrieve_response.py +15 -0
  43. dodopayments/types/webhooks/header_update_params.py +13 -0
  44. dodopayments/types/your_webhook_url_create_params.py +66 -0
  45. {dodopayments-1.44.0.dist-info → dodopayments-1.49.0.dist-info}/METADATA +1 -1
  46. {dodopayments-1.44.0.dist-info → dodopayments-1.49.0.dist-info}/RECORD +48 -24
  47. dodopayments/types/create_new_customer_param.py +0 -23
  48. {dodopayments-1.44.0.dist-info → dodopayments-1.49.0.dist-info}/WHEEL +0 -0
  49. {dodopayments-1.44.0.dist-info → dodopayments-1.49.0.dist-info}/licenses/LICENSE +0 -0
@@ -0,0 +1,131 @@
1
+ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ from __future__ import annotations
4
+
5
+ from typing import Dict, Union, Iterable, Optional
6
+ from datetime import datetime
7
+ from typing_extensions import Required, Annotated, TypedDict
8
+
9
+ from .._utils import PropertyInfo
10
+ from .currency import Currency
11
+ from .country_code import CountryCode
12
+ from .refund_param import RefundParam
13
+ from .dispute_param import DisputeParam
14
+ from .intent_status import IntentStatus
15
+ from .billing_address_param import BillingAddressParam
16
+ from .customer_limited_details_param import CustomerLimitedDetailsParam
17
+
18
+ __all__ = ["PaymentParam", "ProductCart"]
19
+
20
+
21
+ class ProductCart(TypedDict, total=False):
22
+ product_id: Required[str]
23
+
24
+ quantity: Required[int]
25
+
26
+
27
+ class PaymentParam(TypedDict, total=False):
28
+ billing: Required[BillingAddressParam]
29
+ """Billing address details for payments"""
30
+
31
+ brand_id: Required[str]
32
+ """brand id this payment belongs to"""
33
+
34
+ business_id: Required[str]
35
+ """Identifier of the business associated with the payment"""
36
+
37
+ created_at: Required[Annotated[Union[str, datetime], PropertyInfo(format="iso8601")]]
38
+ """Timestamp when the payment was created"""
39
+
40
+ currency: Required[Currency]
41
+ """Currency used for the payment"""
42
+
43
+ customer: Required[CustomerLimitedDetailsParam]
44
+ """Details about the customer who made the payment"""
45
+
46
+ digital_products_delivered: Required[bool]
47
+ """brand id this payment belongs to"""
48
+
49
+ disputes: Required[Iterable[DisputeParam]]
50
+ """List of disputes associated with this payment"""
51
+
52
+ metadata: Required[Dict[str, str]]
53
+ """Additional custom data associated with the payment"""
54
+
55
+ payment_id: Required[str]
56
+ """Unique identifier for the payment"""
57
+
58
+ refunds: Required[Iterable[RefundParam]]
59
+ """List of refunds issued for this payment"""
60
+
61
+ settlement_amount: Required[int]
62
+ """
63
+ The amount that will be credited to your Dodo balance after currency conversion
64
+ and processing. Especially relevant for adaptive pricing where the customer's
65
+ payment currency differs from your settlement currency.
66
+ """
67
+
68
+ settlement_currency: Required[Currency]
69
+ """
70
+ The currency in which the settlement_amount will be credited to your Dodo
71
+ balance. This may differ from the customer's payment currency in adaptive
72
+ pricing scenarios.
73
+ """
74
+
75
+ total_amount: Required[int]
76
+ """
77
+ Total amount charged to the customer including tax, in smallest currency unit
78
+ (e.g. cents)
79
+ """
80
+
81
+ card_issuing_country: Optional[CountryCode]
82
+ """ISO2 country code of the card"""
83
+
84
+ card_last_four: Optional[str]
85
+ """The last four digits of the card"""
86
+
87
+ card_network: Optional[str]
88
+ """Card network like VISA, MASTERCARD etc."""
89
+
90
+ card_type: Optional[str]
91
+ """The type of card DEBIT or CREDIT"""
92
+
93
+ discount_id: Optional[str]
94
+ """The discount id if discount is applied"""
95
+
96
+ error_code: Optional[str]
97
+ """An error code if the payment failed"""
98
+
99
+ error_message: Optional[str]
100
+ """An error message if the payment failed"""
101
+
102
+ payment_link: Optional[str]
103
+ """Checkout URL"""
104
+
105
+ payment_method: Optional[str]
106
+ """Payment method used by customer (e.g. "card", "bank_transfer")"""
107
+
108
+ payment_method_type: Optional[str]
109
+ """Specific type of payment method (e.g. "visa", "mastercard")"""
110
+
111
+ product_cart: Optional[Iterable[ProductCart]]
112
+ """List of products purchased in a one-time payment"""
113
+
114
+ settlement_tax: Optional[int]
115
+ """
116
+ This represents the portion of settlement_amount that corresponds to taxes
117
+ collected. Especially relevant for adaptive pricing where the tax component must
118
+ be tracked separately in your Dodo balance.
119
+ """
120
+
121
+ status: Optional[IntentStatus]
122
+ """Current status of the payment intent"""
123
+
124
+ subscription_id: Optional[str]
125
+ """Identifier of the subscription if payment is part of a subscription"""
126
+
127
+ tax: Optional[int]
128
+ """Amount of tax collected in smallest currency unit (e.g. cents)"""
129
+
130
+ updated_at: Annotated[Union[str, datetime, None], PropertyInfo(format="iso8601")]
131
+ """Timestamp when the payment was last updated"""
@@ -1,6 +1,6 @@
1
1
  # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
2
 
3
- from typing import List, Optional
3
+ from typing import Dict, List, Optional
4
4
  from datetime import datetime
5
5
 
6
6
  from .price import Price
@@ -45,6 +45,9 @@ class Product(BaseModel):
45
45
  license_key_enabled: bool
46
46
  """Indicates whether the product requires a license key."""
47
47
 
48
+ metadata: Dict[str, str]
49
+ """Additional custom data associated with the product"""
50
+
48
51
  price: Price
49
52
  """Pricing information for the product."""
50
53
 
@@ -2,7 +2,7 @@
2
2
 
3
3
  from __future__ import annotations
4
4
 
5
- from typing import List, Optional
5
+ from typing import Dict, List, Optional
6
6
  from typing_extensions import Required, TypedDict
7
7
 
8
8
  from .price_param import PriceParam
@@ -49,6 +49,9 @@ class ProductCreateParams(TypedDict, total=False):
49
49
  When true, generates and sends a license key to your customer. Defaults to false
50
50
  """
51
51
 
52
+ metadata: Dict[str, str]
53
+ """Additional metadata for the product"""
54
+
52
55
  name: Optional[str]
53
56
  """Optional name of the product"""
54
57
 
@@ -1,6 +1,6 @@
1
1
  # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
2
 
3
- from typing import Optional
3
+ from typing import Dict, Optional
4
4
  from datetime import datetime
5
5
 
6
6
  from .price import Price
@@ -21,6 +21,9 @@ class ProductListResponse(BaseModel):
21
21
  is_recurring: bool
22
22
  """Indicates if the product is recurring (e.g., subscriptions)."""
23
23
 
24
+ metadata: Dict[str, str]
25
+ """Additional custom data associated with the product"""
26
+
24
27
  product_id: str
25
28
  """Unique identifier for the product."""
26
29
 
@@ -2,7 +2,7 @@
2
2
 
3
3
  from __future__ import annotations
4
4
 
5
- from typing import List, Optional
5
+ from typing import Dict, List, Optional
6
6
  from typing_extensions import TypedDict
7
7
 
8
8
  from .price_param import PriceParam
@@ -55,6 +55,9 @@ class ProductUpdateParams(TypedDict, total=False):
55
55
  limit, activation message) become applicable.
56
56
  """
57
57
 
58
+ metadata: Optional[Dict[str, str]]
59
+ """Additional metadata for the product"""
60
+
58
61
  name: Optional[str]
59
62
  """Name of the product, optional and must be at most 100 characters."""
60
63
 
@@ -0,0 +1,42 @@
1
+ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ from __future__ import annotations
4
+
5
+ from typing import Union, Optional
6
+ from datetime import datetime
7
+ from typing_extensions import Required, Annotated, TypedDict
8
+
9
+ from .._utils import PropertyInfo
10
+ from .currency import Currency
11
+ from .refund_status import RefundStatus
12
+
13
+ __all__ = ["RefundParam"]
14
+
15
+
16
+ class RefundParam(TypedDict, total=False):
17
+ business_id: Required[str]
18
+ """The unique identifier of the business issuing the refund."""
19
+
20
+ created_at: Required[Annotated[Union[str, datetime], PropertyInfo(format="iso8601")]]
21
+ """The timestamp of when the refund was created in UTC."""
22
+
23
+ is_partial: Required[bool]
24
+ """If true the refund is a partial refund"""
25
+
26
+ payment_id: Required[str]
27
+ """The unique identifier of the payment associated with the refund."""
28
+
29
+ refund_id: Required[str]
30
+ """The unique identifier of the refund."""
31
+
32
+ status: Required[RefundStatus]
33
+ """The current status of the refund."""
34
+
35
+ amount: Optional[int]
36
+ """The refunded amount."""
37
+
38
+ currency: Optional[Currency]
39
+ """The currency of the refund, represented as an ISO 4217 currency code."""
40
+
41
+ reason: Optional[str]
42
+ """The reason provided for the refund, if any. Optional."""
@@ -87,5 +87,8 @@ class Subscription(BaseModel):
87
87
  cancelled_at: Optional[datetime] = None
88
88
  """Cancelled timestamp if the subscription is cancelled"""
89
89
 
90
+ discount_cycles_remaining: Optional[int] = None
91
+ """Number of remaining discount cycles if discount is applied"""
92
+
90
93
  discount_id: Optional[str] = None
91
94
  """The discount id if discount is applied"""
@@ -83,5 +83,8 @@ class SubscriptionListResponse(BaseModel):
83
83
  cancelled_at: Optional[datetime] = None
84
84
  """Cancelled timestamp if the subscription is cancelled"""
85
85
 
86
+ discount_cycles_remaining: Optional[int] = None
87
+ """Number of remaining discount cycles if discount is applied"""
88
+
86
89
  discount_id: Optional[str] = None
87
90
  """The discount id if discount is applied"""
@@ -0,0 +1,97 @@
1
+ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ from __future__ import annotations
4
+
5
+ from typing import Dict, Union, Iterable, Optional
6
+ from datetime import datetime
7
+ from typing_extensions import Required, Annotated, TypedDict
8
+
9
+ from .._utils import PropertyInfo
10
+ from .currency import Currency
11
+ from .time_interval import TimeInterval
12
+ from .subscription_status import SubscriptionStatus
13
+ from .billing_address_param import BillingAddressParam
14
+ from .addon_cart_response_item_param import AddonCartResponseItemParam
15
+ from .customer_limited_details_param import CustomerLimitedDetailsParam
16
+
17
+ __all__ = ["SubscriptionParam"]
18
+
19
+
20
+ class SubscriptionParam(TypedDict, total=False):
21
+ addons: Required[Iterable[AddonCartResponseItemParam]]
22
+ """Addons associated with this subscription"""
23
+
24
+ billing: Required[BillingAddressParam]
25
+ """Billing address details for payments"""
26
+
27
+ cancel_at_next_billing_date: Required[bool]
28
+ """Indicates if the subscription will cancel at the next billing date"""
29
+
30
+ created_at: Required[Annotated[Union[str, datetime], PropertyInfo(format="iso8601")]]
31
+ """Timestamp when the subscription was created"""
32
+
33
+ currency: Required[Currency]
34
+ """Currency used for the subscription payments"""
35
+
36
+ customer: Required[CustomerLimitedDetailsParam]
37
+ """Customer details associated with the subscription"""
38
+
39
+ metadata: Required[Dict[str, str]]
40
+ """Additional custom data associated with the subscription"""
41
+
42
+ next_billing_date: Required[Annotated[Union[str, datetime], PropertyInfo(format="iso8601")]]
43
+ """Timestamp of the next scheduled billing.
44
+
45
+ Indicates the end of current billing period
46
+ """
47
+
48
+ on_demand: Required[bool]
49
+ """Wether the subscription is on-demand or not"""
50
+
51
+ payment_frequency_count: Required[int]
52
+ """Number of payment frequency intervals"""
53
+
54
+ payment_frequency_interval: Required[TimeInterval]
55
+ """Time interval for payment frequency (e.g. month, year)"""
56
+
57
+ previous_billing_date: Required[Annotated[Union[str, datetime], PropertyInfo(format="iso8601")]]
58
+ """Timestamp of the last payment. Indicates the start of current billing period"""
59
+
60
+ product_id: Required[str]
61
+ """Identifier of the product associated with this subscription"""
62
+
63
+ quantity: Required[int]
64
+ """Number of units/items included in the subscription"""
65
+
66
+ recurring_pre_tax_amount: Required[int]
67
+ """
68
+ Amount charged before tax for each recurring payment in smallest currency unit
69
+ (e.g. cents)
70
+ """
71
+
72
+ status: Required[SubscriptionStatus]
73
+ """Current status of the subscription"""
74
+
75
+ subscription_id: Required[str]
76
+ """Unique identifier for the subscription"""
77
+
78
+ subscription_period_count: Required[int]
79
+ """Number of subscription period intervals"""
80
+
81
+ subscription_period_interval: Required[TimeInterval]
82
+ """Time interval for the subscription period (e.g. month, year)"""
83
+
84
+ tax_inclusive: Required[bool]
85
+ """Indicates if the recurring_pre_tax_amount is tax inclusive"""
86
+
87
+ trial_period_days: Required[int]
88
+ """Number of days in the trial period (0 if no trial)"""
89
+
90
+ cancelled_at: Annotated[Union[str, datetime, None], PropertyInfo(format="iso8601")]
91
+ """Cancelled timestamp if the subscription is cancelled"""
92
+
93
+ discount_cycles_remaining: Optional[int]
94
+ """Number of remaining discount cycles if discount is applied"""
95
+
96
+ discount_id: Optional[str]
97
+ """The discount id if discount is applied"""
@@ -22,6 +22,8 @@ class SubscriptionUpdateParams(TypedDict, total=False):
22
22
 
23
23
  metadata: Optional[Dict[str, str]]
24
24
 
25
+ next_billing_date: Annotated[Union[str, datetime, None], PropertyInfo(format="iso8601")]
26
+
25
27
  status: Optional[SubscriptionStatus]
26
28
 
27
29
  tax_id: Optional[str]
@@ -0,0 +1,40 @@
1
+ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ from __future__ import annotations
4
+
5
+ from typing import Dict, List, Optional
6
+ from typing_extensions import Required, TypedDict
7
+
8
+ from .webhook_event_type import WebhookEventType
9
+
10
+ __all__ = ["WebhookCreateParams"]
11
+
12
+
13
+ class WebhookCreateParams(TypedDict, total=False):
14
+ url: Required[str]
15
+ """Url of the webhook"""
16
+
17
+ description: Optional[str]
18
+
19
+ disabled: Optional[bool]
20
+ """Create the webhook in a disabled state.
21
+
22
+ Default is false
23
+ """
24
+
25
+ filter_types: List[WebhookEventType]
26
+ """Filter events to the webhook.
27
+
28
+ Webhook event will only be sent for events in the list.
29
+ """
30
+
31
+ headers: Optional[Dict[str, str]]
32
+ """Custom headers to be passed"""
33
+
34
+ idempotency_key: Optional[str]
35
+ """The request's idempotency key"""
36
+
37
+ metadata: Optional[Dict[str, str]]
38
+ """Metadata to be passed to the webhook Defaut is {}"""
39
+
40
+ rate_limit: Optional[int]
@@ -0,0 +1,42 @@
1
+ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ from typing import Dict, List, Optional
4
+
5
+ from .._models import BaseModel
6
+
7
+ __all__ = ["WebhookCreateResponse"]
8
+
9
+
10
+ class WebhookCreateResponse(BaseModel):
11
+ id: str
12
+ """The webhook's ID."""
13
+
14
+ created_at: str
15
+ """Created at timestamp"""
16
+
17
+ description: str
18
+ """An example webhook name."""
19
+
20
+ metadata: Dict[str, str]
21
+ """Metadata of the webhook"""
22
+
23
+ updated_at: str
24
+ """Updated at timestamp"""
25
+
26
+ url: str
27
+ """Url endpoint of the webhook"""
28
+
29
+ disabled: Optional[bool] = None
30
+ """Status of the webhook.
31
+
32
+ If true, events are not sent
33
+ """
34
+
35
+ filter_types: Optional[List[str]] = None
36
+ """Filter events to the webhook.
37
+
38
+ Webhook event will only be sent for events in the list.
39
+ """
40
+
41
+ rate_limit: Optional[int] = None
42
+ """Configured rate limit"""
@@ -0,0 +1,16 @@
1
+ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ from __future__ import annotations
4
+
5
+ from typing import Optional
6
+ from typing_extensions import TypedDict
7
+
8
+ __all__ = ["WebhookListParams"]
9
+
10
+
11
+ class WebhookListParams(TypedDict, total=False):
12
+ iterator: Optional[str]
13
+ """The iterator returned from a prior invocation"""
14
+
15
+ limit: Optional[int]
16
+ """Limit the number of returned items"""
@@ -0,0 +1,42 @@
1
+ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ from typing import Dict, List, Optional
4
+
5
+ from .._models import BaseModel
6
+
7
+ __all__ = ["WebhookListResponse"]
8
+
9
+
10
+ class WebhookListResponse(BaseModel):
11
+ id: str
12
+ """The webhook's ID."""
13
+
14
+ created_at: str
15
+ """Created at timestamp"""
16
+
17
+ description: str
18
+ """An example webhook name."""
19
+
20
+ metadata: Dict[str, str]
21
+ """Metadata of the webhook"""
22
+
23
+ updated_at: str
24
+ """Updated at timestamp"""
25
+
26
+ url: str
27
+ """Url endpoint of the webhook"""
28
+
29
+ disabled: Optional[bool] = None
30
+ """Status of the webhook.
31
+
32
+ If true, events are not sent
33
+ """
34
+
35
+ filter_types: Optional[List[str]] = None
36
+ """Filter events to the webhook.
37
+
38
+ Webhook event will only be sent for events in the list.
39
+ """
40
+
41
+ rate_limit: Optional[int] = None
42
+ """Configured rate limit"""
@@ -0,0 +1,42 @@
1
+ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ from typing import Dict, List, Optional
4
+
5
+ from .._models import BaseModel
6
+
7
+ __all__ = ["WebhookRetrieveResponse"]
8
+
9
+
10
+ class WebhookRetrieveResponse(BaseModel):
11
+ id: str
12
+ """The webhook's ID."""
13
+
14
+ created_at: str
15
+ """Created at timestamp"""
16
+
17
+ description: str
18
+ """An example webhook name."""
19
+
20
+ metadata: Dict[str, str]
21
+ """Metadata of the webhook"""
22
+
23
+ updated_at: str
24
+ """Updated at timestamp"""
25
+
26
+ url: str
27
+ """Url endpoint of the webhook"""
28
+
29
+ disabled: Optional[bool] = None
30
+ """Status of the webhook.
31
+
32
+ If true, events are not sent
33
+ """
34
+
35
+ filter_types: Optional[List[str]] = None
36
+ """Filter events to the webhook.
37
+
38
+ Webhook event will only be sent for events in the list.
39
+ """
40
+
41
+ rate_limit: Optional[int] = None
42
+ """Configured rate limit"""
@@ -0,0 +1,9 @@
1
+ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ from .._models import BaseModel
4
+
5
+ __all__ = ["WebhookRetrieveSecretResponse"]
6
+
7
+
8
+ class WebhookRetrieveSecretResponse(BaseModel):
9
+ secret: str
@@ -0,0 +1,33 @@
1
+ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ from __future__ import annotations
4
+
5
+ from typing import Dict, List, Optional
6
+ from typing_extensions import TypedDict
7
+
8
+ from .webhook_event_type import WebhookEventType
9
+
10
+ __all__ = ["WebhookUpdateParams"]
11
+
12
+
13
+ class WebhookUpdateParams(TypedDict, total=False):
14
+ description: Optional[str]
15
+ """Description of the webhook"""
16
+
17
+ disabled: Optional[bool]
18
+ """To Disable the endpoint, set it to true."""
19
+
20
+ filter_types: Optional[List[WebhookEventType]]
21
+ """Filter events to the endpoint.
22
+
23
+ Webhook event will only be sent for events in the list.
24
+ """
25
+
26
+ metadata: Optional[Dict[str, str]]
27
+ """Metadata"""
28
+
29
+ rate_limit: Optional[int]
30
+ """Rate limit"""
31
+
32
+ url: Optional[str]
33
+ """Url endpoint"""
@@ -0,0 +1,42 @@
1
+ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ from typing import Dict, List, Optional
4
+
5
+ from .._models import BaseModel
6
+
7
+ __all__ = ["WebhookUpdateResponse"]
8
+
9
+
10
+ class WebhookUpdateResponse(BaseModel):
11
+ id: str
12
+ """The webhook's ID."""
13
+
14
+ created_at: str
15
+ """Created at timestamp"""
16
+
17
+ description: str
18
+ """An example webhook name."""
19
+
20
+ metadata: Dict[str, str]
21
+ """Metadata of the webhook"""
22
+
23
+ updated_at: str
24
+ """Updated at timestamp"""
25
+
26
+ url: str
27
+ """Url endpoint of the webhook"""
28
+
29
+ disabled: Optional[bool] = None
30
+ """Status of the webhook.
31
+
32
+ If true, events are not sent
33
+ """
34
+
35
+ filter_types: Optional[List[str]] = None
36
+ """Filter events to the webhook.
37
+
38
+ Webhook event will only be sent for events in the list.
39
+ """
40
+
41
+ rate_limit: Optional[int] = None
42
+ """Configured rate limit"""
@@ -0,0 +1,6 @@
1
+ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ from __future__ import annotations
4
+
5
+ from .header_update_params import HeaderUpdateParams as HeaderUpdateParams
6
+ from .header_retrieve_response import HeaderRetrieveResponse as HeaderRetrieveResponse
@@ -0,0 +1,15 @@
1
+ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ from typing import Dict, List
4
+
5
+ from ..._models import BaseModel
6
+
7
+ __all__ = ["HeaderRetrieveResponse"]
8
+
9
+
10
+ class HeaderRetrieveResponse(BaseModel):
11
+ headers: Dict[str, str]
12
+ """List of headers configured"""
13
+
14
+ sensitive: List[str]
15
+ """Sensitive headers without the value"""