ignos-internal-api-client 20240617.0.9575__py3-none-any.whl → 20240813.0.9983__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.
@@ -755,6 +755,66 @@ def build_sustainability_setup_map_factory_template_ferro_amp_request( # pylint
755
755
  return HttpRequest(method="POST", url=_url, headers=_headers, **kwargs)
756
756
 
757
757
 
758
+ def build_tenant_credentials_list_tenant_credential_types_request( # pylint: disable=name-too-long
759
+ tenant_id: str, **kwargs: Any
760
+ ) -> HttpRequest:
761
+ _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {})
762
+
763
+ accept = _headers.pop("Accept", "application/json")
764
+
765
+ # Construct URL
766
+ _url = "/tenantcredentials/{tenantId}"
767
+ path_format_arguments = {
768
+ "tenantId": _SERIALIZER.url("tenant_id", tenant_id, "str"),
769
+ }
770
+
771
+ _url: str = _url.format(**path_format_arguments) # type: ignore
772
+
773
+ # Construct headers
774
+ _headers["Accept"] = _SERIALIZER.header("accept", accept, "str")
775
+
776
+ return HttpRequest(method="GET", url=_url, headers=_headers, **kwargs)
777
+
778
+
779
+ def build_tenant_credentials_add_integration_credential_type_request( # pylint: disable=name-too-long
780
+ tenant_id: str, **kwargs: Any
781
+ ) -> HttpRequest:
782
+ _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {})
783
+
784
+ content_type: Optional[str] = kwargs.pop("content_type", _headers.pop("Content-Type", None))
785
+ accept = _headers.pop("Accept", "application/json")
786
+
787
+ # Construct URL
788
+ _url = "/tenantcredentials/{tenantId}"
789
+ path_format_arguments = {
790
+ "tenantId": _SERIALIZER.url("tenant_id", tenant_id, "str"),
791
+ }
792
+
793
+ _url: str = _url.format(**path_format_arguments) # type: ignore
794
+
795
+ # Construct headers
796
+ if content_type is not None:
797
+ _headers["Content-Type"] = _SERIALIZER.header("content_type", content_type, "str")
798
+ _headers["Accept"] = _SERIALIZER.header("accept", accept, "str")
799
+
800
+ return HttpRequest(method="POST", url=_url, headers=_headers, **kwargs)
801
+
802
+
803
+ def build_tenant_credentials_delete_integration_credential_type_request( # pylint: disable=name-too-long
804
+ tenant_id: str, id: str, **kwargs: Any
805
+ ) -> HttpRequest:
806
+ # Construct URL
807
+ _url = "/tenantcredentials/{tenantId}/credentials/{id}"
808
+ path_format_arguments = {
809
+ "tenantId": _SERIALIZER.url("tenant_id", tenant_id, "str"),
810
+ "id": _SERIALIZER.url("id", id, "str"),
811
+ }
812
+
813
+ _url: str = _url.format(**path_format_arguments) # type: ignore
814
+
815
+ return HttpRequest(method="DELETE", url=_url, **kwargs)
816
+
817
+
758
818
  def build_tenants_list_tenants_details_request( # pylint: disable=name-too-long
759
819
  *, tenant_id_prefix: Optional[str] = None, app_id: Optional[str] = None, **kwargs: Any
760
820
  ) -> HttpRequest:
@@ -848,12 +908,10 @@ class AppsOperations:
848
908
  response = pipeline_response.http_response
849
909
 
850
910
  if response.status_code not in [200]:
851
- if _stream:
852
- response.read() # Load the body in memory and close the socket
853
911
  map_error(status_code=response.status_code, response=response, error_map=error_map)
854
912
  raise HttpResponseError(response=response)
855
913
 
856
- deserialized = self._deserialize("[AppDto]", pipeline_response)
914
+ deserialized = self._deserialize("[AppDto]", pipeline_response.http_response)
857
915
 
858
916
  if cls:
859
917
  return cls(pipeline_response, deserialized, {}) # type: ignore
@@ -951,12 +1009,10 @@ class AppsOperations:
951
1009
  response = pipeline_response.http_response
952
1010
 
953
1011
  if response.status_code not in [200]:
954
- if _stream:
955
- response.read() # Load the body in memory and close the socket
956
1012
  map_error(status_code=response.status_code, response=response, error_map=error_map)
957
1013
  raise HttpResponseError(response=response)
958
1014
 
959
- deserialized = self._deserialize("AppDto", pipeline_response)
1015
+ deserialized = self._deserialize("AppDto", pipeline_response.http_response)
960
1016
 
961
1017
  if cls:
962
1018
  return cls(pipeline_response, deserialized, {}) # type: ignore
@@ -1068,12 +1124,10 @@ class AppsOperations:
1068
1124
  response = pipeline_response.http_response
1069
1125
 
1070
1126
  if response.status_code not in [200]:
1071
- if _stream:
1072
- response.read() # Load the body in memory and close the socket
1073
1127
  map_error(status_code=response.status_code, response=response, error_map=error_map)
