Skip to content

Commit 45bf092

Browse files
committed
[Librarian] Regenerated @ 437c39e3f150e78058f5afb3ef0672e89fc59ec0
1 parent 33363be commit 45bf092

File tree

44 files changed

+269
-64
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

44 files changed

+269
-64
lines changed

CHANGES.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,12 @@ twilio-python Changelog
33

44
Here you can see the full list of changes between each twilio-python release.
55

6+
[2023-12-01] Version 8.10.3
7+
---------------------------
8+
**Verify**
9+
- Add `VerifyEventSubscriptionEnabled` parameter to service create and update endpoints.
10+
11+
612
[2023-11-17] Version 8.10.2
713
---------------------------
814
**Library - Chore**

twilio/rest/accounts/v1/safelist.py

Lines changed: 59 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
"""
1414

1515

16-
from typing import Any, Dict, Optional
16+
from typing import Any, Dict, Optional, Union
1717
from twilio.base import values
1818

1919
from twilio.base.instance_resource import InstanceResource
@@ -100,23 +100,77 @@ async def create_async(self, phone_number: str) -> SafelistInstance:
100100

101101
return SafelistInstance(self._version, payload)
102102

103-
def fetch(self) -> SafelistInstance:
103+
def delete(self, phone_number: Union[str, object] = values.unset) -> bool:
104+
"""
105+
Asynchronously delete the SafelistInstance
106+
107+
:param phone_number: The phone number to be removed from SafeList. Phone numbers must be in [E.164 format](https://www.twilio.com/docs/glossary/what-e164).
108+
:returns: True if delete succeeds, False otherwise
109+
"""
110+
111+
params = values.of(
112+
{
113+
"PhoneNumber": phone_number,
114+
}
115+
)
116+
return self._version.delete(method="DELETE", uri=self._uri, params=params)
117+
118+
async def delete_async(
119+
self, phone_number: Union[str, object] = values.unset
120+
) -> bool:
121+
"""
122+
Asynchronously delete the SafelistInstance
123+
124+
:param phone_number: The phone number to be removed from SafeList. Phone numbers must be in [E.164 format](https://www.twilio.com/docs/glossary/what-e164).
125+
:returns: True if delete succeeds, False otherwise
126+
"""
127+
128+
params = values.of(
129+
{
130+
"PhoneNumber": phone_number,
131+
}
132+
)
133+
return await self._version.delete_async(
134+
method="DELETE", uri=self._uri, params=params
135+
)
136+
137+
def fetch(
138+
self, phone_number: Union[str, object] = values.unset
139+
) -> SafelistInstance:
104140
"""
105141
Asynchronously fetch the SafelistInstance
106142
143+
:param phone_number: The phone number to be fetched from SafeList. Phone numbers must be in [E.164 format](https://www.twilio.com/docs/glossary/what-e164).
107144
:returns: The fetched SafelistInstance
108145
"""
109-
payload = self._version.fetch(method="GET", uri=self._uri)
146+
147+
params = values.of(
148+
{
149+
"PhoneNumber": phone_number,
150+
}
151+
)
152+
payload = self._version.fetch(method="GET", uri=self._uri, params=params)
110153

111154
return SafelistInstance(self._version, payload)
112155

113-
async def fetch_async(self) -> SafelistInstance:
156+
async def fetch_async(
157+
self, phone_number: Union[str, object] = values.unset
158+
) -> SafelistInstance:
114159
"""
115160
Asynchronously fetch the SafelistInstance
116161
162+
:param phone_number: The phone number to be fetched from SafeList. Phone numbers must be in [E.164 format](https://www.twilio.com/docs/glossary/what-e164).
117163
:returns: The fetched SafelistInstance
118164
"""
119-
payload = await self._version.fetch_async(method="GET", uri=self._uri)
165+
166+
params = values.of(
167+
{
168+
"PhoneNumber": phone_number,
169+
}
170+
)
171+
payload = await self._version.fetch_async(
172+
method="GET", uri=self._uri, params=params
173+
)
120174

121175
return SafelistInstance(self._version, payload)
122176

twilio/rest/api/v2010/account/balance.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,8 +70,10 @@ def fetch(self) -> BalanceInstance:
7070
"""
7171
Asynchronously fetch the BalanceInstance
7272
73+
7374
:returns: The fetched BalanceInstance
7475
"""
76+
7577
payload = self._version.fetch(method="GET", uri=self._uri)
7678

7779
return BalanceInstance(
@@ -82,8 +84,10 @@ async def fetch_async(self) -> BalanceInstance:
8284
"""
8385
Asynchronously fetch the BalanceInstance
8486
87+
8588
:returns: The fetched BalanceInstance
8689
"""
90+
8791
payload = await self._version.fetch_async(method="GET", uri=self._uri)
8892

8993
return BalanceInstance(

twilio/rest/api/v2010/account/message/__init__.py

Lines changed: 7 additions & 7 deletions
Large diffs are not rendered by default.

twilio/rest/chat/v2/service/channel/__init__.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -620,6 +620,7 @@ def create(
620620
"X-Twilio-Webhook-Enabled": x_twilio_webhook_enabled,
621621
}
622622
)
623+
623624
payload = self._version.create(
624625
method="POST", uri=self._uri, data=data, headers=headers
625626
)
@@ -671,6 +672,7 @@ async def create_async(
671672
"X-Twilio-Webhook-Enabled": x_twilio_webhook_enabled,
672673
}
673674
)
675+
674676
payload = await self._version.create_async(
675677
method="POST", uri=self._uri, data=data, headers=headers
676678
)

twilio/rest/chat/v2/service/channel/member.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -549,6 +549,7 @@ def create(
549549
"X-Twilio-Webhook-Enabled": x_twilio_webhook_enabled,
550550
}
551551
)
552+
552553
payload = self._version.create(
553554
method="POST", uri=self._uri, data=data, headers=headers
554555
)
@@ -605,6 +606,7 @@ async def create_async(
605606
"X-Twilio-Webhook-Enabled": x_twilio_webhook_enabled,
606607
}
607608
)
609+
608610
payload = await self._version.create_async(
609611
method="POST", uri=self._uri, data=data, headers=headers
610612
)

twilio/rest/chat/v2/service/channel/message.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -551,6 +551,7 @@ def create(
551551
"X-Twilio-Webhook-Enabled": x_twilio_webhook_enabled,
552552
}
553553
)
554+
554555
payload = self._version.create(
555556
method="POST", uri=self._uri, data=data, headers=headers
556557
)
@@ -605,6 +606,7 @@ async def create_async(
605606
"X-Twilio-Webhook-Enabled": x_twilio_webhook_enabled,
606607
}
607608
)
609+
608610
payload = await self._version.create_async(
609611
method="POST", uri=self._uri, data=data, headers=headers
610612
)

twilio/rest/chat/v2/service/user/__init__.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -489,6 +489,7 @@ def create(
489489
"X-Twilio-Webhook-Enabled": x_twilio_webhook_enabled,
490490
}
491491
)
492+
492493
payload = self._version.create(
493494
method="POST", uri=self._uri, data=data, headers=headers
494495
)
@@ -531,6 +532,7 @@ async def create_async(
531532
"X-Twilio-Webhook-Enabled": x_twilio_webhook_enabled,
532533
}
533534
)
535+
534536
payload = await self._version.create_async(
535537
method="POST", uri=self._uri, data=data, headers=headers
536538
)

twilio/rest/content/v1/content/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ class ContentInstance(InstanceResource):
3434
:ivar friendly_name: A string name used to describe the Content resource. Not visible to the end recipient.
3535
:ivar language: Two-letter (ISO 639-1) language code (e.g., en) identifying the language the Content resource is in.
3636
:ivar variables: Defines the default placeholder values for variables included in the Content resource. e.g. {\"1\": \"Customer_Name\"}.
37-
:ivar types: The [Content types](https://www.twilio.com/docs/content-api/content-types-overview) (e.g. twilio/text) for this Content resource.
37+
:ivar types: The [Content types](https://www.twilio.com/docs/content/content-types-overview) (e.g. twilio/text) for this Content resource.
3838
:ivar url: The URL of the resource, relative to `https://content.twilio.com`.
3939
:ivar links: A list of links related to the Content resource, such as approval_fetch and approval_create
4040
"""

twilio/rest/content/v1/content_and_approvals.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ class ContentAndApprovalsInstance(InstanceResource):
3333
:ivar friendly_name: A string name used to describe the Content resource. Not visible to the end recipient.
3434
:ivar language: Two-letter (ISO 639-1) language code (e.g., en) identifying the language the Content resource is in.
3535
:ivar variables: Defines the default placeholder values for variables included in the Content resource. e.g. {\"1\": \"Customer_Name\"}.
36-
:ivar types: The [Content types](https://www.twilio.com/docs/content-api/content-types-overview) (e.g. twilio/text) for this Content resource.
36+
:ivar types: The [Content types](https://www.twilio.com/docs/content/content-types-overview) (e.g. twilio/text) for this Content resource.
3737
:ivar approval_requests: The submitted information and approval request status of the Content resource.
3838
"""
3939

0 commit comments

Comments
 (0)