telnyx 3.2.0a0__py3-none-any.whl → 3.3.0a0__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 telnyx might be problematic. Click here for more details.
- telnyx/_client.py +5 -0
- telnyx/_version.py +1 -1
- telnyx/resources/__init__.py +3 -0
- telnyx/resources/webhooks.py +34 -0
- telnyx/types/__init__.py +111 -0
- telnyx/types/call_ai_gather_ended_webhook_event.py +78 -0
- telnyx/types/call_ai_gather_message_history_updated_webhook_event.py +69 -0
- telnyx/types/call_ai_gather_partial_results_webhook_event.py +75 -0
- telnyx/types/call_answered_webhook_event.py +75 -0
- telnyx/types/call_bridged_webhook_event.py +58 -0
- telnyx/types/call_conversation_ended_webhook_event.py +84 -0
- telnyx/types/call_conversation_insights_generated_webhook_event.py +67 -0
- telnyx/types/call_dtmf_received_webhook_event.py +61 -0
- telnyx/types/call_enqueued_webhook_event.py +59 -0
- telnyx/types/call_fork_started_webhook_event.py +53 -0
- telnyx/types/call_fork_stopped_webhook_event.py +53 -0
- telnyx/types/call_gather_ended_webhook_event.py +64 -0
- telnyx/types/call_hangup_webhook_event.py +150 -0
- telnyx/types/call_initiated_webhook_event.py +96 -0
- telnyx/types/call_left_queue_webhook_event.py +62 -0
- telnyx/types/call_machine_detection_ended_webhook_event.py +61 -0
- telnyx/types/call_machine_greeting_ended_webhook_event.py +61 -0
- telnyx/types/call_machine_premium_detection_ended_webhook_event.py +63 -0
- telnyx/types/call_machine_premium_greeting_ended_webhook_event.py +61 -0
- telnyx/types/call_playback_ended_webhook_event.py +70 -0
- telnyx/types/call_playback_started_webhook_event.py +62 -0
- telnyx/types/call_recording_error_webhook_event.py +60 -0
- telnyx/types/call_recording_saved_webhook_event.py +94 -0
- telnyx/types/call_recording_transcription_saved_webhook_event.py +71 -0
- telnyx/types/call_refer_completed_webhook_event.py +61 -0
- telnyx/types/call_refer_failed_webhook_event.py +61 -0
- telnyx/types/call_refer_started_webhook_event.py +61 -0
- telnyx/types/call_siprec_failed_webhook_event.py +53 -0
- telnyx/types/call_siprec_started_webhook_event.py +50 -0
- telnyx/types/call_siprec_stopped_webhook_event.py +53 -0
- telnyx/types/call_speak_ended_webhook_event.py +53 -0
- telnyx/types/call_speak_started_webhook_event.py +50 -0
- telnyx/types/call_streaming_failed_webhook_event.py +70 -0
- telnyx/types/call_streaming_started_webhook_event.py +53 -0
- telnyx/types/call_streaming_stopped_webhook_event.py +53 -0
- telnyx/types/campaign_status_update_webhook_event.py +26 -0
- telnyx/types/conference_created_webhook_event.py +53 -0
- telnyx/types/conference_ended_webhook_event.py +56 -0
- telnyx/types/conference_floor_changed_webhook_event.py +45 -0
- telnyx/types/conference_participant_joined_webhook_event.py +53 -0
- telnyx/types/conference_participant_left_webhook_event.py +53 -0
- telnyx/types/conference_participant_playback_ended_webhook_event.py +65 -0
- telnyx/types/conference_participant_playback_started_webhook_event.py +65 -0
- telnyx/types/conference_participant_speak_ended_webhook_event.py +56 -0
- telnyx/types/conference_participant_speak_started_webhook_event.py +56 -0
- telnyx/types/conference_playback_ended_webhook_event.py +49 -0
- telnyx/types/conference_playback_started_webhook_event.py +49 -0
- telnyx/types/conference_recording_saved_webhook_event.py +103 -0
- telnyx/types/conference_speak_ended_webhook_event.py +40 -0
- telnyx/types/conference_speak_started_webhook_event.py +40 -0
- telnyx/types/custom_sip_header.py +13 -0
- telnyx/types/customer_service_record_status_changed_webhook_event.py +55 -0
- telnyx/types/delivery_update_webhook_event.py +40 -0
- telnyx/types/fax_delivered_webhook_event.py +69 -0
- telnyx/types/fax_failed_webhook_event.py +66 -0
- telnyx/types/fax_media_processed_webhook_event.py +63 -0
- telnyx/types/fax_queued_webhook_event.py +63 -0
- telnyx/types/fax_sending_started_webhook_event.py +63 -0
- telnyx/types/inbound_message_webhook_event.py +227 -0
- telnyx/types/number_order_status_update_webhook_event.py +12 -0
- telnyx/types/replaced_link_click_webhook_event.py +32 -0
- telnyx/types/sip_header.py +15 -0
- telnyx/types/streaming_failed_webhook_event.py +70 -0
- telnyx/types/streaming_started_webhook_event.py +53 -0
- telnyx/types/streaming_stopped_webhook_event.py +53 -0
- telnyx/types/transcription_webhook_event.py +72 -0
- telnyx/types/unwrap_webhook_event.py +138 -0
- {telnyx-3.2.0a0.dist-info → telnyx-3.3.0a0.dist-info}/METADATA +1 -1
- {telnyx-3.2.0a0.dist-info → telnyx-3.3.0a0.dist-info}/RECORD +76 -8
- {telnyx-3.2.0a0.dist-info → telnyx-3.3.0a0.dist-info}/WHEEL +0 -0
- {telnyx-3.2.0a0.dist-info → telnyx-3.3.0a0.dist-info}/licenses/LICENSE +0 -0
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from typing import Optional
|
|
4
|
+
from datetime import datetime
|
|
5
|
+
from typing_extensions import Literal
|
|
6
|
+
|
|
7
|
+
from .._models import BaseModel
|
|
8
|
+
|
|
9
|
+
__all__ = ["ConferenceParticipantSpeakStartedWebhookEvent", "Data", "DataPayload"]
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
class DataPayload(BaseModel):
|
|
13
|
+
call_control_id: Optional[str] = None
|
|
14
|
+
"""Participant's call ID used to issue commands via Call Control API."""
|
|
15
|
+
|
|
16
|
+
call_leg_id: Optional[str] = None
|
|
17
|
+
"""ID that is unique to the call and can be used to correlate webhook events."""
|
|
18
|
+
|
|
19
|
+
call_session_id: Optional[str] = None
|
|
20
|
+
"""
|
|
21
|
+
ID that is unique to the call session and can be used to correlate webhook
|
|
22
|
+
events. Call session is a group of related call legs that logically belong to
|
|
23
|
+
the same phone call, e.g. an inbound and outbound leg of a transferred call.
|
|
24
|
+
"""
|
|
25
|
+
|
|
26
|
+
client_state: Optional[str] = None
|
|
27
|
+
"""State received from a command."""
|
|
28
|
+
|
|
29
|
+
conference_id: Optional[str] = None
|
|
30
|
+
"""ID of the conference the text was spoken in."""
|
|
31
|
+
|
|
32
|
+
connection_id: Optional[str] = None
|
|
33
|
+
"""Call Control App ID (formerly Telnyx connection ID) used in the call."""
|
|
34
|
+
|
|
35
|
+
creator_call_session_id: Optional[str] = None
|
|
36
|
+
"""ID that is unique to the call session that started the conference."""
|
|
37
|
+
|
|
38
|
+
occurred_at: Optional[datetime] = None
|
|
39
|
+
"""ISO 8601 datetime of when the event occurred."""
|
|
40
|
+
|
|
41
|
+
|
|
42
|
+
class Data(BaseModel):
|
|
43
|
+
id: Optional[str] = None
|
|
44
|
+
"""Identifies the type of resource."""
|
|
45
|
+
|
|
46
|
+
event_type: Optional[Literal["conference.participant.speak.started"]] = None
|
|
47
|
+
"""The type of event being delivered."""
|
|
48
|
+
|
|
49
|
+
payload: Optional[DataPayload] = None
|
|
50
|
+
|
|
51
|
+
record_type: Optional[Literal["event"]] = None
|
|
52
|
+
"""Identifies the type of the resource."""
|
|
53
|
+
|
|
54
|
+
|
|
55
|
+
class ConferenceParticipantSpeakStartedWebhookEvent(BaseModel):
|
|
56
|
+
data: Optional[Data] = None
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from typing import Optional
|
|
4
|
+
from datetime import datetime
|
|
5
|
+
from typing_extensions import Literal
|
|
6
|
+
|
|
7
|
+
from .._models import BaseModel
|
|
8
|
+
|
|
9
|
+
__all__ = ["ConferencePlaybackEndedWebhookEvent", "Data", "DataPayload"]
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
class DataPayload(BaseModel):
|
|
13
|
+
conference_id: Optional[str] = None
|
|
14
|
+
"""ID of the conference the text was spoken in."""
|
|
15
|
+
|
|
16
|
+
connection_id: Optional[str] = None
|
|
17
|
+
"""Call Control App ID (formerly Telnyx connection ID) used in the call."""
|
|
18
|
+
|
|
19
|
+
creator_call_session_id: Optional[str] = None
|
|
20
|
+
"""ID that is unique to the call session that started the conference."""
|
|
21
|
+
|
|
22
|
+
media_name: Optional[str] = None
|
|
23
|
+
"""
|
|
24
|
+
The name of the audio media file being played back, if media_name has been used
|
|
25
|
+
to start.
|
|
26
|
+
"""
|
|
27
|
+
|
|
28
|
+
media_url: Optional[str] = None
|
|
29
|
+
"""The audio URL being played back, if audio_url has been used to start."""
|
|
30
|
+
|
|
31
|
+
occurred_at: Optional[datetime] = None
|
|
32
|
+
"""ISO 8601 datetime of when the event occurred."""
|
|
33
|
+
|
|
34
|
+
|
|
35
|
+
class Data(BaseModel):
|
|
36
|
+
id: Optional[str] = None
|
|
37
|
+
"""Identifies the type of resource."""
|
|
38
|
+
|
|
39
|
+
event_type: Optional[Literal["conference.playback.ended"]] = None
|
|
40
|
+
"""The type of event being delivered."""
|
|
41
|
+
|
|
42
|
+
payload: Optional[DataPayload] = None
|
|
43
|
+
|
|
44
|
+
record_type: Optional[Literal["event"]] = None
|
|
45
|
+
"""Identifies the type of the resource."""
|
|
46
|
+
|
|
47
|
+
|
|
48
|
+
class ConferencePlaybackEndedWebhookEvent(BaseModel):
|
|
49
|
+
data: Optional[Data] = None
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from typing import Optional
|
|
4
|
+
from datetime import datetime
|
|
5
|
+
from typing_extensions import Literal
|
|
6
|
+
|
|
7
|
+
from .._models import BaseModel
|
|
8
|
+
|
|
9
|
+
__all__ = ["ConferencePlaybackStartedWebhookEvent", "Data", "DataPayload"]
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
class DataPayload(BaseModel):
|
|
13
|
+
conference_id: Optional[str] = None
|
|
14
|
+
"""ID of the conference the text was spoken in."""
|
|
15
|
+
|
|
16
|
+
connection_id: Optional[str] = None
|
|
17
|
+
"""Call Control App ID (formerly Telnyx connection ID) used in the call."""
|
|
18
|
+
|
|
19
|
+
creator_call_session_id: Optional[str] = None
|
|
20
|
+
"""ID that is unique to the call session that started the conference."""
|
|
21
|
+
|
|
22
|
+
media_name: Optional[str] = None
|
|
23
|
+
"""
|
|
24
|
+
The name of the audio media file being played back, if media_name has been used
|
|
25
|
+
to start.
|
|
26
|
+
"""
|
|
27
|
+
|
|
28
|
+
media_url: Optional[str] = None
|
|
29
|
+
"""The audio URL being played back, if audio_url has been used to start."""
|
|
30
|
+
|
|
31
|
+
occurred_at: Optional[datetime] = None
|
|
32
|
+
"""ISO 8601 datetime of when the event occurred."""
|
|
33
|
+
|
|
34
|
+
|
|
35
|
+
class Data(BaseModel):
|
|
36
|
+
id: Optional[str] = None
|
|
37
|
+
"""Identifies the type of resource."""
|
|
38
|
+
|
|
39
|
+
event_type: Optional[Literal["conference.playback.started"]] = None
|
|
40
|
+
"""The type of event being delivered."""
|
|
41
|
+
|
|
42
|
+
payload: Optional[DataPayload] = None
|
|
43
|
+
|
|
44
|
+
record_type: Optional[Literal["event"]] = None
|
|
45
|
+
"""Identifies the type of the resource."""
|
|
46
|
+
|
|
47
|
+
|
|
48
|
+
class ConferencePlaybackStartedWebhookEvent(BaseModel):
|
|
49
|
+
data: Optional[Data] = None
|
|
@@ -0,0 +1,103 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from typing import Optional
|
|
4
|
+
from datetime import datetime
|
|
5
|
+
from typing_extensions import Literal
|
|
6
|
+
|
|
7
|
+
from .._models import BaseModel
|
|
8
|
+
|
|
9
|
+
__all__ = [
|
|
10
|
+
"ConferenceRecordingSavedWebhookEvent",
|
|
11
|
+
"Data",
|
|
12
|
+
"DataPayload",
|
|
13
|
+
"DataPayloadPublicRecordingURLs",
|
|
14
|
+
"DataPayloadRecordingURLs",
|
|
15
|
+
]
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
class DataPayloadPublicRecordingURLs(BaseModel):
|
|
19
|
+
mp3: Optional[str] = None
|
|
20
|
+
"""Recording URL in requested `mp3` format."""
|
|
21
|
+
|
|
22
|
+
wav: Optional[str] = None
|
|
23
|
+
"""Recording URL in requested `wav` format."""
|
|
24
|
+
|
|
25
|
+
|
|
26
|
+
class DataPayloadRecordingURLs(BaseModel):
|
|
27
|
+
mp3: Optional[str] = None
|
|
28
|
+
"""Recording URL in requested `mp3` format."""
|
|
29
|
+
|
|
30
|
+
wav: Optional[str] = None
|
|
31
|
+
"""Recording URL in requested `wav` format."""
|
|
32
|
+
|
|
33
|
+
|
|
34
|
+
class DataPayload(BaseModel):
|
|
35
|
+
call_control_id: Optional[str] = None
|
|
36
|
+
"""Participant's call ID used to issue commands via Call Control API."""
|
|
37
|
+
|
|
38
|
+
call_session_id: Optional[str] = None
|
|
39
|
+
"""
|
|
40
|
+
ID that is unique to the call session and can be used to correlate webhook
|
|
41
|
+
events. Call session is a group of related call legs that logically belong to
|
|
42
|
+
the same phone call, e.g. an inbound and outbound leg of a transferred call.
|
|
43
|
+
"""
|
|
44
|
+
|
|
45
|
+
channels: Optional[Literal["single", "dual"]] = None
|
|
46
|
+
"""Whether recording was recorded in `single` or `dual` channel."""
|
|
47
|
+
|
|
48
|
+
client_state: Optional[str] = None
|
|
49
|
+
"""State received from a command."""
|
|
50
|
+
|
|
51
|
+
conference_id: Optional[str] = None
|
|
52
|
+
"""ID of the conference that is being recorded."""
|
|
53
|
+
|
|
54
|
+
connection_id: Optional[str] = None
|
|
55
|
+
"""Call Control App ID (formerly Telnyx connection ID) used in the call."""
|
|
56
|
+
|
|
57
|
+
format: Optional[Literal["wav", "mp3"]] = None
|
|
58
|
+
"""The audio file format used when storing the call recording.
|
|
59
|
+
|
|
60
|
+
Can be either `mp3` or `wav`.
|
|
61
|
+
"""
|
|
62
|
+
|
|
63
|
+
public_recording_urls: Optional[DataPayloadPublicRecordingURLs] = None
|
|
64
|
+
"""Recording URLs in requested format.
|
|
65
|
+
|
|
66
|
+
The URL is valid for as long as the file exists. For security purposes, this
|
|
67
|
+
feature is activated on a per request basis. Please contact customer support
|
|
68
|
+
with your Account ID to request activation.
|
|
69
|
+
"""
|
|
70
|
+
|
|
71
|
+
recording_ended_at: Optional[datetime] = None
|
|
72
|
+
"""ISO 8601 datetime of when recording ended."""
|
|
73
|
+
|
|
74
|
+
recording_id: Optional[str] = None
|
|
75
|
+
"""ID of the conference recording."""
|
|
76
|
+
|
|
77
|
+
recording_started_at: Optional[datetime] = None
|
|
78
|
+
"""ISO 8601 datetime of when recording started."""
|
|
79
|
+
|
|
80
|
+
recording_urls: Optional[DataPayloadRecordingURLs] = None
|
|
81
|
+
"""Recording URLs in requested format.
|
|
82
|
+
|
|
83
|
+
These URLs are valid for 10 minutes. After 10 minutes, you may retrieve
|
|
84
|
+
recordings via API using Reports -> Call Recordings documentation, or via
|
|
85
|
+
Mission Control under Reporting -> Recordings.
|
|
86
|
+
"""
|
|
87
|
+
|
|
88
|
+
|
|
89
|
+
class Data(BaseModel):
|
|
90
|
+
id: Optional[str] = None
|
|
91
|
+
"""Identifies the type of resource."""
|
|
92
|
+
|
|
93
|
+
event_type: Optional[Literal["conference.recording.saved"]] = None
|
|
94
|
+
"""The type of event being delivered."""
|
|
95
|
+
|
|
96
|
+
payload: Optional[DataPayload] = None
|
|
97
|
+
|
|
98
|
+
record_type: Optional[Literal["event"]] = None
|
|
99
|
+
"""Identifies the type of the resource."""
|
|
100
|
+
|
|
101
|
+
|
|
102
|
+
class ConferenceRecordingSavedWebhookEvent(BaseModel):
|
|
103
|
+
data: Optional[Data] = None
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from typing import Optional
|
|
4
|
+
from datetime import datetime
|
|
5
|
+
from typing_extensions import Literal
|
|
6
|
+
|
|
7
|
+
from .._models import BaseModel
|
|
8
|
+
|
|
9
|
+
__all__ = ["ConferenceSpeakEndedWebhookEvent", "Data", "DataPayload"]
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
class DataPayload(BaseModel):
|
|
13
|
+
conference_id: Optional[str] = None
|
|
14
|
+
"""ID of the conference the text was spoken in."""
|
|
15
|
+
|
|
16
|
+
connection_id: Optional[str] = None
|
|
17
|
+
"""Call Control App ID (formerly Telnyx connection ID) used in the call."""
|
|
18
|
+
|
|
19
|
+
creator_call_session_id: Optional[str] = None
|
|
20
|
+
"""ID that is unique to the call session that started the conference."""
|
|
21
|
+
|
|
22
|
+
occurred_at: Optional[datetime] = None
|
|
23
|
+
"""ISO 8601 datetime of when the event occurred."""
|
|
24
|
+
|
|
25
|
+
|
|
26
|
+
class Data(BaseModel):
|
|
27
|
+
id: Optional[str] = None
|
|
28
|
+
"""Identifies the type of resource."""
|
|
29
|
+
|
|
30
|
+
event_type: Optional[Literal["conference.speak.ended"]] = None
|
|
31
|
+
"""The type of event being delivered."""
|
|
32
|
+
|
|
33
|
+
payload: Optional[DataPayload] = None
|
|
34
|
+
|
|
35
|
+
record_type: Optional[Literal["event"]] = None
|
|
36
|
+
"""Identifies the type of the resource."""
|
|
37
|
+
|
|
38
|
+
|
|
39
|
+
class ConferenceSpeakEndedWebhookEvent(BaseModel):
|
|
40
|
+
data: Optional[Data] = None
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from typing import Optional
|
|
4
|
+
from datetime import datetime
|
|
5
|
+
from typing_extensions import Literal
|
|
6
|
+
|
|
7
|
+
from .._models import BaseModel
|
|
8
|
+
|
|
9
|
+
__all__ = ["ConferenceSpeakStartedWebhookEvent", "Data", "DataPayload"]
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
class DataPayload(BaseModel):
|
|
13
|
+
conference_id: Optional[str] = None
|
|
14
|
+
"""ID of the conference the text was spoken in."""
|
|
15
|
+
|
|
16
|
+
connection_id: Optional[str] = None
|
|
17
|
+
"""Call Control App ID (formerly Telnyx connection ID) used in the call."""
|
|
18
|
+
|
|
19
|
+
creator_call_session_id: Optional[str] = None
|
|
20
|
+
"""ID that is unique to the call session that started the conference."""
|
|
21
|
+
|
|
22
|
+
occurred_at: Optional[datetime] = None
|
|
23
|
+
"""ISO 8601 datetime of when the event occurred."""
|
|
24
|
+
|
|
25
|
+
|
|
26
|
+
class Data(BaseModel):
|
|
27
|
+
id: Optional[str] = None
|
|
28
|
+
"""Identifies the type of resource."""
|
|
29
|
+
|
|
30
|
+
event_type: Optional[Literal["conference.speak.started"]] = None
|
|
31
|
+
"""The type of event being delivered."""
|
|
32
|
+
|
|
33
|
+
payload: Optional[DataPayload] = None
|
|
34
|
+
|
|
35
|
+
record_type: Optional[Literal["event"]] = None
|
|
36
|
+
"""Identifies the type of the resource."""
|
|
37
|
+
|
|
38
|
+
|
|
39
|
+
class ConferenceSpeakStartedWebhookEvent(BaseModel):
|
|
40
|
+
data: Optional[Data] = None
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from .._models import BaseModel
|
|
4
|
+
|
|
5
|
+
__all__ = ["CustomSipHeader"]
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
class CustomSipHeader(BaseModel):
|
|
9
|
+
name: str
|
|
10
|
+
"""The name of the header to add."""
|
|
11
|
+
|
|
12
|
+
value: str
|
|
13
|
+
"""The value of the header."""
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from typing import Optional
|
|
4
|
+
from datetime import datetime
|
|
5
|
+
from typing_extensions import Literal
|
|
6
|
+
|
|
7
|
+
from .._models import BaseModel
|
|
8
|
+
|
|
9
|
+
__all__ = ["CustomerServiceRecordStatusChangedWebhookEvent", "Data", "DataPayload", "Meta"]
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
class DataPayload(BaseModel):
|
|
13
|
+
id: Optional[str] = None
|
|
14
|
+
"""Uniquely identifies the customer service record."""
|
|
15
|
+
|
|
16
|
+
phone_number: Optional[str] = None
|
|
17
|
+
"""The phone number of the customer service record."""
|
|
18
|
+
|
|
19
|
+
status: Optional[Literal["pending", "completed", "failed"]] = None
|
|
20
|
+
"""The status of the customer service record"""
|
|
21
|
+
|
|
22
|
+
updated_at: Optional[datetime] = None
|
|
23
|
+
"""
|
|
24
|
+
ISO 8601 formatted date indicating the last time where the resource was updated.
|
|
25
|
+
"""
|
|
26
|
+
|
|
27
|
+
|
|
28
|
+
class Data(BaseModel):
|
|
29
|
+
id: Optional[str] = None
|
|
30
|
+
"""Uniquely identifies the callback event."""
|
|
31
|
+
|
|
32
|
+
event_type: Optional[Literal["customer_service_record.status_changed"]] = None
|
|
33
|
+
"""The type of the callback event."""
|
|
34
|
+
|
|
35
|
+
occurred_at: Optional[datetime] = None
|
|
36
|
+
"""ISO 8601 formatted date indicating when the callback event occurred."""
|
|
37
|
+
|
|
38
|
+
payload: Optional[DataPayload] = None
|
|
39
|
+
|
|
40
|
+
record_type: Optional[Literal["event"]] = None
|
|
41
|
+
"""Identifies the type of the resource."""
|
|
42
|
+
|
|
43
|
+
|
|
44
|
+
class Meta(BaseModel):
|
|
45
|
+
attempt: Optional[int] = None
|
|
46
|
+
"""The number of times the callback webhook has been attempted."""
|
|
47
|
+
|
|
48
|
+
delivered_to: Optional[str] = None
|
|
49
|
+
"""The URL that the callback webhook was delivered to."""
|
|
50
|
+
|
|
51
|
+
|
|
52
|
+
class CustomerServiceRecordStatusChangedWebhookEvent(BaseModel):
|
|
53
|
+
data: Optional[Data] = None
|
|
54
|
+
|
|
55
|
+
meta: Optional[Meta] = None
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from typing import Optional
|
|
4
|
+
from datetime import datetime
|
|
5
|
+
from typing_extensions import Literal
|
|
6
|
+
|
|
7
|
+
from .._models import BaseModel
|
|
8
|
+
from .outbound_message_payload import OutboundMessagePayload
|
|
9
|
+
|
|
10
|
+
__all__ = ["DeliveryUpdateWebhookEvent", "Data", "Meta"]
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
class Data(BaseModel):
|
|
14
|
+
id: Optional[str] = None
|
|
15
|
+
"""Identifies the type of resource."""
|
|
16
|
+
|
|
17
|
+
event_type: Optional[Literal["message.sent", "message.finalized"]] = None
|
|
18
|
+
"""The type of event being delivered."""
|
|
19
|
+
|
|
20
|
+
occurred_at: Optional[datetime] = None
|
|
21
|
+
"""ISO 8601 formatted date indicating when the resource was created."""
|
|
22
|
+
|
|
23
|
+
payload: Optional[OutboundMessagePayload] = None
|
|
24
|
+
|
|
25
|
+
record_type: Optional[Literal["event"]] = None
|
|
26
|
+
"""Identifies the type of the resource."""
|
|
27
|
+
|
|
28
|
+
|
|
29
|
+
class Meta(BaseModel):
|
|
30
|
+
attempt: Optional[int] = None
|
|
31
|
+
"""Number of attempts to deliver the webhook event."""
|
|
32
|
+
|
|
33
|
+
delivered_to: Optional[str] = None
|
|
34
|
+
"""The webhook URL the event was delivered to."""
|
|
35
|
+
|
|
36
|
+
|
|
37
|
+
class DeliveryUpdateWebhookEvent(BaseModel):
|
|
38
|
+
data: Optional[Data] = None
|
|
39
|
+
|
|
40
|
+
meta: Optional[Meta] = None
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from typing import Optional
|
|
4
|
+
from typing_extensions import Literal
|
|
5
|
+
|
|
6
|
+
from pydantic import Field as FieldInfo
|
|
7
|
+
|
|
8
|
+
from .._models import BaseModel
|
|
9
|
+
|
|
10
|
+
__all__ = ["FaxDeliveredWebhookEvent", "Payload"]
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
class Payload(BaseModel):
|
|
14
|
+
call_duration_secs: Optional[int] = None
|
|
15
|
+
"""The duration of the call in seconds."""
|
|
16
|
+
|
|
17
|
+
client_state: Optional[str] = None
|
|
18
|
+
"""State received from a command."""
|
|
19
|
+
|
|
20
|
+
connection_id: Optional[str] = None
|
|
21
|
+
"""The ID of the connection used to send the fax."""
|
|
22
|
+
|
|
23
|
+
direction: Optional[Literal["inbound", "outbound"]] = None
|
|
24
|
+
"""The direction of the fax."""
|
|
25
|
+
|
|
26
|
+
fax_id: Optional[str] = None
|
|
27
|
+
"""Identifies the fax."""
|
|
28
|
+
|
|
29
|
+
from_: Optional[str] = FieldInfo(alias="from", default=None)
|
|
30
|
+
"""The phone number, in E.164 format, the fax will be sent from."""
|
|
31
|
+
|
|
32
|
+
media_name: Optional[str] = None
|
|
33
|
+
"""The media_name used for the fax's media.
|
|
34
|
+
|
|
35
|
+
Must point to a file previously uploaded to api.telnyx.com/v2/media by the same
|
|
36
|
+
user/organization. media_name and media_url/contents can't be submitted
|
|
37
|
+
together.
|
|
38
|
+
"""
|
|
39
|
+
|
|
40
|
+
original_media_url: Optional[str] = None
|
|
41
|
+
"""The original URL to the PDF used for the fax's media.
|
|
42
|
+
|
|
43
|
+
If media_name was supplied, this is omitted
|
|
44
|
+
"""
|
|
45
|
+
|
|
46
|
+
page_count: Optional[int] = None
|
|
47
|
+
"""Number of transferred pages"""
|
|
48
|
+
|
|
49
|
+
status: Optional[Literal["delivered"]] = None
|
|
50
|
+
"""The status of the fax."""
|
|
51
|
+
|
|
52
|
+
to: Optional[str] = None
|
|
53
|
+
"""The phone number, in E.164 format, the fax will be sent to or SIP URI"""
|
|
54
|
+
|
|
55
|
+
user_id: Optional[str] = None
|
|
56
|
+
"""Identifier of the user to whom the fax belongs"""
|
|
57
|
+
|
|
58
|
+
|
|
59
|
+
class FaxDeliveredWebhookEvent(BaseModel):
|
|
60
|
+
id: Optional[str] = None
|
|
61
|
+
"""Identifies the type of resource."""
|
|
62
|
+
|
|
63
|
+
event_type: Optional[Literal["fax.delivered"]] = None
|
|
64
|
+
"""The type of event being delivered."""
|
|
65
|
+
|
|
66
|
+
payload: Optional[Payload] = None
|
|
67
|
+
|
|
68
|
+
record_type: Optional[Literal["event"]] = None
|
|
69
|
+
"""Identifies the type of the resource."""
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from typing import Optional
|
|
4
|
+
from typing_extensions import Literal
|
|
5
|
+
|
|
6
|
+
from pydantic import Field as FieldInfo
|
|
7
|
+
|
|
8
|
+
from .._models import BaseModel
|
|
9
|
+
|
|
10
|
+
__all__ = ["FaxFailedWebhookEvent", "Payload"]
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
class Payload(BaseModel):
|
|
14
|
+
client_state: Optional[str] = None
|
|
15
|
+
"""State received from a command."""
|
|
16
|
+
|
|
17
|
+
connection_id: Optional[str] = None
|
|
18
|
+
"""The ID of the connection used to send the fax."""
|
|
19
|
+
|
|
20
|
+
direction: Optional[Literal["inbound", "outbound"]] = None
|
|
21
|
+
"""The direction of the fax."""
|
|
22
|
+
|
|
23
|
+
failure_reason: Optional[Literal["rejected"]] = None
|
|
24
|
+
"""Cause of the sending failure"""
|
|
25
|
+
|
|
26
|
+
fax_id: Optional[str] = None
|
|
27
|
+
"""Identifies the fax."""
|
|
28
|
+
|
|
29
|
+
from_: Optional[str] = FieldInfo(alias="from", default=None)
|
|
30
|
+
"""The phone number, in E.164 format, the fax will be sent from."""
|
|
31
|
+
|
|
32
|
+
media_name: Optional[str] = None
|
|
33
|
+
"""The media_name used for the fax's media.
|
|
34
|
+
|
|
35
|
+
Must point to a file previously uploaded to api.telnyx.com/v2/media by the same
|
|
36
|
+
user/organization. media_name and media_url/contents can't be submitted
|
|
37
|
+
together.
|
|
38
|
+
"""
|
|
39
|
+
|
|
40
|
+
original_media_url: Optional[str] = None
|
|
41
|
+
"""The original URL to the PDF used for the fax's media.
|
|
42
|
+
|
|
43
|
+
If media_name was supplied, this is omitted
|
|
44
|
+
"""
|
|
45
|
+
|
|
46
|
+
status: Optional[Literal["failed"]] = None
|
|
47
|
+
"""The status of the fax."""
|
|
48
|
+
|
|
49
|
+
to: Optional[str] = None
|
|
50
|
+
"""The phone number, in E.164 format, the fax will be sent to or SIP URI"""
|
|
51
|
+
|
|
52
|
+
user_id: Optional[str] = None
|
|
53
|
+
"""Identifier of the user to whom the fax belongs"""
|
|
54
|
+
|
|
55
|
+
|
|
56
|
+
class FaxFailedWebhookEvent(BaseModel):
|
|
57
|
+
id: Optional[str] = None
|
|
58
|
+
"""Identifies the type of resource."""
|
|
59
|
+
|
|
60
|
+
event_type: Optional[Literal["fax.failed"]] = None
|
|
61
|
+
"""The type of event being delivered."""
|
|
62
|
+
|
|
63
|
+
payload: Optional[Payload] = None
|
|
64
|
+
|
|
65
|
+
record_type: Optional[Literal["event"]] = None
|
|
66
|
+
"""Identifies the type of the resource."""
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
from typing import Optional
|
|
4
|
+
from typing_extensions import Literal
|
|
5
|
+
|
|
6
|
+
from pydantic import Field as FieldInfo
|
|
7
|
+
|
|
8
|
+
from .._models import BaseModel
|
|
9
|
+
|
|
10
|
+
__all__ = ["FaxMediaProcessedWebhookEvent", "Payload"]
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
class Payload(BaseModel):
|
|
14
|
+
client_state: Optional[str] = None
|
|
15
|
+
"""State received from a command."""
|
|
16
|
+
|
|
17
|
+
connection_id: Optional[str] = None
|
|
18
|
+
"""The ID of the connection used to send the fax."""
|
|
19
|
+
|
|
20
|
+
direction: Optional[Literal["inbound", "outbound"]] = None
|
|
21
|
+
"""The direction of the fax."""
|
|
22
|
+
|
|
23
|
+
fax_id: Optional[str] = None
|
|
24
|
+
"""Identifies the fax."""
|
|
25
|
+
|
|
26
|
+
from_: Optional[str] = FieldInfo(alias="from", default=None)
|
|
27
|
+
"""The phone number, in E.164 format, the fax will be sent from."""
|
|
28
|
+
|
|
29
|
+
media_name: Optional[str] = None
|
|
30
|
+
"""The media_name used for the fax's media.
|
|
31
|
+
|
|
32
|
+
Must point to a file previously uploaded to api.telnyx.com/v2/media by the same
|
|
33
|
+
user/organization. media_name and media_url/contents can't be submitted
|
|
34
|
+
together.
|
|
35
|
+
"""
|
|
36
|
+
|
|
37
|
+
original_media_url: Optional[str] = None
|
|
38
|
+
"""The original URL to the PDF used for the fax's media.
|
|
39
|
+
|
|
40
|
+
If media_name was supplied, this is omitted
|
|
41
|
+
"""
|
|
42
|
+
|
|
43
|
+
status: Optional[Literal["media.processed"]] = None
|
|
44
|
+
"""The status of the fax."""
|
|
45
|
+
|
|
46
|
+
to: Optional[str] = None
|
|
47
|
+
"""The phone number, in E.164 format, the fax will be sent to or SIP URI"""
|
|
48
|
+
|
|
49
|
+
user_id: Optional[str] = None
|
|
50
|
+
"""Identifier of the user to whom the fax belongs"""
|
|
51
|
+
|
|
52
|
+
|
|
53
|
+
class FaxMediaProcessedWebhookEvent(BaseModel):
|
|
54
|
+
id: Optional[str] = None
|
|
55
|
+
"""Identifies the type of resource."""
|
|
56
|
+
|
|
57
|
+
event_type: Optional[Literal["fax.media.processed"]] = None
|
|
58
|
+
"""The type of event being delivered."""
|
|
59
|
+
|
|
60
|
+
payload: Optional[Payload] = None
|
|
61
|
+
|
|
62
|
+
record_type: Optional[Literal["event"]] = None
|
|
63
|
+
"""Identifies the type of the resource."""
|