1074
1128
  raise HttpResponseError(response=response)
1075
1129
 
1076
- deserialized = self._deserialize("AppDto", pipeline_response)
1130
+ deserialized = self._deserialize("AppDto", pipeline_response.http_response)
1077
1131
 
1078
1132
  if cls:
1079
1133
  return cls(pipeline_response, deserialized, {}) # type: ignore
@@ -1135,12 +1189,10 @@ class AzureRegionsOperations:
1135
1189
  response = pipeline_response.http_response
1136
1190
 
1137
1191
  if response.status_code not in [200]:
1138
- if _stream:
1139
- response.read() # Load the body in memory and close the socket
1140
1192
  map_error(status_code=response.status_code, response=response, error_map=error_map)
1141
1193
  raise HttpResponseError(response=response)
1142
1194
 
1143
- deserialized = self._deserialize("[AzureRegionDto]", pipeline_response)
1195
+ deserialized = self._deserialize("[AzureRegionDto]", pipeline_response.http_response)
1144
1196
 
1145
1197
  if cls:
1146
1198
  return cls(pipeline_response, deserialized, {}) # type: ignore
@@ -1202,12 +1254,10 @@ class CdfClustersOperations:
1202
1254
  response = pipeline_response.http_response
1203
1255
 
1204
1256
  if response.status_code not in [200]:
1205
- if _stream:
1206
- response.read() # Load the body in memory and close the socket
1207
1257
  map_error(status_code=response.status_code, response=response, error_map=error_map)
1208
1258
  raise HttpResponseError(response=response)
1209
1259
 
1210
- deserialized = self._deserialize("[CdfClusterDto]", pipeline_response)
1260
+ deserialized = self._deserialize("[CdfClusterDto]", pipeline_response.http_response)
1211
1261
 
1212
1262
  if cls:
1213
1263
  return cls(pipeline_response, deserialized, {}) # type: ignore
@@ -1301,12 +1351,10 @@ class CdfClustersOperations:
1301
1351
  response = pipeline_response.http_response
1302
1352
 
1303
1353
  if response.status_code not in [200]:
1304
- if _stream:
1305
- response.read() # Load the body in memory and close the socket
1306
1354
  map_error(status_code=response.status_code, response=response, error_map=error_map)
1307
1355
  raise HttpResponseError(response=response)
1308
1356
 
1309
- deserialized = self._deserialize("CdfClusterDto", pipeline_response)
1357
+ deserialized = self._deserialize("CdfClusterDto", pipeline_response.http_response)
1310
1358
 
1311
1359
  if cls:
1312
1360
  return cls(pipeline_response, deserialized, {}) # type: ignore
@@ -1413,12 +1461,10 @@ class CdfClustersOperations:
1413
1461
  response = pipeline_response.http_response
1414
1462
 
1415
1463
  if response.status_code not in [200]:
1416
- if _stream:
1417
- response.read() # Load the body in memory and close the socket
1418
1464
  map_error(status_code=response.status_code, response=response, error_map=error_map)
1419
1465
  raise HttpResponseError(response=response)
1420
1466
 
1421
- deserialized = self._deserialize("CdfClusterDto", pipeline_response)
1467
+ deserialized = self._deserialize("CdfClusterDto", pipeline_response.http_response)
1422
1468
 
1423
1469
  if cls:
1424
1470
  return cls(pipeline_response, deserialized, {}) # type: ignore
@@ -1480,12 +1526,10 @@ class CountriesOperations:
1480
1526
  response = pipeline_response.http_response
1481
1527
 
1482
1528
  if response.status_code not in [200]:
1483
- if _stream:
1484
- response.read() # Load the body in memory and close the socket
1485
1529
  map_error(status_code=response.status_code, response=response, error_map=error_map)
1486
1530
  raise HttpResponseError(response=response)
1487
1531
 
1488
- deserialized = self._deserialize("[CountryDto]", pipeline_response)
1532
+ deserialized = self._deserialize("[CountryDto]", pipeline_response.http_response)
1489
1533
 
1490
1534
  if cls:
1491
1535
  return cls(pipeline_response, deserialized, {}) # type: ignore
@@ -1549,12 +1593,10 @@ class CustomersOperations:
1549
1593
  response = pipeline_response.http_response
1550
1594
 
1551
1595
  if response.status_code not in [200]:
1552
- if _stream:
1553
- response.read() # Load the body in memory and close the socket
1554
1596
  map_error(status_code=response.status_code, response=response, error_map=error_map)
1555
1597
  raise HttpResponseError(response=response)
1556
1598
 
1557
- deserialized = self._deserialize("[IgnosCustomerDto]", pipeline_response)
1599
+ deserialized = self._deserialize("[IgnosCustomerDto]", pipeline_response.http_response)
1558
1600
 
1559
1601
  if cls:
1560
1602
  return cls(pipeline_response, deserialized, {}) # type: ignore
@@ -1658,12 +1700,10 @@ class CustomersOperations:
1658
1700
  response = pipeline_response.http_response
1659
1701
 
