Skip to content

Commit 9372769

Browse files
authored
Merge branch 'main' into snyk-fix-bf66cc118de56e3945f4a6f0bd5b44ab
2 parents 1142702 + 317a5bb commit 9372769

File tree

561 files changed

+32951
-9019
lines changed

Some content is hidden

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

561 files changed

+32951
-9019
lines changed
Lines changed: 69 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,69 @@
1+
name: Bug report
2+
description: Report a bug with the twilio-python helper library.
3+
title: "[BUG] Describe the issue briefly"
4+
labels: "type: bug"
5+
body:
6+
- type: markdown
7+
attributes:
8+
value: |
9+
Thank you for reporting a bug in the twilio-python helper library. Please provide the details below to help us investigate and resolve the issue.
10+
11+
- type: textarea
12+
attributes:
13+
label: Describe the bug
14+
description: Provide a clear and concise description of the issue.
15+
placeholder: A clear and concise description of the bug.
16+
validations:
17+
required: true
18+
19+
- type: textarea
20+
attributes:
21+
label: Code snippet
22+
description: Provide the code snippet that reproduces the issue.
23+
placeholder: "```\n// Code snippet here\n```"
24+
validations:
25+
required: true
26+
27+
- type: textarea
28+
attributes:
29+
label: Actual behavior
30+
description: Describe what actually happened.
31+
placeholder: A description of the actual behavior.
32+
validations:
33+
required: true
34+
35+
- type: textarea
36+
attributes:
37+
label: Expected behavior
38+
description: Describe what you expected to happen.
39+
placeholder: A description of the expected outcome.
40+
validations:
41+
required: true
42+
43+
- type: input
44+
attributes:
45+
label: twilio-python version
46+
description: Specify the version of the twilio-python helper library you are using.
47+
placeholder: e.g., 9.4.1
48+
validations:
49+
required: true
50+
51+
- type: input
52+
attributes:
53+
label: Python version
54+
description: Specify the version of Python you are using.
55+
placeholder: e.g., 3.9.1
56+
validations:
57+
required: true
58+
59+
- type: textarea
60+
attributes:
61+
label: Logs or error messages
62+
description: Provide relevant logs or error messages (if any).
63+
placeholder: "Error: Something went wrong..."
64+
65+
- type: textarea
66+
attributes:
67+
label: Additional context
68+
description: Add any other context about the problem here.
69+
placeholder: Any additional

.github/workflows/test-and-deploy.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ jobs:
1717
timeout-minutes: 20
1818
strategy:
1919
matrix:
20-
python-version: [ '3.7', '3.8', '3.9', '3.10', '3.11', '3.12' ]
20+
python-version: [ '3.8', '3.9', '3.10', '3.11', '3.12' ]
2121
steps:
2222
- name: Checkout twilio-python
2323
uses: actions/checkout@v3
@@ -47,6 +47,7 @@ jobs:
4747
TWILIO_FROM_NUMBER: ${{ secrets.TWILIO_FROM_NUMBER }}
4848
TWILIO_TO_NUMBER: ${{ secrets.TWILIO_TO_NUMBER }}
4949
TWILIO_AUTH_TOKEN: ${{ secrets.TWILIO_AUTH_TOKEN }}
50+
ASSISTANT_ID: ${{ secrets.ASSISTANT_ID }}
5051
run: make cluster-test
5152

5253
- name: Verify docs generation

CHANGES.md

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

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

