mistralai 1.9.10__py3-none-any.whl → 1.9.11__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.
- mistralai/_version.py +3 -3
- mistralai/accesses.py +43 -108
- mistralai/agents.py +29 -68
- mistralai/audio.py +8 -3
- mistralai/basesdk.py +15 -5
- mistralai/batch.py +6 -3
- mistralai/beta.py +10 -5
- mistralai/chat.py +29 -68
- mistralai/classifiers.py +57 -144
- mistralai/conversations.py +143 -352
- mistralai/documents.py +137 -356
- mistralai/embeddings.py +15 -36
- mistralai/files.py +47 -176
- mistralai/fim.py +29 -68
- mistralai/fine_tuning.py +6 -3
- mistralai/jobs.py +49 -158
- mistralai/libraries.py +71 -178
- mistralai/mistral_agents.py +71 -180
- mistralai/mistral_jobs.py +41 -128
- mistralai/models/__init__.py +25 -3
- mistralai/models/httpvalidationerror.py +11 -6
- mistralai/models/mistralerror.py +26 -0
- mistralai/models/no_response_error.py +13 -0
- mistralai/models/responsevalidationerror.py +25 -0
- mistralai/models/sdkerror.py +30 -14
- mistralai/models_.py +71 -204
- mistralai/ocr.py +15 -36
- mistralai/sdk.py +15 -2
- mistralai/transcriptions.py +17 -56
- mistralai/utils/__init__.py +18 -5
- mistralai/utils/eventstreaming.py +10 -0
- mistralai/utils/serializers.py +3 -2
- mistralai/utils/unmarshal_json_response.py +24 -0
- {mistralai-1.9.10.dist-info → mistralai-1.9.11.dist-info}/METADATA +61 -30
- {mistralai-1.9.10.dist-info → mistralai-1.9.11.dist-info}/RECORD +37 -33
- {mistralai-1.9.10.dist-info → mistralai-1.9.11.dist-info}/WHEEL +1 -1
- {mistralai-1.9.10.dist-info → mistralai-1.9.11.dist-info/licenses}/LICENSE +0 -0
mistralai/conversations.py
CHANGED
|
@@ -5,6 +5,7 @@ from mistralai import models, utils
|
|
|
5
5
|
from mistralai._hooks import HookContext
|
|
6
6
|
from mistralai.types import OptionalNullable, UNSET
|
|
7
7
|
from mistralai.utils import eventstreaming, get_security_from_env
|
|
8
|
+
from mistralai.utils.unmarshal_json_response import unmarshal_json_response
|
|
8
9
|
from typing import Any, List, Mapping, Optional, Union
|
|
9
10
|
|
|
10
11
|
# region imports
|
|
@@ -328,31 +329,20 @@ class Conversations(BaseSDK):
|
|
|
328
329
|
|
|
329
330
|
response_data: Any = None
|
|
330
331
|
if utils.match_response(http_res, "200", "application/json"):
|
|
331
|
-
return
|
|
332
|
+
return unmarshal_json_response(models.ConversationResponse, http_res)
|
|
332
333
|
if utils.match_response(http_res, "422", "application/json"):
|
|
333
|
-
response_data =
|
|
334
|
-
|
|
334
|
+
response_data = unmarshal_json_response(
|
|
335
|
+
models.HTTPValidationErrorData, http_res
|
|
335
336
|
)
|
|
336
|
-
raise models.HTTPValidationError(
|
|
337
|
+
raise models.HTTPValidationError(response_data, http_res)
|
|
337
338
|
if utils.match_response(http_res, "4XX", "*"):
|
|
338
339
|
http_res_text = utils.stream_to_text(http_res)
|
|
339
|
-
raise models.SDKError(
|
|
340
|
-
"API error occurred", http_res.status_code, http_res_text, http_res
|
|
341
|
-
)
|
|
340
|
+
raise models.SDKError("API error occurred", http_res, http_res_text)
|
|
342
341
|
if utils.match_response(http_res, "5XX", "*"):
|
|
343
342
|
http_res_text = utils.stream_to_text(http_res)
|
|
344
|
-
raise models.SDKError(
|
|
345
|
-
"API error occurred", http_res.status_code, http_res_text, http_res
|
|
346
|
-
)
|
|
343
|
+
raise models.SDKError("API error occurred", http_res, http_res_text)
|
|
347
344
|
|
|
348
|
-
|
|
349
|
-
http_res_text = utils.stream_to_text(http_res)
|
|
350
|
-
raise models.SDKError(
|
|
351
|
-
f"Unexpected response received (code: {http_res.status_code}, type: {content_type})",
|
|
352
|
-
http_res.status_code,
|
|
353
|
-
http_res_text,
|
|
354
|
-
http_res,
|
|
355
|
-
)
|
|
345
|
+
raise models.SDKError("Unexpected response received", http_res)
|
|
356
346
|
|
|
357
347
|
async def start_async(
|
|
358
348
|
self,
|
|
@@ -467,31 +457,20 @@ class Conversations(BaseSDK):
|
|
|
467
457
|
|
|
468
458
|
response_data: Any = None
|
|
469
459
|
if utils.match_response(http_res, "200", "application/json"):
|
|
470
|
-
return
|
|
460
|
+
return unmarshal_json_response(models.ConversationResponse, http_res)
|
|
471
461
|
if utils.match_response(http_res, "422", "application/json"):
|
|
472
|
-
response_data =
|
|
473
|
-
|
|
462
|
+
response_data = unmarshal_json_response(
|
|
463
|
+
models.HTTPValidationErrorData, http_res
|
|
474
464
|
)
|
|
475
|
-
raise models.HTTPValidationError(
|
|
465
|
+
raise models.HTTPValidationError(response_data, http_res)
|
|
476
466
|
if utils.match_response(http_res, "4XX", "*"):
|
|
477
467
|
http_res_text = await utils.stream_to_text_async(http_res)
|
|
478
|
-
raise models.SDKError(
|
|
479
|
-
"API error occurred", http_res.status_code, http_res_text, http_res
|
|
480
|
-
)
|
|
468
|
+
raise models.SDKError("API error occurred", http_res, http_res_text)
|
|
481
469
|
if utils.match_response(http_res, "5XX", "*"):
|
|
482
470
|
http_res_text = await utils.stream_to_text_async(http_res)
|
|
483
|
-
raise models.SDKError(
|
|
484
|
-
"API error occurred", http_res.status_code, http_res_text, http_res
|
|
485
|
-
)
|
|
471
|
+
raise models.SDKError("API error occurred", http_res, http_res_text)
|
|
486
472
|
|
|
487
|
-
|
|
488
|
-
http_res_text = await utils.stream_to_text_async(http_res)
|
|
489
|
-
raise models.SDKError(
|
|
490
|
-
f"Unexpected response received (code: {http_res.status_code}, type: {content_type})",
|
|
491
|
-
http_res.status_code,
|
|
492
|
-
http_res_text,
|
|
493
|
-
http_res,
|
|
494
|
-
)
|
|
473
|
+
raise models.SDKError("Unexpected response received", http_res)
|
|
495
474
|
|
|
496
475
|
def list(
|
|
497
476
|
self,
|
|
@@ -570,31 +549,20 @@ class Conversations(BaseSDK):
|
|
|
570
549
|
|
|
571
550
|
response_data: Any = None
|
|
572
551
|
if utils.match_response(http_res, "200", "application/json"):
|
|
573
|
-
return
|
|
552
|
+
return unmarshal_json_response(List[models.ResponseBody], http_res)
|
|
574
553
|
if utils.match_response(http_res, "422", "application/json"):
|
|
575
|
-
response_data =
|
|
576
|
-
|
|
554
|
+
response_data = unmarshal_json_response(
|
|
555
|
+
models.HTTPValidationErrorData, http_res
|
|
577
556
|
)
|
|
578
|
-
raise models.HTTPValidationError(
|
|
557
|
+
raise models.HTTPValidationError(response_data, http_res)
|
|
579
558
|
if utils.match_response(http_res, "4XX", "*"):
|
|
580
559
|
http_res_text = utils.stream_to_text(http_res)
|
|
581
|
-
raise models.SDKError(
|
|
582
|
-
"API error occurred", http_res.status_code, http_res_text, http_res
|
|
583
|
-
)
|
|
560
|
+
raise models.SDKError("API error occurred", http_res, http_res_text)
|
|
584
561
|
if utils.match_response(http_res, "5XX", "*"):
|
|
585
562
|
http_res_text = utils.stream_to_text(http_res)
|
|
586
|
-
raise models.SDKError(
|
|
587
|
-
"API error occurred", http_res.status_code, http_res_text, http_res
|
|
588
|
-
)
|
|
563
|
+
raise models.SDKError("API error occurred", http_res, http_res_text)
|
|
589
564
|
|
|
590
|
-
|
|
591
|
-
http_res_text = utils.stream_to_text(http_res)
|
|
592
|
-
raise models.SDKError(
|
|
593
|
-
f"Unexpected response received (code: {http_res.status_code}, type: {content_type})",
|
|
594
|
-
http_res.status_code,
|
|
595
|
-
http_res_text,
|
|
596
|
-
http_res,
|
|
597
|
-
)
|
|
565
|
+
raise models.SDKError("Unexpected response received", http_res)
|
|
598
566
|
|
|
599
567
|
async def list_async(
|
|
600
568
|
self,
|
|
@@ -673,31 +641,20 @@ class Conversations(BaseSDK):
|
|
|
673
641
|
|
|
674
642
|
response_data: Any = None
|
|
675
643
|
if utils.match_response(http_res, "200", "application/json"):
|
|
676
|
-
return
|
|
644
|
+
return unmarshal_json_response(List[models.ResponseBody], http_res)
|
|
677
645
|
if utils.match_response(http_res, "422", "application/json"):
|
|
678
|
-
response_data =
|
|
679
|
-
|
|
646
|
+
response_data = unmarshal_json_response(
|
|
647
|
+
models.HTTPValidationErrorData, http_res
|
|
680
648
|
)
|
|
681
|
-
raise models.HTTPValidationError(
|
|
649
|
+
raise models.HTTPValidationError(response_data, http_res)
|
|
682
650
|
if utils.match_response(http_res, "4XX", "*"):
|
|
683
651
|
http_res_text = await utils.stream_to_text_async(http_res)
|
|
684
|
-
raise models.SDKError(
|
|
685
|
-
"API error occurred", http_res.status_code, http_res_text, http_res
|
|
686
|
-
)
|
|
652
|
+
raise models.SDKError("API error occurred", http_res, http_res_text)
|
|
687
653
|
if utils.match_response(http_res, "5XX", "*"):
|
|
688
654
|
http_res_text = await utils.stream_to_text_async(http_res)
|
|
689
|
-
raise models.SDKError(
|
|
690
|
-
"API error occurred", http_res.status_code, http_res_text, http_res
|
|
691
|
-
)
|
|
655
|
+
raise models.SDKError("API error occurred", http_res, http_res_text)
|
|
692
656
|
|
|
693
|
-
|
|
694
|
-
http_res_text = await utils.stream_to_text_async(http_res)
|
|
695
|
-
raise models.SDKError(
|
|
696
|
-
f"Unexpected response received (code: {http_res.status_code}, type: {content_type})",
|
|
697
|
-
http_res.status_code,
|
|
698
|
-
http_res_text,
|
|
699
|
-
http_res,
|
|
700
|
-
)
|
|
657
|
+
raise models.SDKError("Unexpected response received", http_res)
|
|
701
658
|
|
|
702
659
|
def get(
|
|
703
660
|
self,
|
|
@@ -773,34 +730,22 @@ class Conversations(BaseSDK):
|
|
|
773
730
|
|
|
774
731
|
response_data: Any = None
|
|
775
732
|
if utils.match_response(http_res, "200", "application/json"):
|
|
776
|
-
return
|
|
777
|
-
|
|
778
|
-
models.AgentsAPIV1ConversationsGetResponseV1ConversationsGet,
|
|
733
|
+
return unmarshal_json_response(
|
|
734
|
+
models.AgentsAPIV1ConversationsGetResponseV1ConversationsGet, http_res
|
|
779
735
|
)
|
|
780
736
|
if utils.match_response(http_res, "422", "application/json"):
|
|
781
|
-
response_data =
|
|
782
|
-
|
|
737
|
+
response_data = unmarshal_json_response(
|
|
738
|
+
models.HTTPValidationErrorData, http_res
|
|
783
739
|
)
|
|
784
|
-
raise models.HTTPValidationError(
|
|
740
|
+
raise models.HTTPValidationError(response_data, http_res)
|
|
785
741
|
if utils.match_response(http_res, "4XX", "*"):
|
|
786
742
|
http_res_text = utils.stream_to_text(http_res)
|
|
787
|
-
raise models.SDKError(
|
|
788
|
-
"API error occurred", http_res.status_code, http_res_text, http_res
|
|
789
|
-
)
|
|
743
|
+
raise models.SDKError("API error occurred", http_res, http_res_text)
|
|
790
744
|
if utils.match_response(http_res, "5XX", "*"):
|
|
791
745
|
http_res_text = utils.stream_to_text(http_res)
|
|
792
|
-
raise models.SDKError(
|
|
793
|
-
"API error occurred", http_res.status_code, http_res_text, http_res
|
|
794
|
-
)
|
|
746
|
+
raise models.SDKError("API error occurred", http_res, http_res_text)
|
|
795
747
|
|
|
796
|
-
|
|
797
|
-
http_res_text = utils.stream_to_text(http_res)
|
|
798
|
-
raise models.SDKError(
|
|
799
|
-
f"Unexpected response received (code: {http_res.status_code}, type: {content_type})",
|
|
800
|
-
http_res.status_code,
|
|
801
|
-
http_res_text,
|
|
802
|
-
http_res,
|
|
803
|
-
)
|
|
748
|
+
raise models.SDKError("Unexpected response received", http_res)
|
|
804
749
|
|
|
805
750
|
async def get_async(
|
|
806
751
|
self,
|
|
@@ -876,34 +821,22 @@ class Conversations(BaseSDK):
|
|
|
876
821
|
|
|
877
822
|
response_data: Any = None
|
|
878
823
|
if utils.match_response(http_res, "200", "application/json"):
|
|
879
|
-
return
|
|
880
|
-
|
|
881
|
-
models.AgentsAPIV1ConversationsGetResponseV1ConversationsGet,
|
|
824
|
+
return unmarshal_json_response(
|
|
825
|
+
models.AgentsAPIV1ConversationsGetResponseV1ConversationsGet, http_res
|
|
882
826
|
)
|
|
883
827
|
if utils.match_response(http_res, "422", "application/json"):
|
|
884
|
-
response_data =
|
|
885
|
-
|
|
828
|
+
response_data = unmarshal_json_response(
|
|
829
|
+
models.HTTPValidationErrorData, http_res
|
|
886
830
|
)
|
|
887
|
-
raise models.HTTPValidationError(
|
|
831
|
+
raise models.HTTPValidationError(response_data, http_res)
|
|
888
832
|
if utils.match_response(http_res, "4XX", "*"):
|
|
889
833
|
http_res_text = await utils.stream_to_text_async(http_res)
|
|
890
|
-
raise models.SDKError(
|
|
891
|
-
"API error occurred", http_res.status_code, http_res_text, http_res
|
|
892
|
-
)
|
|
834
|
+
raise models.SDKError("API error occurred", http_res, http_res_text)
|
|
893
835
|
if utils.match_response(http_res, "5XX", "*"):
|
|
894
836
|
http_res_text = await utils.stream_to_text_async(http_res)
|
|
895
|
-
raise models.SDKError(
|
|
896
|
-
"API error occurred", http_res.status_code, http_res_text, http_res
|
|
897
|
-
)
|
|
837
|
+
raise models.SDKError("API error occurred", http_res, http_res_text)
|
|
898
838
|
|
|
899
|
-
|
|
900
|
-
http_res_text = await utils.stream_to_text_async(http_res)
|
|
901
|
-
raise models.SDKError(
|
|
902
|
-
f"Unexpected response received (code: {http_res.status_code}, type: {content_type})",
|
|
903
|
-
http_res.status_code,
|
|
904
|
-
http_res_text,
|
|
905
|
-
http_res,
|
|
906
|
-
)
|
|
839
|
+
raise models.SDKError("Unexpected response received", http_res)
|
|
907
840
|
|
|
908
841
|
def append(
|
|
909
842
|
self,
|
|
@@ -1009,31 +942,20 @@ class Conversations(BaseSDK):
|
|
|
1009
942
|
|
|
1010
943
|
response_data: Any = None
|
|
1011
944
|
if utils.match_response(http_res, "200", "application/json"):
|
|
1012
|
-
return
|
|
945
|
+
return unmarshal_json_response(models.ConversationResponse, http_res)
|
|
1013
946
|
if utils.match_response(http_res, "422", "application/json"):
|
|
1014
|
-
response_data =
|
|
1015
|
-
|
|
947
|
+
response_data = unmarshal_json_response(
|
|
948
|
+
models.HTTPValidationErrorData, http_res
|
|
1016
949
|
)
|
|
1017
|
-
raise models.HTTPValidationError(
|
|
950
|
+
raise models.HTTPValidationError(response_data, http_res)
|
|
1018
951
|
if utils.match_response(http_res, "4XX", "*"):
|
|
1019
952
|
http_res_text = utils.stream_to_text(http_res)
|
|
1020
|
-
raise models.SDKError(
|
|
1021
|
-
"API error occurred", http_res.status_code, http_res_text, http_res
|
|
1022
|
-
)
|
|
953
|
+
raise models.SDKError("API error occurred", http_res, http_res_text)
|
|
1023
954
|
if utils.match_response(http_res, "5XX", "*"):
|
|
1024
955
|
http_res_text = utils.stream_to_text(http_res)
|
|
1025
|
-
raise models.SDKError(
|
|
1026
|
-
"API error occurred", http_res.status_code, http_res_text, http_res
|
|
1027
|
-
)
|
|
956
|
+
raise models.SDKError("API error occurred", http_res, http_res_text)
|
|
1028
957
|
|
|
1029
|
-
|
|
1030
|
-
http_res_text = utils.stream_to_text(http_res)
|
|
1031
|
-
raise models.SDKError(
|
|
1032
|
-
f"Unexpected response received (code: {http_res.status_code}, type: {content_type})",
|
|
1033
|
-
http_res.status_code,
|
|
1034
|
-
http_res_text,
|
|
1035
|
-
http_res,
|
|
1036
|
-
)
|
|
958
|
+
raise models.SDKError("Unexpected response received", http_res)
|
|
1037
959
|
|
|
1038
960
|
async def append_async(
|
|
1039
961
|
self,
|
|
@@ -1139,31 +1061,20 @@ class Conversations(BaseSDK):
|
|
|
1139
1061
|
|
|
1140
1062
|
response_data: Any = None
|
|
1141
1063
|
if utils.match_response(http_res, "200", "application/json"):
|
|
1142
|
-
return
|
|
1064
|
+
return unmarshal_json_response(models.ConversationResponse, http_res)
|
|
1143
1065
|
if utils.match_response(http_res, "422", "application/json"):
|
|
1144
|
-
response_data =
|
|
1145
|
-
|
|
1066
|
+
response_data = unmarshal_json_response(
|
|
1067
|
+
models.HTTPValidationErrorData, http_res
|
|
1146
1068
|
)
|
|
1147
|
-
raise models.HTTPValidationError(
|
|
1069
|
+
raise models.HTTPValidationError(response_data, http_res)
|
|
1148
1070
|
if utils.match_response(http_res, "4XX", "*"):
|
|
1149
1071
|
http_res_text = await utils.stream_to_text_async(http_res)
|
|
1150
|
-
raise models.SDKError(
|
|
1151
|
-
"API error occurred", http_res.status_code, http_res_text, http_res
|
|
1152
|
-
)
|
|
1072
|
+
raise models.SDKError("API error occurred", http_res, http_res_text)
|
|
1153
1073
|
if utils.match_response(http_res, "5XX", "*"):
|
|
1154
1074
|
http_res_text = await utils.stream_to_text_async(http_res)
|
|
1155
|
-
raise models.SDKError(
|
|
1156
|
-
"API error occurred", http_res.status_code, http_res_text, http_res
|
|
1157
|
-
)
|
|
1075
|
+
raise models.SDKError("API error occurred", http_res, http_res_text)
|
|
1158
1076
|
|
|
1159
|
-
|
|
1160
|
-
http_res_text = await utils.stream_to_text_async(http_res)
|
|
1161
|
-
raise models.SDKError(
|
|
1162
|
-
f"Unexpected response received (code: {http_res.status_code}, type: {content_type})",
|
|
1163
|
-
http_res.status_code,
|
|
1164
|
-
http_res_text,
|
|
1165
|
-
http_res,
|
|
1166
|
-
)
|
|
1077
|
+
raise models.SDKError("Unexpected response received", http_res)
|
|
1167
1078
|
|
|
1168
1079
|
def get_history(
|
|
1169
1080
|
self,
|
|
@@ -1239,31 +1150,20 @@ class Conversations(BaseSDK):
|
|
|
1239
1150
|
|
|
1240
1151
|
response_data: Any = None
|
|
1241
1152
|
if utils.match_response(http_res, "200", "application/json"):
|
|
1242
|
-
return
|
|
1153
|
+
return unmarshal_json_response(models.ConversationHistory, http_res)
|
|
1243
1154
|
if utils.match_response(http_res, "422", "application/json"):
|
|
1244
|
-
response_data =
|
|
1245
|
-
|
|
1155
|
+
response_data = unmarshal_json_response(
|
|
1156
|
+
models.HTTPValidationErrorData, http_res
|
|
1246
1157
|
)
|
|
1247
|
-
raise models.HTTPValidationError(
|
|
1158
|
+
raise models.HTTPValidationError(response_data, http_res)
|
|
1248
1159
|
if utils.match_response(http_res, "4XX", "*"):
|
|
1249
1160
|
http_res_text = utils.stream_to_text(http_res)
|
|
1250
|
-
raise models.SDKError(
|
|
1251
|
-
"API error occurred", http_res.status_code, http_res_text, http_res
|
|
1252
|
-
)
|
|
1161
|
+
raise models.SDKError("API error occurred", http_res, http_res_text)
|
|
1253
1162
|
if utils.match_response(http_res, "5XX", "*"):
|
|
1254
1163
|
http_res_text = utils.stream_to_text(http_res)
|
|
1255
|
-
raise models.SDKError(
|
|
1256
|
-
"API error occurred", http_res.status_code, http_res_text, http_res
|
|
1257
|
-
)
|
|
1164
|
+
raise models.SDKError("API error occurred", http_res, http_res_text)
|
|
1258
1165
|
|
|
1259
|
-
|
|
1260
|
-
http_res_text = utils.stream_to_text(http_res)
|
|
1261
|
-
raise models.SDKError(
|
|
1262
|
-
f"Unexpected response received (code: {http_res.status_code}, type: {content_type})",
|
|
1263
|
-
http_res.status_code,
|
|
1264
|
-
http_res_text,
|
|
1265
|
-
http_res,
|
|
1266
|
-
)
|
|
1166
|
+
raise models.SDKError("Unexpected response received", http_res)
|
|
1267
1167
|
|
|
1268
1168
|
async def get_history_async(
|
|
1269
1169
|
self,
|
|
@@ -1339,31 +1239,20 @@ class Conversations(BaseSDK):
|
|
|
1339
1239
|
|
|
1340
1240
|
response_data: Any = None
|
|
1341
1241
|
if utils.match_response(http_res, "200", "application/json"):
|
|
1342
|
-
return
|
|
1242
|
+
return unmarshal_json_response(models.ConversationHistory, http_res)
|
|
1343
1243
|
if utils.match_response(http_res, "422", "application/json"):
|
|
1344
|
-
response_data =
|
|
1345
|
-
|
|
1244
|
+
response_data = unmarshal_json_response(
|
|
1245
|
+
models.HTTPValidationErrorData, http_res
|
|
1346
1246
|
)
|
|
1347
|
-
raise models.HTTPValidationError(
|
|
1247
|
+
raise models.HTTPValidationError(response_data, http_res)
|
|
1348
1248
|
if utils.match_response(http_res, "4XX", "*"):
|
|
1349
1249
|
http_res_text = await utils.stream_to_text_async(http_res)
|
|
1350
|
-
raise models.SDKError(
|
|
1351
|
-
"API error occurred", http_res.status_code, http_res_text, http_res
|
|
1352
|
-
)
|
|
1250
|
+
raise models.SDKError("API error occurred", http_res, http_res_text)
|
|
1353
1251
|
if utils.match_response(http_res, "5XX", "*"):
|
|
1354
1252
|
http_res_text = await utils.stream_to_text_async(http_res)
|
|
1355
|
-
raise models.SDKError(
|
|
1356
|
-
"API error occurred", http_res.status_code, http_res_text, http_res
|
|
1357
|
-
)
|
|
1253
|
+
raise models.SDKError("API error occurred", http_res, http_res_text)
|
|
1358
1254
|
|
|
1359
|
-
|
|
1360
|
-
http_res_text = await utils.stream_to_text_async(http_res)
|
|
1361
|
-
raise models.SDKError(
|
|
1362
|
-
f"Unexpected response received (code: {http_res.status_code}, type: {content_type})",
|
|
1363
|
-
http_res.status_code,
|
|
1364
|
-
http_res_text,
|
|
1365
|
-
http_res,
|
|
1366
|
-
)
|
|
1255
|
+
raise models.SDKError("Unexpected response received", http_res)
|
|
1367
1256
|
|
|
1368
1257
|
def get_messages(
|
|
1369
1258
|
self,
|
|
@@ -1439,31 +1328,20 @@ class Conversations(BaseSDK):
|
|
|
1439
1328
|
|
|
1440
1329
|
response_data: Any = None
|
|
1441
1330
|
if utils.match_response(http_res, "200", "application/json"):
|
|
1442
|
-
return
|
|
1331
|
+
return unmarshal_json_response(models.ConversationMessages, http_res)
|
|
1443
1332
|
if utils.match_response(http_res, "422", "application/json"):
|
|
1444
|
-
response_data =
|
|
1445
|
-
|
|
1333
|
+
response_data = unmarshal_json_response(
|
|
1334
|
+
models.HTTPValidationErrorData, http_res
|
|
1446
1335
|
)
|
|
1447
|
-
raise models.HTTPValidationError(
|
|
1336
|
+
raise models.HTTPValidationError(response_data, http_res)
|
|
1448
1337
|
if utils.match_response(http_res, "4XX", "*"):
|
|
1449
1338
|
http_res_text = utils.stream_to_text(http_res)
|
|
1450
|
-
raise models.SDKError(
|
|
1451
|
-
"API error occurred", http_res.status_code, http_res_text, http_res
|
|
1452
|
-
)
|
|
1339
|
+
raise models.SDKError("API error occurred", http_res, http_res_text)
|
|
1453
1340
|
if utils.match_response(http_res, "5XX", "*"):
|
|
1454
1341
|
http_res_text = utils.stream_to_text(http_res)
|
|
1455
|
-
raise models.SDKError(
|
|
1456
|
-
"API error occurred", http_res.status_code, http_res_text, http_res
|
|
1457
|
-
)
|
|
1342
|
+
raise models.SDKError("API error occurred", http_res, http_res_text)
|
|
1458
1343
|
|
|
1459
|
-
|
|
1460
|
-
http_res_text = utils.stream_to_text(http_res)
|
|
1461
|
-
raise models.SDKError(
|
|
1462
|
-
f"Unexpected response received (code: {http_res.status_code}, type: {content_type})",
|
|
1463
|
-
http_res.status_code,
|
|
1464
|
-
http_res_text,
|
|
1465
|
-
http_res,
|
|
1466
|
-
)
|
|
1344
|
+
raise models.SDKError("Unexpected response received", http_res)
|
|
1467
1345
|
|
|
1468
1346
|
async def get_messages_async(
|
|
1469
1347
|
self,
|
|
@@ -1539,31 +1417,20 @@ class Conversations(BaseSDK):
|
|
|
1539
1417
|
|
|
1540
1418
|
response_data: Any = None
|
|
1541
1419
|
if utils.match_response(http_res, "200", "application/json"):
|
|
1542
|
-
return
|
|
1420
|
+
return unmarshal_json_response(models.ConversationMessages, http_res)
|
|
1543
1421
|
if utils.match_response(http_res, "422", "application/json"):
|
|
1544
|
-
response_data =
|
|
1545
|
-
|
|
1422
|
+
response_data = unmarshal_json_response(
|
|
1423
|
+
models.HTTPValidationErrorData, http_res
|
|
1546
1424
|
)
|
|
1547
|
-
raise models.HTTPValidationError(
|
|
1425
|
+
raise models.HTTPValidationError(response_data, http_res)
|
|
1548
1426
|
if utils.match_response(http_res, "4XX", "*"):
|
|
1549
1427
|
http_res_text = await utils.stream_to_text_async(http_res)
|
|
1550
|
-
raise models.SDKError(
|
|
1551
|
-
"API error occurred", http_res.status_code, http_res_text, http_res
|
|
1552
|
-
)
|
|
1428
|
+
raise models.SDKError("API error occurred", http_res, http_res_text)
|
|
1553
1429
|
if utils.match_response(http_res, "5XX", "*"):
|
|
1554
1430
|
http_res_text = await utils.stream_to_text_async(http_res)
|
|
1555
|
-
raise models.SDKError(
|
|
1556
|
-
"API error occurred", http_res.status_code, http_res_text, http_res
|
|
1557
|
-
)
|
|
1431
|
+
raise models.SDKError("API error occurred", http_res, http_res_text)
|
|
1558
1432
|
|
|
1559
|
-
|
|
1560
|
-
http_res_text = await utils.stream_to_text_async(http_res)
|
|
1561
|
-
raise models.SDKError(
|
|
1562
|
-
f"Unexpected response received (code: {http_res.status_code}, type: {content_type})",
|
|
1563
|
-
http_res.status_code,
|
|
1564
|
-
http_res_text,
|
|
1565
|
-
http_res,
|
|
1566
|
-
)
|
|
1433
|
+
raise models.SDKError("Unexpected response received", http_res)
|
|
1567
1434
|
|
|
1568
1435
|
def restart(
|
|
1569
1436
|
self,
|
|
@@ -1672,31 +1539,20 @@ class Conversations(BaseSDK):
|
|
|
1672
1539
|
|
|
1673
1540
|
response_data: Any = None
|
|
1674
1541
|
if utils.match_response(http_res, "200", "application/json"):
|
|
1675
|
-
return
|
|
1542
|
+
return unmarshal_json_response(models.ConversationResponse, http_res)
|
|
1676
1543
|
if utils.match_response(http_res, "422", "application/json"):
|
|
1677
|
-
response_data =
|
|
1678
|
-
|
|
1544
|
+
response_data = unmarshal_json_response(
|
|
1545
|
+
models.HTTPValidationErrorData, http_res
|
|
1679
1546
|
)
|
|
1680
|
-
raise models.HTTPValidationError(
|
|
1547
|
+
raise models.HTTPValidationError(response_data, http_res)
|
|
1681
1548
|
if utils.match_response(http_res, "4XX", "*"):
|
|
1682
1549
|
http_res_text = utils.stream_to_text(http_res)
|
|
1683
|
-
raise models.SDKError(
|
|
1684
|
-
"API error occurred", http_res.status_code, http_res_text, http_res
|
|
1685
|
-
)
|
|
1550
|
+
raise models.SDKError("API error occurred", http_res, http_res_text)
|
|
1686
1551
|
if utils.match_response(http_res, "5XX", "*"):
|
|
1687
1552
|
http_res_text = utils.stream_to_text(http_res)
|
|
1688
|
-
raise models.SDKError(
|
|
1689
|
-
"API error occurred", http_res.status_code, http_res_text, http_res
|
|
1690
|
-
)
|
|
1553
|
+
raise models.SDKError("API error occurred", http_res, http_res_text)
|
|
1691
1554
|
|
|
1692
|
-
|
|
1693
|
-
http_res_text = utils.stream_to_text(http_res)
|
|
1694
|
-
raise models.SDKError(
|
|
1695
|
-
f"Unexpected response received (code: {http_res.status_code}, type: {content_type})",
|
|
1696
|
-
http_res.status_code,
|
|
1697
|
-
http_res_text,
|
|
1698
|
-
http_res,
|
|
1699
|
-
)
|
|
1555
|
+
raise models.SDKError("Unexpected response received", http_res)
|
|
1700
1556
|
|
|
1701
1557
|
async def restart_async(
|
|
1702
1558
|
self,
|
|
@@ -1805,31 +1661,20 @@ class Conversations(BaseSDK):
|
|
|
1805
1661
|
|
|
1806
1662
|
response_data: Any = None
|
|
1807
1663
|
if utils.match_response(http_res, "200", "application/json"):
|
|
1808
|
-
return
|
|
1664
|
+
return unmarshal_json_response(models.ConversationResponse, http_res)
|
|
1809
1665
|
if utils.match_response(http_res, "422", "application/json"):
|
|
1810
|
-
response_data =
|
|
1811
|
-
|
|
1666
|
+
response_data = unmarshal_json_response(
|
|
1667
|
+
models.HTTPValidationErrorData, http_res
|
|
1812
1668
|
)
|
|
1813
|
-
raise models.HTTPValidationError(
|
|
1669
|
+
raise models.HTTPValidationError(response_data, http_res)
|
|
1814
1670
|
if utils.match_response(http_res, "4XX", "*"):
|
|
1815
1671
|
http_res_text = await utils.stream_to_text_async(http_res)
|
|
1816
|
-
raise models.SDKError(
|
|
1817
|
-
"API error occurred", http_res.status_code, http_res_text, http_res
|
|
1818
|
-
)
|
|
1672
|
+
raise models.SDKError("API error occurred", http_res, http_res_text)
|
|
1819
1673
|
if utils.match_response(http_res, "5XX", "*"):
|
|
1820
1674
|
http_res_text = await utils.stream_to_text_async(http_res)
|
|
1821
|
-
raise models.SDKError(
|
|
1822
|
-
"API error occurred", http_res.status_code, http_res_text, http_res
|
|
1823
|
-
)
|
|
1675
|
+
raise models.SDKError("API error occurred", http_res, http_res_text)
|
|
1824
1676
|
|
|
1825
|
-
|
|
1826
|
-
http_res_text = await utils.stream_to_text_async(http_res)
|
|
1827
|
-
raise models.SDKError(
|
|
1828
|
-
f"Unexpected response received (code: {http_res.status_code}, type: {content_type})",
|
|
1829
|
-
http_res.status_code,
|
|
1830
|
-
http_res_text,
|
|
1831
|
-
http_res,
|
|
1832
|
-
)
|
|
1677
|
+
raise models.SDKError("Unexpected response received", http_res)
|
|
1833
1678
|
|
|
1834
1679
|
def start_stream(
|
|
1835
1680
|
self,
|
|
@@ -1955,32 +1800,23 @@ class Conversations(BaseSDK):
|
|
|
1955
1800
|
return eventstreaming.EventStream(
|
|
1956
1801
|
http_res,
|
|
1957
1802
|
lambda raw: utils.unmarshal_json(raw, models.ConversationEvents),
|
|
1803
|
+
client_ref=self,
|
|
1958
1804
|
)
|
|
1959
1805
|
if utils.match_response(http_res, "422", "application/json"):
|
|
1960
1806
|
http_res_text = utils.stream_to_text(http_res)
|
|
1961
|
-
response_data =
|
|
1962
|
-
|
|
1807
|
+
response_data = unmarshal_json_response(
|
|
1808
|
+
models.HTTPValidationErrorData, http_res, http_res_text
|
|
1963
1809
|
)
|
|
1964
|
-
raise models.HTTPValidationError(
|
|
1810
|
+
raise models.HTTPValidationError(response_data, http_res, http_res_text)
|
|
1965
1811
|
if utils.match_response(http_res, "4XX", "*"):
|
|
1966
1812
|
http_res_text = utils.stream_to_text(http_res)
|
|
1967
|
-
raise models.SDKError(
|
|
1968
|
-
"API error occurred", http_res.status_code, http_res_text, http_res
|
|
1969
|
-
)
|
|
1813
|
+
raise models.SDKError("API error occurred", http_res, http_res_text)
|
|
1970
1814
|
if utils.match_response(http_res, "5XX", "*"):
|
|
1971
1815
|
http_res_text = utils.stream_to_text(http_res)
|
|
1972
|
-
raise models.SDKError(
|
|
1973
|
-
"API error occurred", http_res.status_code, http_res_text, http_res
|
|
1974
|
-
)
|
|
1816
|
+
raise models.SDKError("API error occurred", http_res, http_res_text)
|
|
1975
1817
|
|
|
1976
|
-
content_type = http_res.headers.get("Content-Type")
|
|
1977
1818
|
http_res_text = utils.stream_to_text(http_res)
|
|
1978
|
-
raise models.SDKError(
|
|
1979
|
-
f"Unexpected response received (code: {http_res.status_code}, type: {content_type})",
|
|
1980
|
-
http_res.status_code,
|
|
1981
|
-
http_res_text,
|
|
1982
|
-
http_res,
|
|
1983
|
-
)
|
|
1819
|
+
raise models.SDKError("Unexpected response received", http_res, http_res_text)
|
|
1984
1820
|
|
|
1985
1821
|
async def start_stream_async(
|
|
1986
1822
|
self,
|
|
@@ -2106,32 +1942,23 @@ class Conversations(BaseSDK):
|
|
|
2106
1942
|
return eventstreaming.EventStreamAsync(
|
|
2107
1943
|
http_res,
|
|
2108
1944
|
lambda raw: utils.unmarshal_json(raw, models.ConversationEvents),
|
|
1945
|
+
client_ref=self,
|
|
2109
1946
|
)
|
|
2110
1947
|
if utils.match_response(http_res, "422", "application/json"):
|
|
2111
1948
|
http_res_text = await utils.stream_to_text_async(http_res)
|
|
2112
|
-
response_data =
|
|
2113
|
-
|
|
1949
|
+
response_data = unmarshal_json_response(
|
|
1950
|
+
models.HTTPValidationErrorData, http_res, http_res_text
|
|
2114
1951
|
)
|
|
2115
|
-
raise models.HTTPValidationError(
|
|
1952
|
+
raise models.HTTPValidationError(response_data, http_res, http_res_text)
|
|
2116
1953
|
if utils.match_response(http_res, "4XX", "*"):
|
|
2117
1954
|
http_res_text = await utils.stream_to_text_async(http_res)
|
|
2118
|
-
raise models.SDKError(
|
|
2119
|
-
"API error occurred", http_res.status_code, http_res_text, http_res
|
|
2120
|
-
)
|
|
1955
|
+
raise models.SDKError("API error occurred", http_res, http_res_text)
|
|
2121
1956
|
if utils.match_response(http_res, "5XX", "*"):
|
|
2122
1957
|
http_res_text = await utils.stream_to_text_async(http_res)
|
|
2123
|
-
raise models.SDKError(
|
|
2124
|
-
"API error occurred", http_res.status_code, http_res_text, http_res
|
|
2125
|
-
)
|
|
1958
|
+
raise models.SDKError("API error occurred", http_res, http_res_text)
|
|
2126
1959
|
|
|
2127
|
-
content_type = http_res.headers.get("Content-Type")
|
|
2128
1960
|
http_res_text = await utils.stream_to_text_async(http_res)
|
|
2129
|
-
raise models.SDKError(
|
|
2130
|
-
f"Unexpected response received (code: {http_res.status_code}, type: {content_type})",
|
|
2131
|
-
http_res.status_code,
|
|
2132
|
-
http_res_text,
|
|
2133
|
-
http_res,
|
|
2134
|
-
)
|
|
1961
|
+
raise models.SDKError("Unexpected response received", http_res, http_res_text)
|
|
2135
1962
|
|
|
2136
1963
|
def append_stream(
|
|
2137
1964
|
self,
|
|
@@ -2241,32 +2068,23 @@ class Conversations(BaseSDK):
|
|
|
2241
2068
|
return eventstreaming.EventStream(
|
|
2242
2069
|
http_res,
|
|
2243
2070
|
lambda raw: utils.unmarshal_json(raw, models.ConversationEvents),
|
|
2071
|
+
client_ref=self,
|
|
2244
2072
|
)
|
|
2245
2073
|
if utils.match_response(http_res, "422", "application/json"):
|
|
2246
2074
|
http_res_text = utils.stream_to_text(http_res)
|
|
2247
|
-
response_data =
|
|
2248
|
-
|
|
2075
|
+
response_data = unmarshal_json_response(
|
|
2076
|
+
models.HTTPValidationErrorData, http_res, http_res_text
|
|
2249
2077
|
)
|
|
2250
|
-
raise models.HTTPValidationError(
|
|
2078
|
+
raise models.HTTPValidationError(response_data, http_res, http_res_text)
|
|
2251
2079
|
if utils.match_response(http_res, "4XX", "*"):
|
|
2252
2080
|
http_res_text = utils.stream_to_text(http_res)
|
|
2253
|
-
raise models.SDKError(
|
|
2254
|
-
"API error occurred", http_res.status_code, http_res_text, http_res
|
|
2255
|
-
)
|
|
2081
|
+
raise models.SDKError("API error occurred", http_res, http_res_text)
|
|
2256
2082
|
if utils.match_response(http_res, "5XX", "*"):
|
|
2257
2083
|
http_res_text = utils.stream_to_text(http_res)
|
|
2258
|
-
raise models.SDKError(
|
|
2259
|
-
"API error occurred", http_res.status_code, http_res_text, http_res
|
|
2260
|
-
)
|
|
2084
|
+
raise models.SDKError("API error occurred", http_res, http_res_text)
|
|
2261
2085
|
|
|
2262
|
-
content_type = http_res.headers.get("Content-Type")
|
|
2263
2086
|
http_res_text = utils.stream_to_text(http_res)
|
|
2264
|
-
raise models.SDKError(
|
|
2265
|
-
f"Unexpected response received (code: {http_res.status_code}, type: {content_type})",
|
|
2266
|
-
http_res.status_code,
|
|
2267
|
-
http_res_text,
|
|
2268
|
-
http_res,
|
|
2269
|
-
)
|
|
2087
|
+
raise models.SDKError("Unexpected response received", http_res, http_res_text)
|
|
2270
2088
|
|
|
2271
2089
|
async def append_stream_async(
|
|
2272
2090
|
self,
|
|
@@ -2376,32 +2194,23 @@ class Conversations(BaseSDK):
|
|
|
2376
2194
|
return eventstreaming.EventStreamAsync(
|
|
2377
2195
|
http_res,
|
|
2378
2196
|
lambda raw: utils.unmarshal_json(raw, models.ConversationEvents),
|
|
2197
|
+
client_ref=self,
|
|
2379
2198
|
)
|
|
2380
2199
|
if utils.match_response(http_res, "422", "application/json"):
|
|
2381
2200
|
http_res_text = await utils.stream_to_text_async(http_res)
|
|
2382
|
-
response_data =
|
|
2383
|
-
|
|
2201
|
+
response_data = unmarshal_json_response(
|
|
2202
|
+
models.HTTPValidationErrorData, http_res, http_res_text
|
|
2384
2203
|
)
|
|
2385
|
-
raise models.HTTPValidationError(
|
|
2204
|
+
raise models.HTTPValidationError(response_data, http_res, http_res_text)
|
|
2386
2205
|
if utils.match_response(http_res, "4XX", "*"):
|
|
2387
2206
|
http_res_text = await utils.stream_to_text_async(http_res)
|
|
2388
|
-
raise models.SDKError(
|
|
2389
|
-
"API error occurred", http_res.status_code, http_res_text, http_res
|
|
2390
|
-
)
|
|
2207
|
+
raise models.SDKError("API error occurred", http_res, http_res_text)
|
|
2391
2208
|
if utils.match_response(http_res, "5XX", "*"):
|
|
2392
2209
|
http_res_text = await utils.stream_to_text_async(http_res)
|
|
2393
|
-
raise models.SDKError(
|
|
2394
|
-
"API error occurred", http_res.status_code, http_res_text, http_res
|
|
2395
|
-
)
|
|
2210
|
+
raise models.SDKError("API error occurred", http_res, http_res_text)
|
|
2396
2211
|
|
|
2397
|
-
content_type = http_res.headers.get("Content-Type")
|
|
2398
2212
|
http_res_text = await utils.stream_to_text_async(http_res)
|
|
2399
|
-
raise models.SDKError(
|
|
2400
|
-
f"Unexpected response received (code: {http_res.status_code}, type: {content_type})",
|
|
2401
|
-
http_res.status_code,
|
|
2402
|
-
http_res_text,
|
|
2403
|
-
http_res,
|
|
2404
|
-
)
|
|
2213
|
+
raise models.SDKError("Unexpected response received", http_res, http_res_text)
|
|
2405
2214
|
|
|
2406
2215
|
def restart_stream(
|
|
2407
2216
|
self,
|
|
@@ -2514,32 +2323,23 @@ class Conversations(BaseSDK):
|
|
|
2514
2323
|
return eventstreaming.EventStream(
|
|
2515
2324
|
http_res,
|
|
2516
2325
|
lambda raw: utils.unmarshal_json(raw, models.ConversationEvents),
|
|
2326
|
+
client_ref=self,
|
|
2517
2327
|
)
|
|
2518
2328
|
if utils.match_response(http_res, "422", "application/json"):
|
|
2519
2329
|
http_res_text = utils.stream_to_text(http_res)
|
|
2520
|
-
response_data =
|
|
2521
|
-
|
|
2330
|
+
response_data = unmarshal_json_response(
|
|
2331
|
+
models.HTTPValidationErrorData, http_res, http_res_text
|
|
2522
2332
|
)
|
|
2523
|
-
raise models.HTTPValidationError(
|
|
2333
|
+
raise models.HTTPValidationError(response_data, http_res, http_res_text)
|
|
2524
2334
|
if utils.match_response(http_res, "4XX", "*"):
|
|
2525
2335
|
http_res_text = utils.stream_to_text(http_res)
|
|
2526
|
-
raise models.SDKError(
|
|
2527
|
-
"API error occurred", http_res.status_code, http_res_text, http_res
|
|
2528
|
-
)
|
|
2336
|
+
raise models.SDKError("API error occurred", http_res, http_res_text)
|
|
2529
2337
|
if utils.match_response(http_res, "5XX", "*"):
|
|
2530
2338
|
http_res_text = utils.stream_to_text(http_res)
|
|
2531
|
-
raise models.SDKError(
|
|
2532
|
-
"API error occurred", http_res.status_code, http_res_text, http_res
|
|
2533
|
-
)
|
|
2339
|
+
raise models.SDKError("API error occurred", http_res, http_res_text)
|
|
2534
2340
|
|
|
2535
|
-
content_type = http_res.headers.get("Content-Type")
|
|
2536
2341
|
http_res_text = utils.stream_to_text(http_res)
|
|
2537
|
-
raise models.SDKError(
|
|
2538
|
-
f"Unexpected response received (code: {http_res.status_code}, type: {content_type})",
|
|
2539
|
-
http_res.status_code,
|
|
2540
|
-
http_res_text,
|
|
2541
|
-
http_res,
|
|
2542
|
-
)
|
|
2342
|
+
raise models.SDKError("Unexpected response received", http_res, http_res_text)
|
|
2543
2343
|
|
|
2544
2344
|
async def restart_stream_async(
|
|
2545
2345
|
self,
|
|
@@ -2652,29 +2452,20 @@ class Conversations(BaseSDK):
|
|
|
2652
2452
|
return eventstreaming.EventStreamAsync(
|
|
2653
2453
|
http_res,
|
|
2654
2454
|
lambda raw: utils.unmarshal_json(raw, models.ConversationEvents),
|
|
2455
|
+
client_ref=self,
|
|
2655
2456
|
)
|
|
2656
2457
|
if utils.match_response(http_res, "422", "application/json"):
|
|
2657
2458
|
http_res_text = await utils.stream_to_text_async(http_res)
|
|
2658
|
-
response_data =
|
|
2659
|
-
|
|
2459
|
+
response_data = unmarshal_json_response(
|
|
2460
|
+
models.HTTPValidationErrorData, http_res, http_res_text
|
|
2660
2461
|
)
|
|
2661
|
-
raise models.HTTPValidationError(
|
|
2462
|
+
raise models.HTTPValidationError(response_data, http_res, http_res_text)
|
|
2662
2463
|
if utils.match_response(http_res, "4XX", "*"):
|
|
2663
2464
|
http_res_text = await utils.stream_to_text_async(http_res)
|
|
2664
|
-
raise models.SDKError(
|
|
2665
|
-
"API error occurred", http_res.status_code, http_res_text, http_res
|
|
2666
|
-
)
|
|
2465
|
+
raise models.SDKError("API error occurred", http_res, http_res_text)
|
|
2667
2466
|
if utils.match_response(http_res, "5XX", "*"):
|
|
2668
2467
|
http_res_text = await utils.stream_to_text_async(http_res)
|
|
2669
|
-
raise models.SDKError(
|
|
2670
|
-
"API error occurred", http_res.status_code, http_res_text, http_res
|
|
2671
|
-
)
|
|
2468
|
+
raise models.SDKError("API error occurred", http_res, http_res_text)
|
|
2672
2469
|
|
|
2673
|
-
content_type = http_res.headers.get("Content-Type")
|
|
2674
2470
|
http_res_text = await utils.stream_to_text_async(http_res)
|
|
2675
|
-
raise models.SDKError(
|
|
2676
|
-
f"Unexpected response received (code: {http_res.status_code}, type: {content_type})",
|
|
2677
|
-
http_res.status_code,
|
|
2678
|
-
http_res_text,
|
|
2679
|
-
http_res,
|
|
2680
|
-
)
|
|
2471
|
+
raise models.SDKError("Unexpected response received", http_res, http_res_text)
|