1660
1702
  if response.status_code not in [200]:
1661
- if _stream:
1662
- response.read() # Load the body in memory and close the socket
1663
1703
  map_error(status_code=response.status_code, response=response, error_map=error_map)
1664
1704
  raise HttpResponseError(response=response)
1665
1705
 
1666
- deserialized = self._deserialize("IgnosCustomerDto", pipeline_response)
1706
+ deserialized = self._deserialize("IgnosCustomerDto", pipeline_response.http_response)
1667
1707
 
1668
1708
  if cls:
1669
1709
  return cls(pipeline_response, deserialized, {}) # type: ignore
@@ -1710,12 +1750,10 @@ class CustomersOperations:
1710
1750
  response = pipeline_response.http_response
1711
1751
 
1712
1752
  if response.status_code not in [200]:
1713
- if _stream:
1714
- response.read() # Load the body in memory and close the socket
1715
1753
  map_error(status_code=response.status_code, response=response, error_map=error_map)
1716
1754
  raise HttpResponseError(response=response)
1717
1755
 
1718
- deserialized = self._deserialize("IgnosCustomerDto", pipeline_response)
1756
+ deserialized = self._deserialize("IgnosCustomerDto", pipeline_response.http_response)
1719
1757
 
1720
1758
  if cls:
1721
1759
  return cls(pipeline_response, deserialized, {}) # type: ignore
@@ -1827,12 +1865,10 @@ class CustomersOperations:
1827
1865
  response = pipeline_response.http_response
1828
1866
 
1829
1867
  if response.status_code not in [200]:
1830
- if _stream:
1831
- response.read() # Load the body in memory and close the socket
1832
1868
  map_error(status_code=response.status_code, response=response, error_map=error_map)
1833
1869
  raise HttpResponseError(response=response)
1834
1870
 
1835
- deserialized = self._deserialize("IgnosCustomerDto", pipeline_response)
1871
+ deserialized = self._deserialize("IgnosCustomerDto", pipeline_response.http_response)
1836
1872
 
1837
1873
  if cls:
1838
1874
  return cls(pipeline_response, deserialized, {}) # type: ignore
@@ -1879,12 +1915,10 @@ class CustomersOperations:
1879
1915
  response = pipeline_response.http_response
1880
1916
 
1881
1917
  if response.status_code not in [200]:
1882
- if _stream:
1883
- response.read() # Load the body in memory and close the socket
1884
1918
  map_error(status_code=response.status_code, response=response, error_map=error_map)
1885
1919
  raise HttpResponseError(response=response)
1886
1920
 
1887
- deserialized = self._deserialize("[TenantDto]", pipeline_response)
1921
+ deserialized = self._deserialize("[TenantDto]", pipeline_response.http_response)
1888
1922
 
1889
1923
  if cls:
1890
1924
  return cls(pipeline_response, deserialized, {}) # type: ignore
@@ -1996,12 +2030,10 @@ class CustomersOperations:
1996
2030
  response = pipeline_response.http_response
1997
2031
 
1998
2032
  if response.status_code not in [200]:
1999
- if _stream:
2000
- response.read() # Load the body in memory and close the socket
2001
2033
  map_error(status_code=response.status_code, response=response, error_map=error_map)
2002
2034
  raise HttpResponseError(response=response)
2003
2035
 
2004
- deserialized = self._deserialize("TenantDto", pipeline_response)
2036
+ deserialized = self._deserialize("TenantDto", pipeline_response.http_response)
2005
2037
 
2006
2038
  if cls:
2007
2039
  return cls(pipeline_response, deserialized, {}) # type: ignore
@@ -2131,12 +2163,10 @@ class CustomersOperations:
2131
2163
  response = pipeline_response.http_response
2132
2164
 
2133
2165
  if response.status_code not in [200]:
2134
- if _stream:
2135
- response.read() # Load the body in memory and close the socket
2136
2166
  map_error(status_code=response.status_code, response=response, error_map=error_map)
2137
2167
  raise HttpResponseError(response=response)
2138
2168
 
2139
- deserialized = self._deserialize("TenantDto", pipeline_response)
2169
+ deserialized = self._deserialize("TenantDto", pipeline_response.http_response)
2140
2170
 
2141
2171
  if cls:
2142
2172
  return cls(pipeline_response, deserialized, {}) # type: ignore
@@ -2186,12 +2216,10 @@ class CustomersOperations:
2186
2216
  response = pipeline_response.http_response
2187
2217
 
2188
2218
  if response.status_code not in [200]:
2189
- if _stream:
2190
- response.read() # Load the body in memory and close the socket
2191
2219
  map_error(status_code=response.status_code, response=response, error_map=error_map)
2192
2220
  raise HttpResponseError(response=response)
2193
2221
 
2194
- deserialized = self._deserialize("CdfConfigDto", pipeline_response)
2222
+ deserialized = self._deserialize("CdfConfigDto", pipeline_response.http_response)
2195
2223
 
2196
2224
  if cls:
2197
2225
  return cls(pipeline_response, deserialized, {}) # type: ignore