6+
[2025-03-11] Version 9.5.0
7+
--------------------------
8+
**Library - Feature**
9+
- [PR #850](https://github.com/twilio/twilio-python/pull/850): Update UPGRADE.md. Thanks to [@manisha1997](https://github.com/manisha1997)!
10+
11+
**Library - Fix**
12+
- [PR #847](https://github.com/twilio/twilio-python/pull/847): AssistantsBase import. Thanks to [@sbansla](https://github.com/sbansla)!
13+
14+
**Api**
15+
- Add the missing `emergency_enabled` field for `Address Service` endpoints
16+
17+
**Messaging**
18+
- Add missing enums for A2P and TF
19+
20+
**Numbers**
21+
- add missing enum values to hosted_number_order_status
22+
23+
**Twiml**
24+
- Convert Twiml Attribute `speechModel` of type enum to string **(breaking change)**
25+
26+
27+
[2025-02-20] Version 9.4.6
28+
--------------------------
29+
**Library - Chore**
30+
- [PR #842](https://github.com/twilio/twilio-python/pull/842): issue 841. Thanks to [@manisha1997](https://github.com/manisha1997)!
31+
32+
**Flex**
33+
- Adding Digital Transfers APIs under v1/Interactions
34+
35+
**Numbers**
36+
- Convert webhook_type to ienum type in v1/Porting/Configuration/Webhook/{webhook_type}
37+
38+
**Trusthub**
39+
- Changing TrustHub SupportingDocument status enum from lowercase to uppercase since kyc-orch returns status capitalized and rest proxy requires strict casing
40+
41+
42+
[2025-02-11] Version 9.4.5
43+
--------------------------
44+
**Api**
45+
- Change downstream url and change media type for file `base/api/v2010/validation_request.json`.
46+
47+
**Intelligence**
48+
- Add json_results for Generative JSON operator results
49+
50+
**Messaging**
51+
- Add DestinationAlphaSender API to support Country-Specific Alpha Senders
52+
53+
**Video**
54+
- Change codec type from enum to case-insensitive enum in recording and room_recording apis
55+
56+
57+
[2025-01-28] Version 9.4.4
58+
--------------------------
59+
**Library - Fix**
60+
- [PR #822](https://github.com/twilio/twilio-python/pull/822): Fix for 10 vulnerabilities. Thanks to [@twilio-product-security](https://github.com/twilio-product-security)!
61+
62+
**Library - Chore**
63+
- [PR #834](https://github.com/twilio/twilio-python/pull/834): update httpclient. Thanks to [@manisha1997](https://github.com/manisha1997)!
64+
- [PR #837](https://github.com/twilio/twilio-python/pull/837): enable newer versions of aiohttp-retry. Thanks to [@tiwarishubham635](https://github.com/tiwarishubham635)!
65+
- [PR #833](https://github.com/twilio/twilio-python/pull/833): created bug report issue template. Thanks to [@sbansla](https://github.com/sbansla)!
66+
67+
**Api**
68+
- Add open-api file tag to `conference/call recordings` and `recording_transcriptions`.
69+
70+
**Events**
71+
- Add support for subaccount subscriptions (beta)
72+
73+
**Insights**
74+
- add new region to conference APIs
75+
76+
**Lookups**
77+
- Add new `parnter_sub_id` query parameter to the lookup request
78+
79+
80+
[2025-01-13] Version 9.4.3
81+
--------------------------
82+
**Messaging**
83+
- Adds validity period Default value in service resource documentation
84+
85+
86+
[2025-01-09] Version 9.4.2
87+
--------------------------
88+
**Library - Chore**
89+
- [PR #832](https://github.com/twilio/twilio-python/pull/832): remove test for 3.7. Thanks to [@tiwarishubham635](https://github.com/tiwarishubham635)!
90+
91+
**Numbers**
92+
- Change beta feature flag to use v2/BulkHostedNumberOrders
93+
94+
95+
[2024-12-13] Version 9.4.1
96+
--------------------------
97+
**Library - Fix**
98+
- [PR #827](https://github.com/twilio/twilio-python/pull/827): Fixing init file for preview iam domain. Thanks to [@AsabuHere](https://github.com/AsabuHere)!
99+
100+
**Library - Chore**
101+
- [PR #826](https://github.com/twilio/twilio-python/pull/826): fix orgs api changes. Thanks to [@tiwarishubham635](https://github.com/tiwarishubham635)!
102+
103+
104+
[2024-12-12] Version 9.4.0
105+
--------------------------
106+
**Library - Feature**
107+
- [PR #825](https://github.com/twilio/twilio-python/pull/825): Docs update and examples for organization api uptake and public oauth. Thanks to [@AsabuHere](https://github.com/AsabuHere)!
108+
- [PR #815](https://github.com/twilio/twilio-python/pull/815): Organizations Api uptake for twilio-python. Thanks to [@AsabuHere](https://github.com/AsabuHere)!
109+
110+
111+
[2024-12-05] Version 9.3.8
112+
--------------------------
113+
**Api**
114+
- Add optional parameter `intelligence_service` to `transcription`
115+
- Updated `phone_number_sid` to be populated for sip trunking terminating calls.
116+
117+
**Numbers**
118+
- Add Update Hosted Number Order V2 API endpoint
119+
- Update Port in docs
120+
121+
**Twiml**
122+
- Add optional parameter `intelligence_service` to `<Transcription>`
123+
- Add support for new `<ConversationRelay>` and `<Assistant>` noun
124+
- Add `events` attribute to `<Dial>` verb
125+
126+
127+
[2024-11-15] Version 9.3.7
128+
--------------------------
129+
**Library - Chore**
130+
- [PR #819](https://github.com/twilio/twilio-python/pull/819): use older verison of aiohttp_retry. Thanks to [@sbansla](https://github.com/sbansla)!
131+
132+
**Api**
133+
- Added `ivr-virtual-agent-custom-voices` and `ivr-virtual-agent-genai` to `usage_record` API.
134+
- Add open-api file tag to realtime_transcriptions
135+
136+
**Taskrouter**
137+
- Add `api-tag` property to workers reservation
138+
- Add `api-tag` property to task reservation
139+
140+
141+
[2024-10-25] Version 9.3.6
142+
--------------------------
143+
**Library - Chore**
144+
- [PR #818](https://github.com/twilio/twilio-python/pull/818): removing unavailable references from init files. Thanks to [@tiwarishubham635](https://github.com/tiwarishubham635)!
145+
146+
147+
[2024-10-24] Version 9.3.5
148+
--------------------------
149+
**Conversations**
150+
- Expose ConversationWithParticipants resource that allows creating a conversation with participants
151+
152+
153+
[2024-10-17] Version 9.3.4
154+
--------------------------
155+
**Api**
156+
- Add response key `country` to fetch AvailablePhoneNumber resource by specific country.
157+
158+
**Messaging**
159+
- Make library and doc public for requestManagedCert Endpoint
160+
161+
162+
[2024-10-03] Version 9.3.3
163+
--------------------------
164+
**Library - Chore**
165+
- [PR #816](https://github.com/twilio/twilio-python/pull/816): add assistants init files. Thanks to [@tiwarishubham635](https://github.com/tiwarishubham635)!
166+
167+
**Messaging**
168+
- Add A2P external campaign CnpMigration flag
169+
170+
**Numbers**
171+
- Add address sid to portability API
172+
173+
**Verify**
174+
- Add `SnaClientToken` optional parameter on Verification check.
175+
- Add `EnableSnaClientToken` optional parameter for Verification creation.
176+
177+
178+
[2024-09-25] Version 9.3.2
179+
--------------------------
180+
**Accounts**
181+
- Update docs and mounts.
182+
- Change library visibility to public
183+
- Enable consent and contact bulk upsert APIs in prod.
184+
185+
**Serverless**
186+
- Add is_plugin parameter in deployments api to check if it is plugins deployment
187+
188+
189+
[2024-09-18] Version 9.3.1
190+
--------------------------
191+
**Library - Chore**
192+
- [PR #813](https://github.com/twilio/twilio-python/pull/813): add static init file to iam domain. Thanks to [@tiwarishubham635](https://github.com/tiwarishubham635)!
193+
194+
**Intelligence**
195+
- Remove public from operator_type
196+
- Update operator_type to include general-availablity and deprecated
197+
198+
**Numbers**
199+
- Remove beta flag for bundle clone API
200+
201+
202+
[2024-09-05] Version 9.3.0
203+
--------------------------
204+
**Iam**
205+
- updated library_visibility public for new public apikeys
206+
207+
**Numbers**
208+
- Add new field in Error Codes for Regulatory Compliance.
209+
- Change typing of Port In Request date_created field to date_time instead of date **(breaking change)**
210+
211+
212+
[2024-08-26] Version 9.2.4
213+
--------------------------
214+
**Library - Chore**
215+
- [PR #810](https://github.com/twilio/twilio-python/pull/810): add license identifier to project metadata. Thanks to [@mschoettle](https://github.com/mschoettle)!
216+
- [PR #808](https://github.com/twilio/twilio-python/pull/808): preview iam removal. Thanks to [@manisha1997](https://github.com/manisha1997)!
217+
- [PR #807](https://github.com/twilio/twilio-python/pull/807): update intersphinx_mapping. Thanks to [@tiwarishubham635](https://github.com/tiwarishubham635)!
218+
- [PR #804](https://github.com/twilio/twilio-python/pull/804): add init file. Thanks to [@manisha1997](https://github.com/manisha1997)!
219+
220+
**Api**
221+
- Update documentation of `error_code` and `error_message` on the Message resource.
222+
- Remove generic parameters from `transcription` resource
223+
- Added public documentation for Payload Data retrieval API
224+
225+
**Flex**
226+
- Adding update Flex User api
227+
228+
**Insights**
229+
- Added 'branded', 'business_profile' and 'voice_integrity' fields in List Call Summary
230+
231+
**Intelligence**
232+
- Add `words` array information to the Sentences v2 entity.
233+
- Add `X-Rate-Limit-Limit`, `X-Rate-Limit-Remaining`, and `X-Rate-Limit-Config` headers for Operator Results.
234+
- Change the path parameter when fetching an `/OperatorType/{}` from `sid<EY>` to `string` to support searching by SID or by name
235+
- Add `X-Rate-Limit-Limit`, `X-Rate-Limit-Remaining`, and `X-Rate-Limit-Config` headers for Transcript and Service endpoints.
236+
237+
**Messaging**
238+
- Adds two new channel senders api to add/remove channel senders to/from a messaging service
239+
- Extend ERC api to accept an optional attribute in request body to indicate CNP migration for an ERC
240+
241+
**Numbers**
242+
- Modify visibility to public in bundle clone API
243+
- Add `port_date` field to Port In Request and Port In Phone Numbers Fetch APIs
244+
- Change properties docs for port in phone numbers api
245+
- Add is_test body param to the Bundle Create API
246+
- Change properties docs for port in api
247+
248+
**Trusthub**
249+
- Add new field in themeSetId in compliance_inquiry.
250+
251+
**Verify**
252+
- Update `custom_code_enabled` description on verification docs
253+
254+
255+
[2024-07-02] Version 9.2.3
256+
--------------------------
257+
**Intelligence**
258+
- Deprecate account flag api.twilio-intelligence.v2
259+
260+
261+
[2024-06-27] Version 9.2.2
262+
--------------------------
263+
**Api**
264+
- Add `transcription` resource
265+
266+
**Flex**
267+
- Changed mount name for flex_team v2 api
268+
269+
**Intelligence**
270+
- Add `X-Rate-Limit-Limit`, `X-Rate-Limit-Remaining`, and `X-Rate-Limit-Config` as Response Headers to Operator resources
271+
272+
**Numbers**
273+
- Added include_constraints query parameter to the Regulations API
274+
275+
**Twiml**
276+
- Add support for `<Transcription>` noun
277+
278+
279+
[2024-06-21] Version 9.2.1
280+
--------------------------
281+
**Api**
282+
- Add beta feature request managed cert
283+
284+
6285
[2024-06-18] Version 9.2.0
7286
--------------------------
8287
**Library - Chore**

README.md

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,6 +86,13 @@ After a brief delay, you will receive the text message on your phone.
8686
> **Warning**
8787
> It's okay to hardcode your credentials when testing locally, but you should use environment variables to keep them secret before committing any code or deploying to production. Check out [How to Set Environment Variables](https://www.twilio.com/blog/2017/01/how-to-set-environment-variables.html) for more information.
8888
89+
## OAuth Feature for Twilio APIs
90+
We are introducing Client Credentials Flow-based OAuth 2.0 authentication. This feature is currently in beta and its implementation is subject to change.
91+
92+
API examples [here](https://github.com/twilio/twilio-python/blob/main/examples/public_oauth.py)
93+
94+
Organisation API examples [here](https://github.com/twilio/twilio-python/blob/main/examples/organization_api.py)
95+
8996
## Use the helper library
9097

9198
### API Credentials
@@ -128,7 +135,9 @@ client = Client()
128135

129136
### Specify Region and/or Edge
130137

131-
To take advantage of Twilio's [Global Infrastructure](https://www.twilio.com/docs/global-infrastructure), specify the target Region and/or Edge for the client:
138+
To take advantage of Twilio's [Global Infrastructure](https://www.twilio.com/docs/global-infrastructure), specify the target Region and Edge for the client:
139+
140+
> **Note:** When specifying a `region` parameter for a helper library client, be sure to also specify the `edge` parameter. For backward compatibility purposes, specifying a `region` without specifying an `edge` will result in requests being routed to US1.
132141
133142
```python
134143
from twilio.rest import Client

0 commit comments

Comments
 (0)