syllable-sdk 0.35.56__py3-none-any.whl → 0.35.58__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.
- syllable_sdk/_version.py +3 -3
- syllable_sdk/channels.py +374 -2
- syllable_sdk/models/__init__.py +37 -0
- syllable_sdk/models/channel.py +8 -2
- syllable_sdk/models/channelconfigview.py +56 -0
- syllable_sdk/models/organizationchannelconfig.py +70 -0
- syllable_sdk/models/organizationchannelcreaterequest.py +82 -0
- syllable_sdk/models/organizationchannelupdaterequest.py +87 -0
- syllable_sdk/models/telephonyconfigurations.py +84 -0
- {syllable_sdk-0.35.56.dist-info → syllable_sdk-0.35.58.dist-info}/METADATA +3 -1
- {syllable_sdk-0.35.56.dist-info → syllable_sdk-0.35.58.dist-info}/RECORD +12 -7
- {syllable_sdk-0.35.56.dist-info → syllable_sdk-0.35.58.dist-info}/WHEEL +0 -0
syllable_sdk/_version.py
CHANGED
|
@@ -3,10 +3,10 @@
|
|
|
3
3
|
import importlib.metadata
|
|
4
4
|
|
|
5
5
|
__title__: str = "syllable-sdk"
|
|
6
|
-
__version__: str = "0.35.
|
|
6
|
+
__version__: str = "0.35.58"
|
|
7
7
|
__openapi_doc_version__: str = "0.0.2"
|
|
8
|
-
__gen_version__: str = "2.
|
|
9
|
-
__user_agent__: str = "speakeasy-sdk/python 0.35.
|
|
8
|
+
__gen_version__: str = "2.668.4"
|
|
9
|
+
__user_agent__: str = "speakeasy-sdk/python 0.35.58 2.668.4 0.0.2 syllable-sdk"
|
|
10
10
|
|
|
11
11
|
try:
|
|
12
12
|
if __package__ is not None:
|
syllable_sdk/channels.py
CHANGED
|
@@ -6,10 +6,10 @@ from syllable_sdk import errors, models, utils
|
|
|
6
6
|
from syllable_sdk._hooks import HookContext
|
|
7
7
|
from syllable_sdk.targets import Targets
|
|
8
8
|
from syllable_sdk.twilio import Twilio
|
|
9
|
-
from syllable_sdk.types import OptionalNullable, UNSET
|
|
9
|
+
from syllable_sdk.types import BaseModel, OptionalNullable, UNSET
|
|
10
10
|
from syllable_sdk.utils import get_security_from_env
|
|
11
11
|
from syllable_sdk.utils.unmarshal_json_response import unmarshal_json_response
|
|
12
|
-
from typing import Any, List, Mapping, Optional
|
|
12
|
+
from typing import Any, List, Mapping, Optional, Union, cast
|
|
13
13
|
|
|
14
14
|
|
|
15
15
|
class Channels(BaseSDK):
|
|
@@ -251,6 +251,378 @@ class Channels(BaseSDK):
|
|
|
251
251
|
|
|
252
252
|
raise errors.APIError("Unexpected response received", http_res)
|
|
253
253
|
|
|
254
|
+
def create(
|
|
255
|
+
self,
|
|
256
|
+
*,
|
|
257
|
+
request: Union[
|
|
258
|
+
models.OrganizationChannelCreateRequest,
|
|
259
|
+
models.OrganizationChannelCreateRequestTypedDict,
|
|
260
|
+
],
|
|
261
|
+
retries: OptionalNullable[utils.RetryConfig] = UNSET,
|
|
262
|
+
server_url: Optional[str] = None,
|
|
263
|
+
timeout_ms: Optional[int] = None,
|
|
264
|
+
http_headers: Optional[Mapping[str, str]] = None,
|
|
265
|
+
) -> models.Channel:
|
|
266
|
+
r"""Create Channel
|
|
267
|
+
|
|
268
|
+
:param request: The request object to send.
|
|
269
|
+
:param retries: Override the default retry configuration for this method
|
|
270
|
+
:param server_url: Override the default server URL for this method
|
|
271
|
+
:param timeout_ms: Override the default request timeout configuration for this method in milliseconds
|
|
272
|
+
:param http_headers: Additional headers to set or replace on requests.
|
|
273
|
+
"""
|
|
274
|
+
base_url = None
|
|
275
|
+
url_variables = None
|
|
276
|
+
if timeout_ms is None:
|
|
277
|
+
timeout_ms = self.sdk_configuration.timeout_ms
|
|
278
|
+
|
|
279
|
+
if server_url is not None:
|
|
280
|
+
base_url = server_url
|
|
281
|
+
else:
|
|
282
|
+
base_url = self._get_url(base_url, url_variables)
|
|
283
|
+
|
|
284
|
+
if not isinstance(request, BaseModel):
|
|
285
|
+
request = utils.unmarshal(request, models.OrganizationChannelCreateRequest)
|
|
286
|
+
request = cast(models.OrganizationChannelCreateRequest, request)
|
|
287
|
+
|
|
288
|
+
req = self._build_request(
|
|
289
|
+
method="POST",
|
|
290
|
+
path="/api/v1/channels/",
|
|
291
|
+
base_url=base_url,
|
|
292
|
+
url_variables=url_variables,
|
|
293
|
+
request=request,
|
|
294
|
+
request_body_required=True,
|
|
295
|
+
request_has_path_params=False,
|
|
296
|
+
request_has_query_params=True,
|
|
297
|
+
user_agent_header="user-agent",
|
|
298
|
+
accept_header_value="application/json",
|
|
299
|
+
http_headers=http_headers,
|
|
300
|
+
security=self.sdk_configuration.security,
|
|
301
|
+
get_serialized_body=lambda: utils.serialize_request_body(
|
|
302
|
+
request, False, False, "json", models.OrganizationChannelCreateRequest
|
|
303
|
+
),
|
|
304
|
+
timeout_ms=timeout_ms,
|
|
305
|
+
)
|
|
306
|
+
|
|
307
|
+
if retries == UNSET:
|
|
308
|
+
if self.sdk_configuration.retry_config is not UNSET:
|
|
309
|
+
retries = self.sdk_configuration.retry_config
|
|
310
|
+
|
|
311
|
+
retry_config = None
|
|
312
|
+
if isinstance(retries, utils.RetryConfig):
|
|
313
|
+
retry_config = (retries, ["429", "500", "502", "503", "504"])
|
|
314
|
+
|
|
315
|
+
http_res = self.do_request(
|
|
316
|
+
hook_ctx=HookContext(
|
|
317
|
+
config=self.sdk_configuration,
|
|
318
|
+
base_url=base_url or "",
|
|
319
|
+
operation_id="channels_create",
|
|
320
|
+
oauth2_scopes=[],
|
|
321
|
+
security_source=get_security_from_env(
|
|
322
|
+
self.sdk_configuration.security, models.Security
|
|
323
|
+
),
|
|
324
|
+
),
|
|
325
|
+
request=req,
|
|
326
|
+
error_status_codes=["422", "4XX", "5XX"],
|
|
327
|
+
retry_config=retry_config,
|
|
328
|
+
)
|
|
329
|
+
|
|
330
|
+
response_data: Any = None
|
|
331
|
+
if utils.match_response(http_res, "200", "application/json"):
|
|
332
|
+
return unmarshal_json_response(models.Channel, http_res)
|
|
333
|
+
if utils.match_response(http_res, "422", "application/json"):
|
|
334
|
+
response_data = unmarshal_json_response(
|
|
335
|
+
errors.HTTPValidationErrorData, http_res
|
|
336
|
+
)
|
|
337
|
+
raise errors.HTTPValidationError(response_data, http_res)
|
|
338
|
+
if utils.match_response(http_res, "4XX", "*"):
|
|
339
|
+
http_res_text = utils.stream_to_text(http_res)
|
|
340
|
+
raise errors.APIError("API error occurred", http_res, http_res_text)
|
|
341
|
+
if utils.match_response(http_res, "5XX", "*"):
|
|
342
|
+
http_res_text = utils.stream_to_text(http_res)
|
|
343
|
+
raise errors.APIError("API error occurred", http_res, http_res_text)
|
|
344
|
+
|
|
345
|
+
raise errors.APIError("Unexpected response received", http_res)
|
|
346
|
+
|
|
347
|
+
async def create_async(
|
|
348
|
+
self,
|
|
349
|
+
*,
|
|
350
|
+
request: Union[
|
|
351
|
+
models.OrganizationChannelCreateRequest,
|
|
352
|
+
models.OrganizationChannelCreateRequestTypedDict,
|
|
353
|
+
],
|
|
354
|
+
retries: OptionalNullable[utils.RetryConfig] = UNSET,
|
|
355
|
+
server_url: Optional[str] = None,
|
|
356
|
+
timeout_ms: Optional[int] = None,
|
|
357
|
+
http_headers: Optional[Mapping[str, str]] = None,
|
|
358
|
+
) -> models.Channel:
|
|
359
|
+
r"""Create Channel
|
|
360
|
+
|
|
361
|
+
:param request: The request object to send.
|
|
362
|
+
:param retries: Override the default retry configuration for this method
|
|
363
|
+
:param server_url: Override the default server URL for this method
|
|
364
|
+
:param timeout_ms: Override the default request timeout configuration for this method in milliseconds
|
|
365
|
+
:param http_headers: Additional headers to set or replace on requests.
|
|
366
|
+
"""
|
|
367
|
+
base_url = None
|
|
368
|
+
url_variables = None
|
|
369
|
+
if timeout_ms is None:
|
|
370
|
+
timeout_ms = self.sdk_configuration.timeout_ms
|
|
371
|
+
|
|
372
|
+
if server_url is not None:
|
|
373
|
+
base_url = server_url
|
|
374
|
+
else:
|
|
375
|
+
base_url = self._get_url(base_url, url_variables)
|
|
376
|
+
|
|
377
|
+
if not isinstance(request, BaseModel):
|
|
378
|
+
request = utils.unmarshal(request, models.OrganizationChannelCreateRequest)
|
|
379
|
+
request = cast(models.OrganizationChannelCreateRequest, request)
|
|
380
|
+
|
|
381
|
+
req = self._build_request_async(
|
|
382
|
+
method="POST",
|
|
383
|
+
path="/api/v1/channels/",
|
|
384
|
+
base_url=base_url,
|
|
385
|
+
url_variables=url_variables,
|
|
386
|
+
request=request,
|
|
387
|
+
request_body_required=True,
|
|
388
|
+
request_has_path_params=False,
|
|
389
|
+
request_has_query_params=True,
|
|
390
|
+
user_agent_header="user-agent",
|
|
391
|
+
accept_header_value="application/json",
|
|
392
|
+
http_headers=http_headers,
|
|
393
|
+
security=self.sdk_configuration.security,
|
|
394
|
+
get_serialized_body=lambda: utils.serialize_request_body(
|
|
395
|
+
request, False, False, "json", models.OrganizationChannelCreateRequest
|
|
396
|
+
),
|
|
397
|
+
timeout_ms=timeout_ms,
|
|
398
|
+
)
|
|
399
|
+
|
|
400
|
+
if retries == UNSET:
|
|
401
|
+
if self.sdk_configuration.retry_config is not UNSET:
|
|
402
|
+
retries = self.sdk_configuration.retry_config
|
|
403
|
+
|
|
404
|
+
retry_config = None
|
|
405
|
+
if isinstance(retries, utils.RetryConfig):
|
|
406
|
+
retry_config = (retries, ["429", "500", "502", "503", "504"])
|
|
407
|
+
|
|
408
|
+
http_res = await self.do_request_async(
|
|
409
|
+
hook_ctx=HookContext(
|
|
410
|
+
config=self.sdk_configuration,
|
|
411
|
+
base_url=base_url or "",
|
|
412
|
+
operation_id="channels_create",
|
|
413
|
+
oauth2_scopes=[],
|
|
414
|
+
security_source=get_security_from_env(
|
|
415
|
+
self.sdk_configuration.security, models.Security
|
|
416
|
+
),
|
|
417
|
+
),
|
|
418
|
+
request=req,
|
|
419
|
+
error_status_codes=["422", "4XX", "5XX"],
|
|
420
|
+
retry_config=retry_config,
|
|
421
|
+
)
|
|
422
|
+
|
|
423
|
+
response_data: Any = None
|
|
424
|
+
if utils.match_response(http_res, "200", "application/json"):
|
|
425
|
+
return unmarshal_json_response(models.Channel, http_res)
|
|
426
|
+
if utils.match_response(http_res, "422", "application/json"):
|
|
427
|
+
response_data = unmarshal_json_response(
|
|
428
|
+
errors.HTTPValidationErrorData, http_res
|
|
429
|
+
)
|
|
430
|
+
raise errors.HTTPValidationError(response_data, http_res)
|
|
431
|
+
if utils.match_response(http_res, "4XX", "*"):
|
|
432
|
+
http_res_text = await utils.stream_to_text_async(http_res)
|
|
433
|
+
raise errors.APIError("API error occurred", http_res, http_res_text)
|
|
434
|
+
if utils.match_response(http_res, "5XX", "*"):
|
|
435
|
+
http_res_text = await utils.stream_to_text_async(http_res)
|
|
436
|
+
raise errors.APIError("API error occurred", http_res, http_res_text)
|
|
437
|
+
|
|
438
|
+
raise errors.APIError("Unexpected response received", http_res)
|
|
439
|
+
|
|
440
|
+
def update(
|
|
441
|
+
self,
|
|
442
|
+
*,
|
|
443
|
+
request: Union[
|
|
444
|
+
models.OrganizationChannelUpdateRequest,
|
|
445
|
+
models.OrganizationChannelUpdateRequestTypedDict,
|
|
446
|
+
],
|
|
447
|
+
retries: OptionalNullable[utils.RetryConfig] = UNSET,
|
|
448
|
+
server_url: Optional[str] = None,
|
|
449
|
+
timeout_ms: Optional[int] = None,
|
|
450
|
+
http_headers: Optional[Mapping[str, str]] = None,
|
|
451
|
+
) -> models.Channel:
|
|
452
|
+
r"""Update Channel
|
|
453
|
+
|
|
454
|
+
:param request: The request object to send.
|
|
455
|
+
:param retries: Override the default retry configuration for this method
|
|
456
|
+
:param server_url: Override the default server URL for this method
|
|
457
|
+
:param timeout_ms: Override the default request timeout configuration for this method in milliseconds
|
|
458
|
+
:param http_headers: Additional headers to set or replace on requests.
|
|
459
|
+
"""
|
|
460
|
+
base_url = None
|
|
461
|
+
url_variables = None
|
|
462
|
+
if timeout_ms is None:
|
|
463
|
+
timeout_ms = self.sdk_configuration.timeout_ms
|
|
464
|
+
|
|
465
|
+
if server_url is not None:
|
|
466
|
+
base_url = server_url
|
|
467
|
+
else:
|
|
468
|
+
base_url = self._get_url(base_url, url_variables)
|
|
469
|
+
|
|
470
|
+
if not isinstance(request, BaseModel):
|
|
471
|
+
request = utils.unmarshal(request, models.OrganizationChannelUpdateRequest)
|
|
472
|
+
request = cast(models.OrganizationChannelUpdateRequest, request)
|
|
473
|
+
|
|
474
|
+
req = self._build_request(
|
|
475
|
+
method="PUT",
|
|
476
|
+
path="/api/v1/channels/",
|
|
477
|
+
base_url=base_url,
|
|
478
|
+
url_variables=url_variables,
|
|
479
|
+
request=request,
|
|
480
|
+
request_body_required=True,
|
|
481
|
+
request_has_path_params=False,
|
|
482
|
+
request_has_query_params=True,
|
|
483
|
+
user_agent_header="user-agent",
|
|
484
|
+
accept_header_value="application/json",
|
|
485
|
+
http_headers=http_headers,
|
|
486
|
+
security=self.sdk_configuration.security,
|
|
487
|
+
get_serialized_body=lambda: utils.serialize_request_body(
|
|
488
|
+
request, False, False, "json", models.OrganizationChannelUpdateRequest
|
|
489
|
+
),
|
|
490
|
+
timeout_ms=timeout_ms,
|
|
491
|
+
)
|
|
492
|
+
|
|
493
|
+
if retries == UNSET:
|
|
494
|
+
if self.sdk_configuration.retry_config is not UNSET:
|
|
495
|
+
retries = self.sdk_configuration.retry_config
|
|
496
|
+
|
|
497
|
+
retry_config = None
|
|
498
|
+
if isinstance(retries, utils.RetryConfig):
|
|
499
|
+
retry_config = (retries, ["429", "500", "502", "503", "504"])
|
|
500
|
+
|
|
501
|
+
http_res = self.do_request(
|
|
502
|
+
hook_ctx=HookContext(
|
|
503
|
+
config=self.sdk_configuration,
|
|
504
|
+
base_url=base_url or "",
|
|
505
|
+
operation_id="channels_update",
|
|
506
|
+
oauth2_scopes=[],
|
|
507
|
+
security_source=get_security_from_env(
|
|
508
|
+
self.sdk_configuration.security, models.Security
|
|
509
|
+
),
|
|
510
|
+
),
|
|
511
|
+
request=req,
|
|
512
|
+
error_status_codes=["422", "4XX", "5XX"],
|
|
513
|
+
retry_config=retry_config,
|
|
514
|
+
)
|
|
515
|
+
|
|
516
|
+
response_data: Any = None
|
|
517
|
+
if utils.match_response(http_res, "200", "application/json"):
|
|
518
|
+
return unmarshal_json_response(models.Channel, http_res)
|
|
519
|
+
if utils.match_response(http_res, "422", "application/json"):
|
|
520
|
+
response_data = unmarshal_json_response(
|
|
521
|
+
errors.HTTPValidationErrorData, http_res
|
|
522
|
+
)
|
|
523
|
+
raise errors.HTTPValidationError(response_data, http_res)
|
|
524
|
+
if utils.match_response(http_res, "4XX", "*"):
|
|
525
|
+
http_res_text = utils.stream_to_text(http_res)
|
|
526
|
+
raise errors.APIError("API error occurred", http_res, http_res_text)
|
|
527
|
+
if utils.match_response(http_res, "5XX", "*"):
|
|
528
|
+
http_res_text = utils.stream_to_text(http_res)
|
|
529
|
+
raise errors.APIError("API error occurred", http_res, http_res_text)
|
|
530
|
+
|
|
531
|
+
raise errors.APIError("Unexpected response received", http_res)
|
|
532
|
+
|
|
533
|
+
async def update_async(
|
|
534
|
+
self,
|
|
535
|
+
*,
|
|
536
|
+
request: Union[
|
|
537
|
+
models.OrganizationChannelUpdateRequest,
|
|
538
|
+
models.OrganizationChannelUpdateRequestTypedDict,
|
|
539
|
+
],
|
|
540
|
+
retries: OptionalNullable[utils.RetryConfig] = UNSET,
|
|
541
|
+
server_url: Optional[str] = None,
|
|
542
|
+
timeout_ms: Optional[int] = None,
|
|
543
|
+
http_headers: Optional[Mapping[str, str]] = None,
|
|
544
|
+
) -> models.Channel:
|
|
545
|
+
r"""Update Channel
|
|
546
|
+
|
|
547
|
+
:param request: The request object to send.
|
|
548
|
+
:param retries: Override the default retry configuration for this method
|
|
549
|
+
:param server_url: Override the default server URL for this method
|
|
550
|
+
:param timeout_ms: Override the default request timeout configuration for this method in milliseconds
|
|
551
|
+
:param http_headers: Additional headers to set or replace on requests.
|
|
552
|
+
"""
|
|
553
|
+
base_url = None
|
|
554
|
+
url_variables = None
|
|
555
|
+
if timeout_ms is None:
|
|
556
|
+
timeout_ms = self.sdk_configuration.timeout_ms
|
|
557
|
+
|
|
558
|
+
if server_url is not None:
|
|
559
|
+
base_url = server_url
|
|
560
|
+
else:
|
|
561
|
+
base_url = self._get_url(base_url, url_variables)
|
|
562
|
+
|
|
563
|
+
if not isinstance(request, BaseModel):
|
|
564
|
+
request = utils.unmarshal(request, models.OrganizationChannelUpdateRequest)
|
|
565
|
+
request = cast(models.OrganizationChannelUpdateRequest, request)
|
|
566
|
+
|
|
567
|
+
req = self._build_request_async(
|
|
568
|
+
method="PUT",
|
|
569
|
+
path="/api/v1/channels/",
|
|
570
|
+
base_url=base_url,
|
|
571
|
+
url_variables=url_variables,
|
|
572
|
+
request=request,
|
|
573
|
+
request_body_required=True,
|
|
574
|
+
request_has_path_params=False,
|
|
575
|
+
request_has_query_params=True,
|
|
576
|
+
user_agent_header="user-agent",
|
|
577
|
+
accept_header_value="application/json",
|
|
578
|
+
http_headers=http_headers,
|
|
579
|
+
security=self.sdk_configuration.security,
|
|
580
|
+
get_serialized_body=lambda: utils.serialize_request_body(
|
|
581
|
+
request, False, False, "json", models.OrganizationChannelUpdateRequest
|
|
582
|
+
),
|
|
583
|
+
timeout_ms=timeout_ms,
|
|
584
|
+
)
|
|
585
|
+
|
|
586
|
+
if retries == UNSET:
|
|
587
|
+
if self.sdk_configuration.retry_config is not UNSET:
|
|
588
|
+
retries = self.sdk_configuration.retry_config
|
|
589
|
+
|
|
590
|
+
retry_config = None
|
|
591
|
+
if isinstance(retries, utils.RetryConfig):
|
|
592
|
+
retry_config = (retries, ["429", "500", "502", "503", "504"])
|
|
593
|
+
|
|
594
|
+
http_res = await self.do_request_async(
|
|
595
|
+
hook_ctx=HookContext(
|
|
596
|
+
config=self.sdk_configuration,
|
|
597
|
+
base_url=base_url or "",
|
|
598
|
+
operation_id="channels_update",
|
|
599
|
+
oauth2_scopes=[],
|
|
600
|
+
security_source=get_security_from_env(
|
|
601
|
+
self.sdk_configuration.security, models.Security
|
|
602
|
+
),
|
|
603
|
+
),
|
|
604
|
+
request=req,
|
|
605
|
+
error_status_codes=["422", "4XX", "5XX"],
|
|
606
|
+
retry_config=retry_config,
|
|
607
|
+
)
|
|
608
|
+
|
|
609
|
+
response_data: Any = None
|
|
610
|
+
if utils.match_response(http_res, "200", "application/json"):
|
|
611
|
+
return unmarshal_json_response(models.Channel, http_res)
|
|
612
|
+
if utils.match_response(http_res, "422", "application/json"):
|
|
613
|
+
response_data = unmarshal_json_response(
|
|
614
|
+
errors.HTTPValidationErrorData, http_res
|
|
615
|
+
)
|
|
616
|
+
raise errors.HTTPValidationError(response_data, http_res)
|
|
617
|
+
if utils.match_response(http_res, "4XX", "*"):
|
|
618
|
+
http_res_text = await utils.stream_to_text_async(http_res)
|
|
619
|
+
raise errors.APIError("API error occurred", http_res, http_res_text)
|
|
620
|
+
if utils.match_response(http_res, "5XX", "*"):
|
|
621
|
+
http_res_text = await utils.stream_to_text_async(http_res)
|
|
622
|
+
raise errors.APIError("API error occurred", http_res, http_res_text)
|
|
623
|
+
|
|
624
|
+
raise errors.APIError("Unexpected response received", http_res)
|
|
625
|
+
|
|
254
626
|
def delete(
|
|
255
627
|
self,
|
|
256
628
|
*,
|
syllable_sdk/models/__init__.py
CHANGED
|
@@ -88,6 +88,7 @@ if TYPE_CHECKING:
|
|
|
88
88
|
ChannelTargetsUpdateRequest,
|
|
89
89
|
ChannelTargetsUpdateRequestTypedDict,
|
|
90
90
|
)
|
|
91
|
+
from .channelconfigview import ChannelConfigView, ChannelConfigViewTypedDict
|
|
91
92
|
from .channelproperties import ChannelProperties
|
|
92
93
|
from .channels_listop import ChannelsListRequest, ChannelsListRequestTypedDict
|
|
93
94
|
from .channels_twilio_get_by_idop import (
|
|
@@ -519,6 +520,18 @@ if TYPE_CHECKING:
|
|
|
519
520
|
)
|
|
520
521
|
from .logintype import LoginType
|
|
521
522
|
from .orderbydirection import OrderByDirection
|
|
523
|
+
from .organizationchannelconfig import (
|
|
524
|
+
OrganizationChannelConfig,
|
|
525
|
+
OrganizationChannelConfigTypedDict,
|
|
526
|
+
)
|
|
527
|
+
from .organizationchannelcreaterequest import (
|
|
528
|
+
OrganizationChannelCreateRequest,
|
|
529
|
+
OrganizationChannelCreateRequestTypedDict,
|
|
530
|
+
)
|
|
531
|
+
from .organizationchannelupdaterequest import (
|
|
532
|
+
OrganizationChannelUpdateRequest,
|
|
533
|
+
OrganizationChannelUpdateRequestTypedDict,
|
|
534
|
+
)
|
|
522
535
|
from .organizationresponse import (
|
|
523
536
|
OrganizationResponse,
|
|
524
537
|
OrganizationResponseTypedDict,
|
|
@@ -696,6 +709,10 @@ if TYPE_CHECKING:
|
|
|
696
709
|
TakeoutStatusResponseTypedDict,
|
|
697
710
|
)
|
|
698
711
|
from .targetmodes import TargetModes
|
|
712
|
+
from .telephonyconfigurations import (
|
|
713
|
+
TelephonyConfigurations,
|
|
714
|
+
TelephonyConfigurationsTypedDict,
|
|
715
|
+
)
|
|
699
716
|
from .testmessage import TestMessage, TestMessageTypedDict
|
|
700
717
|
from .testmessageresponse import TestMessageResponse, TestMessageResponseTypedDict
|
|
701
718
|
from .tool_deleteop import ToolDeleteRequest, ToolDeleteRequestTypedDict
|
|
@@ -866,6 +883,8 @@ __all__ = [
|
|
|
866
883
|
"BodyOutboundBatchUploadTypedDict",
|
|
867
884
|
"CampaignProperties",
|
|
868
885
|
"Channel",
|
|
886
|
+
"ChannelConfigView",
|
|
887
|
+
"ChannelConfigViewTypedDict",
|
|
869
888
|
"ChannelProperties",
|
|
870
889
|
"ChannelServices",
|
|
871
890
|
"ChannelTargetCreateRequest",
|
|
@@ -1148,6 +1167,12 @@ __all__ = [
|
|
|
1148
1167
|
"Metadata",
|
|
1149
1168
|
"MetadataTypedDict",
|
|
1150
1169
|
"OrderByDirection",
|
|
1170
|
+
"OrganizationChannelConfig",
|
|
1171
|
+
"OrganizationChannelConfigTypedDict",
|
|
1172
|
+
"OrganizationChannelCreateRequest",
|
|
1173
|
+
"OrganizationChannelCreateRequestTypedDict",
|
|
1174
|
+
"OrganizationChannelUpdateRequest",
|
|
1175
|
+
"OrganizationChannelUpdateRequestTypedDict",
|
|
1151
1176
|
"OrganizationResponse",
|
|
1152
1177
|
"OrganizationResponseTypedDict",
|
|
1153
1178
|
"OutboundBatchAddRequest",
|
|
@@ -1290,6 +1315,8 @@ __all__ = [
|
|
|
1290
1315
|
"TakeoutsGetFileRequest",
|
|
1291
1316
|
"TakeoutsGetFileRequestTypedDict",
|
|
1292
1317
|
"TargetModes",
|
|
1318
|
+
"TelephonyConfigurations",
|
|
1319
|
+
"TelephonyConfigurationsTypedDict",
|
|
1293
1320
|
"TestMessage",
|
|
1294
1321
|
"TestMessageResponse",
|
|
1295
1322
|
"TestMessageResponseTypedDict",
|
|
@@ -1444,6 +1471,8 @@ _dynamic_imports: dict[str, str] = {
|
|
|
1444
1471
|
"ChannelTargetsListRequestTypedDict": ".channel_targets_listop",
|
|
1445
1472
|
"ChannelTargetsUpdateRequest": ".channel_targets_updateop",
|
|
1446
1473
|
"ChannelTargetsUpdateRequestTypedDict": ".channel_targets_updateop",
|
|
1474
|
+
"ChannelConfigView": ".channelconfigview",
|
|
1475
|
+
"ChannelConfigViewTypedDict": ".channelconfigview",
|
|
1447
1476
|
"ChannelProperties": ".channelproperties",
|
|
1448
1477
|
"ChannelsListRequest": ".channels_listop",
|
|
1449
1478
|
"ChannelsListRequestTypedDict": ".channels_listop",
|
|
@@ -1715,6 +1744,12 @@ _dynamic_imports: dict[str, str] = {
|
|
|
1715
1744
|
"ListResponseUserResponseTypedDict": ".listresponse_userresponse_",
|
|
1716
1745
|
"LoginType": ".logintype",
|
|
1717
1746
|
"OrderByDirection": ".orderbydirection",
|
|
1747
|
+
"OrganizationChannelConfig": ".organizationchannelconfig",
|
|
1748
|
+
"OrganizationChannelConfigTypedDict": ".organizationchannelconfig",
|
|
1749
|
+
"OrganizationChannelCreateRequest": ".organizationchannelcreaterequest",
|
|
1750
|
+
"OrganizationChannelCreateRequestTypedDict": ".organizationchannelcreaterequest",
|
|
1751
|
+
"OrganizationChannelUpdateRequest": ".organizationchannelupdaterequest",
|
|
1752
|
+
"OrganizationChannelUpdateRequestTypedDict": ".organizationchannelupdaterequest",
|
|
1718
1753
|
"OrganizationResponse": ".organizationresponse",
|
|
1719
1754
|
"OrganizationResponseTypedDict": ".organizationresponse",
|
|
1720
1755
|
"OutboundBatchAddRequest": ".outbound_batch_addop",
|
|
@@ -1855,6 +1890,8 @@ _dynamic_imports: dict[str, str] = {
|
|
|
1855
1890
|
"TakeoutStatusResponse": ".takeoutstatusresponse",
|
|
1856
1891
|
"TakeoutStatusResponseTypedDict": ".takeoutstatusresponse",
|
|
1857
1892
|
"TargetModes": ".targetmodes",
|
|
1893
|
+
"TelephonyConfigurations": ".telephonyconfigurations",
|
|
1894
|
+
"TelephonyConfigurationsTypedDict": ".telephonyconfigurations",
|
|
1858
1895
|
"TestMessage": ".testmessage",
|
|
1859
1896
|
"TestMessageTypedDict": ".testmessage",
|
|
1860
1897
|
"TestMessageResponse": ".testmessageresponse",
|
syllable_sdk/models/channel.py
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT."""
|
|
2
2
|
|
|
3
3
|
from __future__ import annotations
|
|
4
|
+
from .channelconfigview import ChannelConfigView, ChannelConfigViewTypedDict
|
|
4
5
|
from .channelservices import ChannelServices
|
|
5
6
|
from pydantic import model_serializer
|
|
6
7
|
from syllable_sdk.types import (
|
|
@@ -25,6 +26,8 @@ class ChannelTypedDict(TypedDict):
|
|
|
25
26
|
r"""The comma-delimited list of supported modes for the channel, which defines the possible communication methods for channel targets linked to it."""
|
|
26
27
|
is_system_channel: NotRequired[bool]
|
|
27
28
|
r"""Whether the channel is a built-in system channel (i.e., is not customizable)"""
|
|
29
|
+
config: NotRequired[Nullable[ChannelConfigViewTypedDict]]
|
|
30
|
+
r"""Configuration for the channel"""
|
|
28
31
|
|
|
29
32
|
|
|
30
33
|
class Channel(BaseModel):
|
|
@@ -43,10 +46,13 @@ class Channel(BaseModel):
|
|
|
43
46
|
is_system_channel: Optional[bool] = True
|
|
44
47
|
r"""Whether the channel is a built-in system channel (i.e., is not customizable)"""
|
|
45
48
|
|
|
49
|
+
config: OptionalNullable[ChannelConfigView] = UNSET
|
|
50
|
+
r"""Configuration for the channel"""
|
|
51
|
+
|
|
46
52
|
@model_serializer(mode="wrap")
|
|
47
53
|
def serialize_model(self, handler):
|
|
48
|
-
optional_fields = ["supported_modes", "is_system_channel"]
|
|
49
|
-
nullable_fields = ["supported_modes"]
|
|
54
|
+
optional_fields = ["supported_modes", "is_system_channel", "config"]
|
|
55
|
+
nullable_fields = ["supported_modes", "config"]
|
|
50
56
|
null_default_fields = []
|
|
51
57
|
|
|
52
58
|
serialized = handler(self)
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT."""
|
|
2
|
+
|
|
3
|
+
from __future__ import annotations
|
|
4
|
+
from .telephonyconfigurations import (
|
|
5
|
+
TelephonyConfigurations,
|
|
6
|
+
TelephonyConfigurationsTypedDict,
|
|
7
|
+
)
|
|
8
|
+
from pydantic import model_serializer
|
|
9
|
+
from syllable_sdk.types import (
|
|
10
|
+
BaseModel,
|
|
11
|
+
Nullable,
|
|
12
|
+
OptionalNullable,
|
|
13
|
+
UNSET,
|
|
14
|
+
UNSET_SENTINEL,
|
|
15
|
+
)
|
|
16
|
+
from typing_extensions import NotRequired, TypedDict
|
|
17
|
+
|
|
18
|
+
|
|
19
|
+
class ChannelConfigViewTypedDict(TypedDict):
|
|
20
|
+
telephony: NotRequired[Nullable[TelephonyConfigurationsTypedDict]]
|
|
21
|
+
r"""Telephony configurations to be applied to targets belonging to the channel. Only applies to voice supported channels."""
|
|
22
|
+
|
|
23
|
+
|
|
24
|
+
class ChannelConfigView(BaseModel):
|
|
25
|
+
telephony: OptionalNullable[TelephonyConfigurations] = UNSET
|
|
26
|
+
r"""Telephony configurations to be applied to targets belonging to the channel. Only applies to voice supported channels."""
|
|
27
|
+
|
|
28
|
+
@model_serializer(mode="wrap")
|
|
29
|
+
def serialize_model(self, handler):
|
|
30
|
+
optional_fields = ["telephony"]
|
|
31
|
+
nullable_fields = ["telephony"]
|
|
32
|
+
null_default_fields = []
|
|
33
|
+
|
|
34
|
+
serialized = handler(self)
|
|
35
|
+
|
|
36
|
+
m = {}
|
|
37
|
+
|
|
38
|
+
for n, f in type(self).model_fields.items():
|
|
39
|
+
k = f.alias or n
|
|
40
|
+
val = serialized.get(k)
|
|
41
|
+
serialized.pop(k, None)
|
|
42
|
+
|
|
43
|
+
optional_nullable = k in optional_fields and k in nullable_fields
|
|
44
|
+
is_set = (
|
|
45
|
+
self.__pydantic_fields_set__.intersection({n})
|
|
46
|
+
or k in null_default_fields
|
|
47
|
+
) # pylint: disable=no-member
|
|
48
|
+
|
|
49
|
+
if val is not None and val != UNSET_SENTINEL:
|
|
50
|
+
m[k] = val
|
|
51
|
+
elif val != UNSET_SENTINEL and (
|
|
52
|
+
not k in optional_fields or (optional_nullable and is_set)
|
|
53
|
+
):
|
|
54
|
+
m[k] = val
|
|
55
|
+
|
|
56
|
+
return m
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT."""
|
|
2
|
+
|
|
3
|
+
from __future__ import annotations
|
|
4
|
+
from .telephonyconfigurations import (
|
|
5
|
+
TelephonyConfigurations,
|
|
6
|
+
TelephonyConfigurationsTypedDict,
|
|
7
|
+
)
|
|
8
|
+
from pydantic import model_serializer
|
|
9
|
+
from syllable_sdk.types import (
|
|
10
|
+
BaseModel,
|
|
11
|
+
Nullable,
|
|
12
|
+
OptionalNullable,
|
|
13
|
+
UNSET,
|
|
14
|
+
UNSET_SENTINEL,
|
|
15
|
+
)
|
|
16
|
+
from typing_extensions import NotRequired, TypedDict
|
|
17
|
+
|
|
18
|
+
|
|
19
|
+
class OrganizationChannelConfigTypedDict(TypedDict):
|
|
20
|
+
r"""Channel config information for creates / updates through the organizations API"""
|
|
21
|
+
|
|
22
|
+
account_sid: NotRequired[Nullable[str]]
|
|
23
|
+
r"""SID of the Twilio account"""
|
|
24
|
+
auth_token: NotRequired[Nullable[str]]
|
|
25
|
+
r"""The Twilio auth token"""
|
|
26
|
+
telephony: NotRequired[Nullable[TelephonyConfigurationsTypedDict]]
|
|
27
|
+
r"""Telephony configurations to be applied to the targets under the channel"""
|
|
28
|
+
|
|
29
|
+
|
|
30
|
+
class OrganizationChannelConfig(BaseModel):
|
|
31
|
+
r"""Channel config information for creates / updates through the organizations API"""
|
|
32
|
+
|
|
33
|
+
account_sid: OptionalNullable[str] = UNSET
|
|
34
|
+
r"""SID of the Twilio account"""
|
|
35
|
+
|
|
36
|
+
auth_token: OptionalNullable[str] = UNSET
|
|
37
|
+
r"""The Twilio auth token"""
|
|
38
|
+
|
|
39
|
+
telephony: OptionalNullable[TelephonyConfigurations] = UNSET
|
|
40
|
+
r"""Telephony configurations to be applied to the targets under the channel"""
|
|
41
|
+
|
|
42
|
+
@model_serializer(mode="wrap")
|
|
43
|
+
def serialize_model(self, handler):
|
|
44
|
+
optional_fields = ["account_sid", "auth_token", "telephony"]
|
|
45
|
+
nullable_fields = ["account_sid", "auth_token", "telephony"]
|
|
46
|
+
null_default_fields = []
|
|
47
|
+
|
|
48
|
+
serialized = handler(self)
|
|
49
|
+
|
|
50
|
+
m = {}
|
|
51
|
+
|
|
52
|
+
for n, f in type(self).model_fields.items():
|
|
53
|
+
k = f.alias or n
|
|
54
|
+
val = serialized.get(k)
|
|
55
|
+
serialized.pop(k, None)
|
|
56
|
+
|
|
57
|
+
optional_nullable = k in optional_fields and k in nullable_fields
|
|
58
|
+
is_set = (
|
|
59
|
+
self.__pydantic_fields_set__.intersection({n})
|
|
60
|
+
or k in null_default_fields
|
|
61
|
+
) # pylint: disable=no-member
|
|
62
|
+
|
|
63
|
+
if val is not None and val != UNSET_SENTINEL:
|
|
64
|
+
m[k] = val
|
|
65
|
+
elif val != UNSET_SENTINEL and (
|
|
66
|
+
not k in optional_fields or (optional_nullable and is_set)
|
|
67
|
+
):
|
|
68
|
+
m[k] = val
|
|
69
|
+
|
|
70
|
+
return m
|
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT."""
|
|
2
|
+
|
|
3
|
+
from __future__ import annotations
|
|
4
|
+
from .channelservices import ChannelServices
|
|
5
|
+
from .organizationchannelconfig import (
|
|
6
|
+
OrganizationChannelConfig,
|
|
7
|
+
OrganizationChannelConfigTypedDict,
|
|
8
|
+
)
|
|
9
|
+
from pydantic import model_serializer
|
|
10
|
+
from syllable_sdk.types import (
|
|
11
|
+
BaseModel,
|
|
12
|
+
Nullable,
|
|
13
|
+
OptionalNullable,
|
|
14
|
+
UNSET,
|
|
15
|
+
UNSET_SENTINEL,
|
|
16
|
+
)
|
|
17
|
+
from typing import Optional
|
|
18
|
+
from typing_extensions import NotRequired, TypedDict
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
class OrganizationChannelCreateRequestTypedDict(TypedDict):
|
|
22
|
+
r"""Request model to create a channel through the organizations API"""
|
|
23
|
+
|
|
24
|
+
name: str
|
|
25
|
+
r"""The channel name"""
|
|
26
|
+
channel_service: ChannelServices
|
|
27
|
+
r"""The communication service for a channel."""
|
|
28
|
+
config: OrganizationChannelConfigTypedDict
|
|
29
|
+
r"""Channel config information for creates / updates through the organizations API"""
|
|
30
|
+
supported_modes: NotRequired[Nullable[str]]
|
|
31
|
+
r"""The comma-delimited list of supported modes for the channel, which defines the possible communication methods for channel targets linked to it."""
|
|
32
|
+
is_system_channel: NotRequired[bool]
|
|
33
|
+
r"""Whether the channel is a built-in system channel (i.e., is not customizable)"""
|
|
34
|
+
|
|
35
|
+
|
|
36
|
+
class OrganizationChannelCreateRequest(BaseModel):
|
|
37
|
+
r"""Request model to create a channel through the organizations API"""
|
|
38
|
+
|
|
39
|
+
name: str
|
|
40
|
+
r"""The channel name"""
|
|
41
|
+
|
|
42
|
+
channel_service: ChannelServices
|
|
43
|
+
r"""The communication service for a channel."""
|
|
44
|
+
|
|
45
|
+
config: OrganizationChannelConfig
|
|
46
|
+
r"""Channel config information for creates / updates through the organizations API"""
|
|
47
|
+
|
|
48
|
+
supported_modes: OptionalNullable[str] = UNSET
|
|
49
|
+
r"""The comma-delimited list of supported modes for the channel, which defines the possible communication methods for channel targets linked to it."""
|
|
50
|
+
|
|
51
|
+
is_system_channel: Optional[bool] = True
|
|
52
|
+
r"""Whether the channel is a built-in system channel (i.e., is not customizable)"""
|
|
53
|
+
|
|
54
|
+
@model_serializer(mode="wrap")
|
|
55
|
+
def serialize_model(self, handler):
|
|
56
|
+
optional_fields = ["supported_modes", "is_system_channel"]
|
|
57
|
+
nullable_fields = ["supported_modes"]
|
|
58
|
+
null_default_fields = []
|
|
59
|
+
|
|
60
|
+
serialized = handler(self)
|
|
61
|
+
|
|
62
|
+
m = {}
|
|
63
|
+
|
|
64
|
+
for n, f in type(self).model_fields.items():
|
|
65
|
+
k = f.alias or n
|
|
66
|
+
val = serialized.get(k)
|
|
67
|
+
serialized.pop(k, None)
|
|
68
|
+
|
|
69
|
+
optional_nullable = k in optional_fields and k in nullable_fields
|
|
70
|
+
is_set = (
|
|
71
|
+
self.__pydantic_fields_set__.intersection({n})
|
|
72
|
+
or k in null_default_fields
|
|
73
|
+
) # pylint: disable=no-member
|
|
74
|
+
|
|
75
|
+
if val is not None and val != UNSET_SENTINEL:
|
|
76
|
+
m[k] = val
|
|
77
|
+
elif val != UNSET_SENTINEL and (
|
|
78
|
+
not k in optional_fields or (optional_nullable and is_set)
|
|
79
|
+
):
|
|
80
|
+
m[k] = val
|
|
81
|
+
|
|
82
|
+
return m
|
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT."""
|
|
2
|
+
|
|
3
|
+
from __future__ import annotations
|
|
4
|
+
from .channelservices import ChannelServices
|
|
5
|
+
from .organizationchannelconfig import (
|
|
6
|
+
OrganizationChannelConfig,
|
|
7
|
+
OrganizationChannelConfigTypedDict,
|
|
8
|
+
)
|
|
9
|
+
from pydantic import model_serializer
|
|
10
|
+
from syllable_sdk.types import (
|
|
11
|
+
BaseModel,
|
|
12
|
+
Nullable,
|
|
13
|
+
OptionalNullable,
|
|
14
|
+
UNSET,
|
|
15
|
+
UNSET_SENTINEL,
|
|
16
|
+
)
|
|
17
|
+
from typing import Optional
|
|
18
|
+
from typing_extensions import NotRequired, TypedDict
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
class OrganizationChannelUpdateRequestTypedDict(TypedDict):
|
|
22
|
+
r"""Request model to update a channel through the organizations API"""
|
|
23
|
+
|
|
24
|
+
name: str
|
|
25
|
+
r"""The channel name"""
|
|
26
|
+
channel_service: ChannelServices
|
|
27
|
+
r"""The communication service for a channel."""
|
|
28
|
+
config: OrganizationChannelConfigTypedDict
|
|
29
|
+
r"""Channel config information for creates / updates through the organizations API"""
|
|
30
|
+
id: int
|
|
31
|
+
r"""The internal ID of the channel"""
|
|
32
|
+
supported_modes: NotRequired[Nullable[str]]
|
|
33
|
+
r"""The comma-delimited list of supported modes for the channel, which defines the possible communication methods for channel targets linked to it."""
|
|
34
|
+
is_system_channel: NotRequired[bool]
|
|
35
|
+
r"""Whether the channel is a built-in system channel (i.e., is not customizable)"""
|
|
36
|
+
|
|
37
|
+
|
|
38
|
+
class OrganizationChannelUpdateRequest(BaseModel):
|
|
39
|
+
r"""Request model to update a channel through the organizations API"""
|
|
40
|
+
|
|
41
|
+
name: str
|
|
42
|
+
r"""The channel name"""
|
|
43
|
+
|
|
44
|
+
channel_service: ChannelServices
|
|
45
|
+
r"""The communication service for a channel."""
|
|
46
|
+
|
|
47
|
+
config: OrganizationChannelConfig
|
|
48
|
+
r"""Channel config information for creates / updates through the organizations API"""
|
|
49
|
+
|
|
50
|
+
id: int
|
|
51
|
+
r"""The internal ID of the channel"""
|
|
52
|
+
|
|
53
|
+
supported_modes: OptionalNullable[str] = UNSET
|
|
54
|
+
r"""The comma-delimited list of supported modes for the channel, which defines the possible communication methods for channel targets linked to it."""
|
|
55
|
+
|
|
56
|
+
is_system_channel: Optional[bool] = True
|
|
57
|
+
r"""Whether the channel is a built-in system channel (i.e., is not customizable)"""
|
|
58
|
+
|
|
59
|
+
@model_serializer(mode="wrap")
|
|
60
|
+
def serialize_model(self, handler):
|
|
61
|
+
optional_fields = ["supported_modes", "is_system_channel"]
|
|
62
|
+
nullable_fields = ["supported_modes"]
|
|
63
|
+
null_default_fields = []
|
|
64
|
+
|
|
65
|
+
serialized = handler(self)
|
|
66
|
+
|
|
67
|
+
m = {}
|
|
68
|
+
|
|
69
|
+
for n, f in type(self).model_fields.items():
|
|
70
|
+
k = f.alias or n
|
|
71
|
+
val = serialized.get(k)
|
|
72
|
+
serialized.pop(k, None)
|
|
73
|
+
|
|
74
|
+
optional_nullable = k in optional_fields and k in nullable_fields
|
|
75
|
+
is_set = (
|
|
76
|
+
self.__pydantic_fields_set__.intersection({n})
|
|
77
|
+
or k in null_default_fields
|
|
78
|
+
) # pylint: disable=no-member
|
|
79
|
+
|
|
80
|
+
if val is not None and val != UNSET_SENTINEL:
|
|
81
|
+
m[k] = val
|
|
82
|
+
elif val != UNSET_SENTINEL and (
|
|
83
|
+
not k in optional_fields or (optional_nullable and is_set)
|
|
84
|
+
):
|
|
85
|
+
m[k] = val
|
|
86
|
+
|
|
87
|
+
return m
|
|
@@ -0,0 +1,84 @@
|
|
|
1
|
+
"""Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT."""
|
|
2
|
+
|
|
3
|
+
from __future__ import annotations
|
|
4
|
+
from pydantic import model_serializer
|
|
5
|
+
from syllable_sdk.types import (
|
|
6
|
+
BaseModel,
|
|
7
|
+
Nullable,
|
|
8
|
+
OptionalNullable,
|
|
9
|
+
UNSET,
|
|
10
|
+
UNSET_SENTINEL,
|
|
11
|
+
)
|
|
12
|
+
from typing_extensions import NotRequired, TypedDict
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
class TelephonyConfigurationsTypedDict(TypedDict):
|
|
16
|
+
pre_input_timeout: NotRequired[Nullable[float]]
|
|
17
|
+
r"""Pre input silence threshold"""
|
|
18
|
+
post_speech_input_timeout: NotRequired[Nullable[float]]
|
|
19
|
+
r"""Post speech silence timeout to determine input as ended."""
|
|
20
|
+
post_dtmf_input_timeout: NotRequired[Nullable[float]]
|
|
21
|
+
r"""Post dtmf silence timeout to determine input as ended."""
|
|
22
|
+
overall_input_timeout: NotRequired[Nullable[float]]
|
|
23
|
+
r"""Total input timeout"""
|
|
24
|
+
output_padding: NotRequired[Nullable[float]]
|
|
25
|
+
r"""Number of seconds to start listening to user input before assistant speech ends"""
|
|
26
|
+
|
|
27
|
+
|
|
28
|
+
class TelephonyConfigurations(BaseModel):
|
|
29
|
+
pre_input_timeout: OptionalNullable[float] = UNSET
|
|
30
|
+
r"""Pre input silence threshold"""
|
|
31
|
+
|
|
32
|
+
post_speech_input_timeout: OptionalNullable[float] = UNSET
|
|
33
|
+
r"""Post speech silence timeout to determine input as ended."""
|
|
34
|
+
|
|
35
|
+
post_dtmf_input_timeout: OptionalNullable[float] = UNSET
|
|
36
|
+
r"""Post dtmf silence timeout to determine input as ended."""
|
|
37
|
+
|
|
38
|
+
overall_input_timeout: OptionalNullable[float] = UNSET
|
|
39
|
+
r"""Total input timeout"""
|
|
40
|
+
|
|
41
|
+
output_padding: OptionalNullable[float] = UNSET
|
|
42
|
+
r"""Number of seconds to start listening to user input before assistant speech ends"""
|
|
43
|
+
|
|
44
|
+
@model_serializer(mode="wrap")
|
|
45
|
+
def serialize_model(self, handler):
|
|
46
|
+
optional_fields = [
|
|
47
|
+
"pre_input_timeout",
|
|
48
|
+
"post_speech_input_timeout",
|
|
49
|
+
"post_dtmf_input_timeout",
|
|
50
|
+
"overall_input_timeout",
|
|
51
|
+
"output_padding",
|
|
52
|
+
]
|
|
53
|
+
nullable_fields = [
|
|
54
|
+
"pre_input_timeout",
|
|
55
|
+
"post_speech_input_timeout",
|
|
56
|
+
"post_dtmf_input_timeout",
|
|
57
|
+
"overall_input_timeout",
|
|
58
|
+
"output_padding",
|
|
59
|
+
]
|
|
60
|
+
null_default_fields = []
|
|
61
|
+
|
|
62
|
+
serialized = handler(self)
|
|
63
|
+
|
|
64
|
+
m = {}
|
|
65
|
+
|
|
66
|
+
for n, f in type(self).model_fields.items():
|
|
67
|
+
k = f.alias or n
|
|
68
|
+
val = serialized.get(k)
|
|
69
|
+
serialized.pop(k, None)
|
|
70
|
+
|
|
71
|
+
optional_nullable = k in optional_fields and k in nullable_fields
|
|
72
|
+
is_set = (
|
|
73
|
+
self.__pydantic_fields_set__.intersection({n})
|
|
74
|
+
or k in null_default_fields
|
|
75
|
+
) # pylint: disable=no-member
|
|
76
|
+
|
|
77
|
+
if val is not None and val != UNSET_SENTINEL:
|
|
78
|
+
m[k] = val
|
|
79
|
+
elif val != UNSET_SENTINEL and (
|
|
80
|
+
not k in optional_fields or (optional_nullable and is_set)
|
|
81
|
+
):
|
|
82
|
+
m[k] = val
|
|
83
|
+
|
|
84
|
+
return m
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.3
|
|
2
2
|
Name: syllable-sdk
|
|
3
|
-
Version: 0.35.
|
|
3
|
+
Version: 0.35.58
|
|
4
4
|
Summary: Python Client SDK Generated by Speakeasy.
|
|
5
5
|
Author: Syllable
|
|
6
6
|
Requires-Python: >=3.9.2
|
|
@@ -253,6 +253,8 @@ with SyllableSDK(
|
|
|
253
253
|
### [channels](https://github.com/asksyllable/syllable-sdk-python/blob/master/docs/sdks/channels/README.md)
|
|
254
254
|
|
|
255
255
|
* [list](https://github.com/asksyllable/syllable-sdk-python/blob/master/docs/sdks/channels/README.md#list) - Get Channels
|
|
256
|
+
* [create](https://github.com/asksyllable/syllable-sdk-python/blob/master/docs/sdks/channels/README.md#create) - Create Channel
|
|
257
|
+
* [update](https://github.com/asksyllable/syllable-sdk-python/blob/master/docs/sdks/channels/README.md#update) - Update Channel
|
|
256
258
|
* [delete](https://github.com/asksyllable/syllable-sdk-python/blob/master/docs/sdks/channels/README.md#delete) - Delete Channel Target
|
|
257
259
|
|
|
258
260
|
#### [channels.targets](https://github.com/asksyllable/syllable-sdk-python/blob/master/docs/sdks/targets/README.md)
|
|
@@ -3,12 +3,12 @@ syllable_sdk/_hooks/__init__.py,sha256=9_7W5jAYw8rcO8Kfc-Ty-lB82BHfksAJJpVFb_UeU
|
|
|
3
3
|
syllable_sdk/_hooks/registration.py,sha256=1QZB41w6If7I9dXiOSQx6dhSc6BPWrnI5Q5bMOr4iVA,624
|
|
4
4
|
syllable_sdk/_hooks/sdkhooks.py,sha256=aRu2TMpxilLKDrG6EIy6uQd6IrBH7kaHOoVkd7GIcus,2562
|
|
5
5
|
syllable_sdk/_hooks/types.py,sha256=uwJkn18g4_rLZhVtKdE6Ed5YcCjGWSqVgN9-PWqV7Ho,3053
|
|
6
|
-
syllable_sdk/_version.py,sha256=
|
|
6
|
+
syllable_sdk/_version.py,sha256=zeWMQK95LSA51tTvUITk-w7ztDIiUk2mecdktK9Uarw,470
|
|
7
7
|
syllable_sdk/agents.py,sha256=0x4iFVF9VksBu32ThrGcgM3FqMCC9-iP8ggPh2r4R04,46694
|
|
8
8
|
syllable_sdk/basesdk.py,sha256=dULbDf9e71tjSgOe7YwC9jD-80uIFiMrAhFbFvbEYho,11916
|
|
9
9
|
syllable_sdk/batches.py,sha256=qgI5PRkdgLdaJl4DPfs4mBJrB0OY_CCDePYntyjleSs,73059
|
|
10
10
|
syllable_sdk/campaigns.py,sha256=MIw1sWFreiedJfhFuGg2lYbxOQDtwwsgI2TiS7AgnIM,40546
|
|
11
|
-
syllable_sdk/channels.py,sha256=
|
|
11
|
+
syllable_sdk/channels.py,sha256=oXgjGpVn_ANZu_ao8zZRwKQNJ895smUN9fKe6Gj17U0,34131
|
|
12
12
|
syllable_sdk/conversations.py,sha256=SjbYq8-mr2RdIh_JO_qxh25WvLkWXf_KsEUxhHRVlB4,10743
|
|
13
13
|
syllable_sdk/custom_messages.py,sha256=xM3Sy-bdXPYX-qUJUl_CfgjR0HtEpN32u1uXqc1X9x0,41307
|
|
14
14
|
syllable_sdk/dashboards.py,sha256=qvzxTiPnzJTmip02EPyGP-qaCgBtpZ4OPYJa2IGH1nw,45442
|
|
@@ -28,7 +28,7 @@ syllable_sdk/insights_sdk.py,sha256=MxNtdwu2dcM8xCjKS2l-ZIM-pT-Bbh8LSjMnFLl32nc,
|
|
|
28
28
|
syllable_sdk/insights_tools.py,sha256=SuDEOpPtk7SlsFZ-thzIZSt_31WjofzyzqozseWQy3M,55115
|
|
29
29
|
syllable_sdk/language_groups.py,sha256=BlcTvh_KitUkbVzXlBjCcxTmBbQ12QWxCZfXqlCOoPc,49214
|
|
30
30
|
syllable_sdk/latency.py,sha256=PymvwBTs6KAVMl-IZVj6L4zJotRApBOcnkfB4FrlNkg,7449
|
|
31
|
-
syllable_sdk/models/__init__.py,sha256=
|
|
31
|
+
syllable_sdk/models/__init__.py,sha256=7_2q4PfPjKkyuSFDoSz9_UX_zq1AamrivJuR-2HpKzo,85449
|
|
32
32
|
syllable_sdk/models/agent_deleteop.py,sha256=tUbi-gwd4chf2Ba9O9lCvqDQw6YOnn7aheu8OPDzptc,629
|
|
33
33
|
syllable_sdk/models/agent_get_by_idop.py,sha256=vj_xEbhOv3c8n3-B3uQnfTwHWdxYSE4k3Zvr58Yc9A4,484
|
|
34
34
|
syllable_sdk/models/agent_listop.py,sha256=dJdQuIst1TF4xMol9XVdX4xOw8z06jyAQpm46_u0Ysk,5007
|
|
@@ -59,12 +59,13 @@ syllable_sdk/models/body_organizations_update.py,sha256=hwiy1OqKWjA-eN1FJc3tybqe
|
|
|
59
59
|
syllable_sdk/models/body_outbound_batch_delete.py,sha256=c-3MzefgLGTnZiYtLKb28AkOMwtCImkMLJg932g5PLY,425
|
|
60
60
|
syllable_sdk/models/body_outbound_batch_upload.py,sha256=_W1aXZOpZX1KO1GaUJhMAkjEgV1v9nLQazyWcQ6AjYY,1313
|
|
61
61
|
syllable_sdk/models/campaignproperties.py,sha256=06sF5NzEiwmyQ6WLgHxSccErd2EnmpYge5FI7CFe4hI,467
|
|
62
|
-
syllable_sdk/models/channel.py,sha256=
|
|
62
|
+
syllable_sdk/models/channel.py,sha256=qdavKRBPraONuozprbVC84BJwfg0vtOAa7Laqyuw_oE,2724
|
|
63
63
|
syllable_sdk/models/channel_targets_createop.py,sha256=YmOseJWuOWtE9AApMqju7dGO-I-zEHq0NQ_wGvIl6Ck,877
|
|
64
64
|
syllable_sdk/models/channel_targets_deleteop.py,sha256=AzJzm--VepFhuGZ7p7zysc-h9u7HXzQ4EctxH-mbI0c,657
|
|
65
65
|
syllable_sdk/models/channel_targets_get_by_idop.py,sha256=fRKxp4AWvmIBLmJT1OmxrylUVvmkjhf9ITvDIe7gbu8,640
|
|
66
66
|
syllable_sdk/models/channel_targets_listop.py,sha256=bG5gb4JobNMvwyNgO9DRzRMHp6wQ7P6aJVN8lZBZQiU,5089
|
|
67
67
|
syllable_sdk/models/channel_targets_updateop.py,sha256=JXURM5evRvWUuF-5mMrYqW9oBm2d7B0YIc6X4_lQGxI,1011
|
|
68
|
+
syllable_sdk/models/channelconfigview.py,sha256=DfshI8QEwpEeAuAhITDktdxttqYXnpRf90cauzc8xHA,1829
|
|
68
69
|
syllable_sdk/models/channelproperties.py,sha256=cpvVG1F8O_bZ0WG76KqT66nle8YQ8o8u4J56v4Ao-rU,396
|
|
69
70
|
syllable_sdk/models/channels_listop.py,sha256=kZS7vUtO6pMNq1au6TbF94FFvBC1Odxl0vQunP_g564,5029
|
|
70
71
|
syllable_sdk/models/channels_twilio_get_by_idop.py,sha256=lnantEqegGeXZAGVETByEv1DzR8jcxVfNw1hi5B9AJI,506
|
|
@@ -206,6 +207,9 @@ syllable_sdk/models/listresponse_toolresponse_.py,sha256=lAgwBYF4-VRgfNp7pyrBMw6
|
|
|
206
207
|
syllable_sdk/models/listresponse_userresponse_.py,sha256=zZqujwjjoe589oZZZrSyEj8-74tx2MnSWpY08AJtaK0,2348
|
|
207
208
|
syllable_sdk/models/logintype.py,sha256=N6VPXZQVqNFkhC2568I0mJzBotKDqCKeqipJFp2a_Pg,285
|
|
208
209
|
syllable_sdk/models/orderbydirection.py,sha256=1Jh50d2n7KXwKBRlkW7gdDUUGl4pexO0l0XwQWn8Sac,291
|
|
210
|
+
syllable_sdk/models/organizationchannelconfig.py,sha256=u59K0ggMcc2oeAvI0uDWVu5MMY7ZNnci3N1KNwVERVI,2303
|
|
211
|
+
syllable_sdk/models/organizationchannelcreaterequest.py,sha256=e0OaCYQHw_vrtMgOIWrJigYMz-Ys5wfH9mrYIWgUI1M,2931
|
|
212
|
+
syllable_sdk/models/organizationchannelupdaterequest.py,sha256=oM35Fr9O_oVSgcYm4PN4Di3qnEJx4Zl8tX_EVwgdyh0,3040
|
|
209
213
|
syllable_sdk/models/organizationresponse.py,sha256=gcqBRNwAsVrXOSnjgMSui_VrAZz0AEYJIoItEfnMMxc,3658
|
|
210
214
|
syllable_sdk/models/outbound_batch_addop.py,sha256=5SI0jNm19NE11zdtToh9p3HLhSM9OiJSIx0wVjL-BpI,806
|
|
211
215
|
syllable_sdk/models/outbound_batch_deleteop.py,sha256=5t4BDaxQYogksgZkvR_gDfkFPoMVeJA0GSrhTZu_uRs,892
|
|
@@ -281,6 +285,7 @@ syllable_sdk/models/takeouts_get_by_job_idop.py,sha256=vFpjQ3wUfS3UeD3pkX6S07AJw
|
|
|
281
285
|
syllable_sdk/models/takeouts_get_fileop.py,sha256=x_BGUgt6co6HOHFPOsSIOxpZ8D4KVIjBv7ZifL0l0YQ,620
|
|
282
286
|
syllable_sdk/models/takeoutstatusresponse.py,sha256=U83D5jjff7LMEdFg7PAPfO-RSDW094TiXhTsnrAHUPs,1766
|
|
283
287
|
syllable_sdk/models/targetmodes.py,sha256=dR2veCCcFJRRwz1tUqq41d5JvChpcamnUQXpEx1dEnw,309
|
|
288
|
+
syllable_sdk/models/telephonyconfigurations.py,sha256=EStakiggOEZFftOBRCd_rHX7OAqAPuLbwCm-7yPl4KU,2842
|
|
284
289
|
syllable_sdk/models/testmessage.py,sha256=e3kHJe_E78zGcNKZ5azTTcZjQxtQUsf3F8GPyUDCIPA,3365
|
|
285
290
|
syllable_sdk/models/testmessageresponse.py,sha256=Ya7G0PtfNzz3B5CSILrarNclcoEqkwmSE-Qi5ioRAfo,2335
|
|
286
291
|
syllable_sdk/models/tool_deleteop.py,sha256=M_vEFwiOgFbgrqnKRypbrObtU8EIavsOR9hPvVq_Ups,629
|
|
@@ -367,6 +372,6 @@ syllable_sdk/utils/url.py,sha256=BgGPgcTA6MRK4bF8fjP2dUopN3NzEzxWMXPBVg8NQUA,525
|
|
|
367
372
|
syllable_sdk/utils/values.py,sha256=CcaCXEa3xHhkUDROyXZocN8f0bdITftv9Y0P9lTf0YM,3517
|
|
368
373
|
syllable_sdk/v1.py,sha256=noni4Ds8tZ5oHPZqoEoVJUYGs8L-ts9jGGFDU2E0pyE,53244
|
|
369
374
|
syllable_sdk/workflows.py,sha256=kQPJzssdldotkipoWzu1ddas4IKbpFdXkGFDwDkWt1M,64777
|
|
370
|
-
syllable_sdk-0.35.
|
|
371
|
-
syllable_sdk-0.35.
|
|
372
|
-
syllable_sdk-0.35.
|
|
375
|
+
syllable_sdk-0.35.58.dist-info/METADATA,sha256=951uOuFksSD95p4NZ4XRakRa9jzhLwXxd9IlcG7L9nM,45941
|
|
376
|
+
syllable_sdk-0.35.58.dist-info/WHEEL,sha256=b4K_helf-jlQoXBBETfwnf4B04YC67LOev0jo4fX5m8,88
|
|
377
|
+
syllable_sdk-0.35.58.dist-info/RECORD,,
|
|
File without changes
|