@@ -2322,12 +2350,10 @@ class CustomersOperations:
2322
2350
  response = pipeline_response.http_response
2323
2351
 
2324
2352
  if response.status_code not in [200]:
2325
- if _stream:
2326
- response.read() # Load the body in memory and close the socket
2327
2353
  map_error(status_code=response.status_code, response=response, error_map=error_map)
2328
2354
  raise HttpResponseError(response=response)
2329
2355
 
2330
- deserialized = self._deserialize("CdfConfigDto", pipeline_response)
2356
+ deserialized = self._deserialize("CdfConfigDto", pipeline_response.http_response)
2331
2357
 
2332
2358
  if cls:
2333
2359
  return cls(pipeline_response, deserialized, {}) # type: ignore
@@ -2374,12 +2400,10 @@ class CustomersOperations:
2374
2400
  response = pipeline_response.http_response
2375
2401
 
2376
2402
  if response.status_code not in [200]:
2377
- if _stream:
2378
- response.read() # Load the body in memory and close the socket
2379
2403
  map_error(status_code=response.status_code, response=response, error_map=error_map)
2380
2404
  raise HttpResponseError(response=response)
2381
2405
 
2382
- deserialized = self._deserialize("[CustomerAppDto]", pipeline_response)
2406
+ deserialized = self._deserialize("[CustomerAppDto]", pipeline_response.http_response)
2383
2407
 
2384
2408
  if cls:
2385
2409
  return cls(pipeline_response, deserialized, {}) # type: ignore
@@ -2431,8 +2455,6 @@ class CustomersOperations:
2431
2455
  response = pipeline_response.http_response
2432
2456
 
2433
2457
  if response.status_code not in [204]:
2434
- if _stream:
2435
- response.read() # Load the body in memory and close the socket
2436
2458
  map_error(status_code=response.status_code, response=response, error_map=error_map)
2437
2459
  raise HttpResponseError(response=response)
2438
2460
 
@@ -2484,8 +2506,6 @@ class CustomersOperations:
2484
2506
  response = pipeline_response.http_response
2485
2507
 
2486
2508
  if response.status_code not in [204]:
2487
- if _stream:
2488
- response.read() # Load the body in memory and close the socket
2489
2509
  map_error(status_code=response.status_code, response=response, error_map=error_map)
2490
2510
  raise HttpResponseError(response=response)
2491
2511
 
@@ -2527,12 +2547,10 @@ class CustomersOperations:
2527
2547
  response = pipeline_response.http_response
2528
2548
 
2529
2549
  if response.status_code not in [200]:
2530
- if _stream:
2531
- response.read() # Load the body in memory and close the socket
2532
2550
  map_error(status_code=response.status_code, response=response, error_map=error_map)
2533
2551
  raise HttpResponseError(response=response)
2534
2552
 
2535
- deserialized = self._deserialize("[TenantKeyDto]", pipeline_response)
2553
+ deserialized = self._deserialize("[TenantKeyDto]", pipeline_response.http_response)
2536
2554
 
2537
2555
  if cls:
2538
2556
  return cls(pipeline_response, deserialized, {}) # type: ignore
@@ -2574,8 +2592,6 @@ class CustomersOperations:
2574
2592
  response = pipeline_response.http_response
2575
2593
 
2576
2594
  if response.status_code not in [204]:
2577
- if _stream:
2578
- response.read() # Load the body in memory and close the socket
2579
2595
  map_error(status_code=response.status_code, response=response, error_map=error_map)
2580
2596
  raise HttpResponseError(response=response)
2581
2597
 
@@ -2637,8 +2653,6 @@ class DatabasesOperations:
2637
2653
  response = pipeline_response.http_response
2638
2654
 
2639
2655
  if response.status_code not in [200]:
2640
- if _stream:
2641
- response.read() # Load the body in memory and close the socket
2642
2656
  map_error(status_code=response.status_code, response=response, error_map=error_map)
2643
2657
  raise HttpResponseError(response=response)
2644
2658
 
@@ -2703,12 +2717,10 @@ class ErpSyncOperations:
2703
2717
  response = pipeline_response.http_response
2704
2718
 
2705
2719
  if response.status_code not in [200]:
2706
- if _stream:
2707
- response.read() # Load the body in memory and close the socket
2708
2720
  map_error(status_code=response.status_code, response=response, error_map=error_map)
2709
2721
  raise HttpResponseError(response=response)
2710
2722
 
2711
- deserialized = self._deserialize("[ErpSyncErrorDto]", pipeline_response)
2723
+ deserialized = self._deserialize("[ErpSyncErrorDto]", pipeline_response.http_response)
2712
2724
 
2713
2725
  if cls:
2714
2726
  return cls(pipeline_response, deserialized, {}) # type: ignore
@@ -2756,12 +2768,10 @@ class ErpSyncOperations:
2756
2768
  response = pipeline_response.http_response
2757
2769
 
2758
2770
  if response.status_code not in [200]:
2759
- if _stream:
2760
- response.read() # Load the body in memory and close the socket
2761
2771
  map_error(status_code=response.status_code, response=response, error_map=error_map)
2762
2772
  raise HttpResponseError(response=response)
2763
2773
 
2764
- deserialized = self._deserialize("ErpSyncErrorMessage", pipeline_response)
2774
+ deserialized = self._deserialize("ErpSyncErrorMessage", pipeline_response.http_response)
2765
2775
 
2766
2776
  if cls:
2767
2777
  return cls(pipeline_response, deserialized, {}) # type: ignore
@@ -2814,8 +2824,6 @@ class ErpSyncOperations:
2814
2824
  response = pipeline_response.http_response
2815
2825
 
2816
2826
  if response.status_code not in [200]:
2817
- if _stream:
2818
- response.read() # Load the body in memory and close the socket
2819
2827
  map_error(status_code=response.status_code, response=response, error_map=error_map)
2820
2828
  raise HttpResponseError(response=response)
2821
2829
 
@@ -2921,12 +2929,10 @@ class ErpSyncOperations:
2921
2929
  response = pipeline_response.http_response
2922
2930
 
2923
2931
  if response.status_code not in [200]:
2924
- if _stream:
2925
- response.read() # Load the body in memory and close the socket
2926
2932
  map_error(status_code=response.status_code, response=response, error_map=error_map)
2927
2933
  raise HttpResponseError(response=response)
2928
2934
 
2929
- deserialized = self._deserialize("DataSyncOrchestrationTriggerResponse", pipeline_response)
2935
+ deserialized = self._deserialize("DataSyncOrchestrationTriggerResponse", pipeline_response.http_response)
2930
2936
 
2931
2937
  if cls:
2932
2938
  return cls(pipeline_response, deserialized, {}) # type: ignore
@@ -3032,8 +3038,6 @@ class ErpSyncOperations:
3032
3038
  response = pipeline_response.http_response
3033
3039
 
3034
3040
  if response.status_code not in [200]:
3035
- if _stream:
3036
- response.read() # Load the body in memory and close the socket
3037
3041
  map_error(status_code=response.status_code, response=response, error_map=error_map)
3038
3042
  raise HttpResponseError(response=response)
3039
3043
 
@@ -3095,12 +3099,10 @@ class ErpSyncOperations:
3095
3099
  response = pipeline_response.http_response
3096
3100
 
3097
3101
  if response.status_code not in [200]:
3098
- if _stream:
3099
- response.read() # Load the body in memory and close the socket
3100
3102
  map_error(status_code=response.status_code, response=response, error_map=error_map)
3101
3103
  raise HttpResponseError(response=response)
3102
3104
 
3103
- deserialized = self._deserialize("[DataSyncOrchestrationInstance]", pipeline_response)
3105
+ deserialized = self._deserialize("[DataSyncOrchestrationInstance]", pipeline_response.http_response)
3104
3106
 
3105
3107
  if cls:
3106
3108
  return cls(pipeline_response, deserialized, {}) # type: ignore
@@ -3206,8 +3208,6 @@ class ErpSyncOperations:
3206
3208
  response = pipeline_response.http_response
3207
3209
 
3208
3210
  if response.status_code not in [200]:
3209
- if _stream:
3210
- response.read() # Load the body in memory and close the socket
3211
3211
  map_error(status_code=response.status_code, response=response, error_map=error_map)
3212
3212
  raise HttpResponseError(response=response)
3213
3213
 
@@ -3313,8 +3313,6 @@ class ErpSyncOperations:
3313
3313
  response = pipeline_response.http_response
3314
3314
 
3315
3315
  if response.status_code not in [200]:
3316
- if _stream:
3317
- response.read() # Load the body in memory and close the socket
3318
3316
  map_error(status_code=response.status_code, response=response, error_map=error_map)
3319
3317
  raise HttpResponseError(response=response)
3320
3318
 
@@ -3381,12 +3379,10 @@ class PowerOperations:
3381
3379
  response = pipeline_response.http_response
3382
3380
 
3383
3381
  if response.status_code not in [200]:
3384
- if _stream:
3385
- response.read() # Load the body in memory and close the socket
3386
3382
  map_error(status_code=response.status_code, response=response, error_map=error_map)
3387
3383
  raise HttpResponseError(response=response)
3388
3384
 
3389
- deserialized = self._deserialize("[PowerRegionDto]", pipeline_response)
3385
+ deserialized = self._deserialize("[PowerRegionDto]", pipeline_response.http_response)
3390
3386
 
3391
3387
  if cls:
3392
3388
  return cls(pipeline_response, deserialized, {}) # type: ignore
@@ -3480,12 +3476,10 @@ class PowerOperations:
3480
3476
  response = pipeline_response.http_response
3481
3477
 
3482
3478
  if response.status_code not in [200]:
3483
- if _stream:
3484
- response.read() # Load the body in memory and close the socket
3485
3479
  map_error(status_code=response.status_code, response=response, error_map=error_map)
3486
3480
  raise HttpResponseError(response=response)
3487
3481
 
3488
- deserialized = self._deserialize("PowerRegionDto", pipeline_response)
3482
+ deserialized = self._deserialize("PowerRegionDto", pipeline_response.http_response)
3489
3483
 
3490
3484
  if cls:
3491
3485
  return cls(pipeline_response, deserialized, {}) # type: ignore
@@ -3558,8 +3552,6 @@ class PresentationOperations:
3558
3552
  response = pipeline_response.http_response
3559
3553
 
3560
3554
  if response.status_code not in [200]:
3561
- if _stream:
3562
- response.read() # Load the body in memory and close the socket
3563
3555
  map_error(status_code=response.status_code, response=response, error_map=error_map)
3564
3556
  raise HttpResponseError(response=response)
3565
3557
 
@@ -3694,12 +3686,10 @@ class PresentationOperations:
3694
3686
  response = pipeline_response.http_response
3695
3687
 
3696
3688
  if response.status_code not in [200]:
3697
- if _stream:
3698
- response.read() # Load the body in memory and close the socket
3699
3689
  map_error(status_code=response.status_code, response=response, error_map=error_map)
3700
3690
  raise HttpResponseError(response=response)
3701
3691
 
3702
- deserialized = self._deserialize("ComponentSettingsDto", pipeline_response)
3692
+ deserialized = self._deserialize("ComponentSettingsDto", pipeline_response.http_response)
3703
3693
 
3704
3694
  if cls:
3705
3695
  return cls(pipeline_response, deserialized, {}) # type: ignore
@@ -3843,8 +3833,6 @@ class SustainabilitySetupOperations:
3843
3833
  response = pipeline_response.http_response
3844
3834
 
3845
3835
  if response.status_code not in [200]:
3846
- if _stream:
3847
- response.read() # Load the body in memory and close the socket
3848
3836
  map_error(status_code=response.status_code, response=response, error_map=error_map)
3849
3837
  raise HttpResponseError(response=response)
3850
3838
 
@@ -3969,8 +3957,6 @@ class SustainabilitySetupOperations:
3969
3957
  response = pipeline_response.http_response
3970
3958
 
3971
3959
  if response.status_code not in [200]:
3972
- if _stream:
3973
- response.read() # Load the body in memory and close the socket
3974
3960
  map_error(status_code=response.status_code, response=response, error_map=error_map)
3975
3961
  raise HttpResponseError(response=response)
3976
3962
 
@@ -4095,8 +4081,238 @@ class SustainabilitySetupOperations:
4095
4081
  response = pipeline_response.http_response
4096
4082
 
4097
4083
  if response.status_code not in [200]:
4098
- if _stream:
4099
- response.read() # Load the body in memory and close the socket
4084
+ map_error(status_code=response.status_code, response=response, error_map=error_map)
4085
+ raise HttpResponseError(response=response)
4086
+
4087
+ if cls:
4088
+ return cls(pipeline_response, None, {}) # type: ignore
4089
+
4090
+
4091
+ class TenantCredentialsOperations:
4092
+ """
4093
+ .. warning::
4094
+ **DO NOT** instantiate this class directly.
4095
+
4096
+ Instead, you should access the following operations through
4097
+ :class:`~ignos.internal.api.client.IgnosInternalApi`'s
4098
+ :attr:`tenant_credentials` attribute.
4099
+ """
4100
+
4101
+ models = _models
4102
+
4103
+ def __init__(self, *args, **kwargs):
4104
+ input_args = list(args)
4105
+ self._client = input_args.pop(0) if input_args else kwargs.pop("client")
4106
+ self._config = input_args.pop(0) if input_args else kwargs.pop("config")
4107
+ self._serialize = input_args.pop(0) if input_args else kwargs.pop("serializer")
4108
+ self._deserialize = input_args.pop(0) if input_args else kwargs.pop("deserializer")
4109
+
4110
+ @distributed_trace
4111
+ def list_tenant_credential_types(
4112
+ self, tenant_id: str, **kwargs: Any
4113
+ ) -> List[_models.TenantIntegrationCredentialTypeDto]:
4114
+ """list_tenant_credential_types.
4115
+
4116
+ :param tenant_id: Required.
4117
+ :type tenant_id: str
4118
+ :return: list of TenantIntegrationCredentialTypeDto
4119
+ :rtype: list[~ignos.internal.api.client.models.TenantIntegrationCredentialTypeDto]
4120
+ :raises ~azure.core.exceptions.HttpResponseError:
4121
+ """
4122
+ error_map: MutableMapping[int, Type[HttpResponseError]] = {
4123
+ 401: ClientAuthenticationError,
4124
+ 404: ResourceNotFoundError,
4125
+ 409: ResourceExistsError,
4126
+ 304: ResourceNotModifiedError,
4127
+ }
4128
+ error_map.update(kwargs.pop("error_map", {}) or {})
4129
+
4130
+ _headers = kwargs.pop("headers", {}) or {}
4131
+ _params = kwargs.pop("params", {}) or {}
4132
+
4133
+ cls: ClsType[List[_models.TenantIntegrationCredentialTypeDto]] = kwargs.pop("cls", None)
4134
+
4135
+ _request = build_tenant_credentials_list_tenant_credential_types_request(
4136
+ tenant_id=tenant_id,
4137
+ headers=_headers,
4138
+ params=_params,
4139
+ )
4140
+ _request.url = self._client.format_url(_request.url)
4141
+
4142
+ _stream = False
4143
+ pipeline_response: PipelineResponse = self._client._pipeline.run( # pylint: disable=protected-access
4144
+ _request, stream=_stream, **kwargs
4145
+ )
4146
+
4147
+ response = pipeline_response.http_response
4148
+
4149
+ if response.status_code not in [200]:
4150
+ map_error(status_code=response.status_code, response=response, error_map=error_map)
4151
+ raise HttpResponseError(response=response)
4152
+
4153
+ deserialized = self._deserialize("[TenantIntegrationCredentialTypeDto]", pipeline_response.http_response)
4154
+
4155
+ if cls:
4156
+ return cls(pipeline_response, deserialized, {}) # type: ignore
4157
+
4158
+ return deserialized # type: ignore
4159
+
4160
+ @overload
4161
+ def add_integration_credential_type(
4162
+ self,
4163
+ tenant_id: str,
4164
+ body: Optional[_models.AddIntegrationCredentialTypeRequest] = None,
4165
+ *,
4166
+ content_type: str = "application/json",
4167
+ **kwargs: Any
4168
+ ) -> _models.TenantIntegrationCredentialTypeDto:
4169
+ """add_integration_credential_type.
4170
+
4171
+ :param tenant_id: Required.
4172
+ :type tenant_id: str
4173
+ :param body: Default value is None.
4174
+ :type body: ~ignos.internal.api.client.models.AddIntegrationCredentialTypeRequest
4175
+ :keyword content_type: Body Parameter content-type. Content type parameter for JSON body.
4176
+ Default value is "application/json".
4177
+ :paramtype content_type: str
4178
+ :return: TenantIntegrationCredentialTypeDto
4179
+ :rtype: ~ignos.internal.api.client.models.TenantIntegrationCredentialTypeDto
4180
+ :raises ~azure.core.exceptions.HttpResponseError:
4181
+ """
4182
+
4183
+ @overload
4184
+ def add_integration_credential_type(
4185
+ self, tenant_id: str, body: Optional[IO[bytes]] = None, *, content_type: str = "application/json", **kwargs: Any
4186
+ ) -> _models.TenantIntegrationCredentialTypeDto:
4187
+ """add_integration_credential_type.
4188
+
4189
+ :param tenant_id: Required.
4190
+ :type tenant_id: str
4191
+ :param body: Default value is None.
4192
+ :type body: IO[bytes]
4193
+ :keyword content_type: Body Parameter content-type. Content type parameter for binary body.
4194
+ Known values are: 'application/*+json', 'application/json', 'text/json'. Default value is
4195
+ "application/json".
4196
+ :paramtype content_type: str
4197
+ :return: TenantIntegrationCredentialTypeDto
4198
+ :rtype: ~ignos.internal.api.client.models.TenantIntegrationCredentialTypeDto
4199
+ :raises ~azure.core.exceptions.HttpResponseError:
4200
+ """
4201
+
4202
+ @distributed_trace
4203
+ def add_integration_credential_type(
4204
+ self,
4205
+ tenant_id: str,
4206
+ body: Optional[Union[_models.AddIntegrationCredentialTypeRequest, IO[bytes]]] = None,
4207
+ **kwargs: Any
4208
+ ) -> _models.TenantIntegrationCredentialTypeDto:
4209
+ """add_integration_credential_type.
4210
+
4211
+ :param tenant_id: Required.
4212
+ :type tenant_id: str
4213
+ :param body: Is either a AddIntegrationCredentialTypeRequest type or a IO[bytes] type. Default
4214
+ value is None.
4215
+ :type body: ~ignos.internal.api.client.models.AddIntegrationCredentialTypeRequest or IO[bytes]
4216
+ :return: TenantIntegrationCredentialTypeDto
4217
+ :rtype: ~ignos.internal.api.client.models.TenantIntegrationCredentialTypeDto
4218
+ :raises ~azure.core.exceptions.HttpResponseError:
4219
+ """
4220
+ error_map: MutableMapping[int, Type[HttpResponseError]] = {
4221
+ 401: ClientAuthenticationError,
4222
+ 404: ResourceNotFoundError,
4223
+ 409: ResourceExistsError,
4224
+ 304: ResourceNotModifiedError,
4225
+ }
4226
+ error_map.update(kwargs.pop("error_map", {}) or {})
4227
+
4228
+ _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {})
4229
+ _params = kwargs.pop("params", {}) or {}
4230
+
4231
+ content_type: Optional[str] = kwargs.pop("content_type", _headers.pop("Content-Type", None))
4232
+ cls: ClsType[_models.TenantIntegrationCredentialTypeDto] = kwargs.pop("cls", None)
4233
+
4234
+ content_type = content_type or "application/json"
4235
+ _json = None
4236
+ _content = None
4237
+ if isinstance(body, (IOBase, bytes)):
4238
+ _content = body
4239
+ else:
4240
+ if body is not None:
4241
+ _json = self._serialize.body(body, "AddIntegrationCredentialTypeRequest")
4242
+ else:
4243
+ _json = None
4244
+
4245
+ _request = build_tenant_credentials_add_integration_credential_type_request(
4246
+ tenant_id=tenant_id,
4247
+ content_type=content_type,
4248
+ json=_json,
4249
+ content=_content,
4250
+ headers=_headers,
4251
+ params=_params,
4252
+ )
4253
+ _request.url = self._client.format_url(_request.url)
4254
+
4255
+ _stream = False
4256
+ pipeline_response: PipelineResponse = self._client._pipeline.run( # pylint: disable=protected-access
4257
+ _request, stream=_stream, **kwargs
4258
+ )
4259
+
4260
+ response = pipeline_response.http_response
4261
+
4262
+ if response.status_code not in [200]:
4263
+ map_error(status_code=response.status_code, response=response, error_map=error_map)
4264
+ raise HttpResponseError(response=response)
4265
+
4266
+ deserialized = self._deserialize("TenantIntegrationCredentialTypeDto", pipeline_response.http_response)
4267
+
4268
+ if cls:
4269
+ return cls(pipeline_response, deserialized, {}) # type: ignore
4270
+
4271
+ return deserialized # type: ignore
4272
+
4273
+ @distributed_trace
4274
+ def delete_integration_credential_type( # pylint: disable=inconsistent-return-statements
4275
+ self, tenant_id: str, id: str, **kwargs: Any
4276
+ ) -> None:
4277
+ """delete_integration_credential_type.
4278
+
4279
+ :param tenant_id: Required.
4280
+ :type tenant_id: str
4281
+ :param id: Required.
4282
+ :type id: str
4283
+ :return: None
4284
+ :rtype: None
4285
+ :raises ~azure.core.exceptions.HttpResponseError:
4286
+ """
4287
+ error_map: MutableMapping[int, Type[HttpResponseError]] = {
4288
+ 401: ClientAuthenticationError,
4289
+ 404: ResourceNotFoundError,
4290
+ 409: ResourceExistsError,
4291
+ 304: ResourceNotModifiedError,
4292
+ }
4293
+ error_map.update(kwargs.pop("error_map", {}) or {})
4294
+
4295
+ _headers = kwargs.pop("headers", {}) or {}
4296
+ _params = kwargs.pop("params", {}) or {}
4297
+
4298
+ cls: ClsType[None] = kwargs.pop("cls", None)
4299
+
4300
+ _request = build_tenant_credentials_delete_integration_credential_type_request(
4301
+ tenant_id=tenant_id,
4302
+ id=id,
4303
+ headers=_headers,
4304
+ params=_params,
4305
+ )
4306
+ _request.url = self._client.format_url(_request.url)
4307
+
4308
+ _stream = False
4309
+ pipeline_response: PipelineResponse = self._client._pipeline.run( # pylint: disable=protected-access
4310
+ _request, stream=_stream, **kwargs
4311
+ )
4312
+
4313
+ response = pipeline_response.http_response
4314
+
4315
+ if response.status_code not in [204]:
4100
4316
  map_error(status_code=response.status_code, response=response, error_map=error_map)
4101
4317
  raise HttpResponseError(response=response)
4102
4318
 
@@ -4168,12 +4384,10 @@ class TenantsOperations:
4168
4384
  response = pipeline_response.http_response
4169
4385
 
4170
4386
  if response.status_code not in [200]:
4171
- if _stream:
4172
- response.read() # Load the body in memory and close the socket
4173
4387
  map_error(status_code=response.status_code, response=response, error_map=error_map)
4174
4388
  raise HttpResponseError(response=response)
4175
4389
 
4176
- deserialized = self._deserialize("[TenantDetailDto]", pipeline_response)
4390
+ deserialized = self._deserialize("[TenantDetailDto]", pipeline_response.http_response)
4177
4391
 
4178
4392
  if cls:
4179
4393
  return cls(pipeline_response, deserialized, {}) # type: ignore
@@ -4235,12 +4449,10 @@ class UserOperations:
4235
4449
  response = pipeline_response.http_response
4236
4450
 
4237
4451
  if response.status_code not in [200]:
4238
- if _stream:
4239
- response.read() # Load the body in memory and close the socket
4240
4452
  map_error(status_code=response.status_code, response=response, error_map=error_map)
4241
4453
  raise HttpResponseError(response=response)
4242
4454
 
4243
- deserialized = self._deserialize("UserDetailsDto", pipeline_response)
4455
+ deserialized = self._deserialize("UserDetailsDto", pipeline_response.http_response)
4244
4456
 
4245
4457
  if cls:
4246
4458
  return cls(pipeline_response, deserialized, {}) # type: ignore