compass_api_sdk 0.9.40__py3-none-any.whl → 0.9.42__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of compass_api_sdk might be problematic. Click here for more details.

compass_api_sdk/pendle.py CHANGED
@@ -4,30 +4,33 @@ from .basesdk import BaseSDK
4
4
  from compass_api_sdk import errors, models, utils
5
5
  from compass_api_sdk._hooks import HookContext
6
6
  from compass_api_sdk.types import OptionalNullable, UNSET
7
+ from compass_api_sdk.utils.unmarshal_json_response import unmarshal_json_response
7
8
  from typing import Any, Mapping, Optional, Union
8
9
 
9
10
 
10
11
  class Pendle(BaseSDK):
11
- def position(
12
+ def market(
12
13
  self,
13
14
  *,
14
- chain: models.PendlePositionChain = models.PendlePositionChain.ARBITRUM_MAINNET,
15
- user_address: str = "0xB7954A07213413b2ec6Faa1360f56a498eACe10b",
15
+ chain: models.PendleMarketChain = models.PendleMarketChain.ARBITRUM_MAINNET,
16
16
  market_address: str = "0x46d62a8dede1bf2d0de04f2ed863245cbba5e538",
17
17
  block: OptionalNullable[int] = UNSET,
18
+ user_address: OptionalNullable[str] = UNSET,
18
19
  retries: OptionalNullable[utils.RetryConfig] = UNSET,
19
20
  server_url: Optional[str] = None,
20
21
  timeout_ms: Optional[int] = None,
21
22
  http_headers: Optional[Mapping[str, str]] = None,
22
- ) -> models.PendleGetUserPositionResponse:
23
- r"""Check User's Market Position
23
+ ) -> models.PendleGetMarketResponse:
24
+ r"""Get Market & User Position
24
25
 
25
- Check the SY, PT, YT and Underlying Token positions for a given market.
26
+ Get the market's implied APY, maturity date and the associated token data.
27
+
28
+ The user position is only included if 'user_address' parameter is included.
26
29
 
27
30
  :param chain: The chain to use.
28
- :param user_address: The user address of the desired position.
29
31
  :param market_address: The market address of the desired position.
30
32
  :param block: Optional block number (defaults to latest).
33
+ :param user_address: The user address of the desired market position. Only include if you would like the user position included in the response. Defaults to `None`.
31
34
  :param retries: Override the default retry configuration for this method
32
35
  :param server_url: Override the default server URL for this method
33
36
  :param timeout_ms: Override the default request timeout configuration for this method in milliseconds
@@ -43,16 +46,16 @@ class Pendle(BaseSDK):
43
46
  else:
44
47
  base_url = self._get_url(base_url, url_variables)
45
48
 
46
- request = models.PendlePositionRequest(
49
+ request = models.PendleMarketRequest(
47
50
  chain=chain,
48
51
  block=block,
49
- user_address=user_address,
50
52
  market_address=market_address,
53
+ user_address=user_address,
51
54
  )
52
55
 
53
56
  req = self._build_request(
54
57
  method="GET",
55
- path="/v0/pendle/position",
58
+ path="/v0/pendle/market",
56
59
  base_url=base_url,
57
60
  url_variables=url_variables,
58
61
  request=request,
@@ -78,7 +81,7 @@ class Pendle(BaseSDK):
78
81
  hook_ctx=HookContext(
79
82
  config=self.sdk_configuration,
80
83
  base_url=base_url or "",
81
- operation_id="pendle_position",
84
+ operation_id="pendle_market",
82
85
  oauth2_scopes=[],
83
86
  security_source=self.sdk_configuration.security,
84
87
  ),
@@ -89,11 +92,9 @@ class Pendle(BaseSDK):
89
92
 
90
93
  response_data: Any = None
91
94
  if utils.match_response(http_res, "200", "application/json"):
92
- return utils.unmarshal_json_response(
93
- models.PendleGetUserPositionResponse, http_res
94
- )
95
+ return unmarshal_json_response(models.PendleGetMarketResponse, http_res)
95
96
  if utils.match_response(http_res, "422", "application/json"):
96
- response_data = utils.unmarshal_json_response(
97
+ response_data = unmarshal_json_response(
97
98
  errors.HTTPValidationErrorData, http_res
98
99
  )
99
100
  raise errors.HTTPValidationError(response_data, http_res)
@@ -106,26 +107,28 @@ class Pendle(BaseSDK):
106
107
 
107
108
  raise errors.APIError("Unexpected response received", http_res)
108
109
 
109
- async def position_async(
110
+ async def market_async(
110
111
  self,
111
112
  *,
112
- chain: models.PendlePositionChain = models.PendlePositionChain.ARBITRUM_MAINNET,
113
- user_address: str = "0xB7954A07213413b2ec6Faa1360f56a498eACe10b",
113
+ chain: models.PendleMarketChain = models.PendleMarketChain.ARBITRUM_MAINNET,
114
114
  market_address: str = "0x46d62a8dede1bf2d0de04f2ed863245cbba5e538",
115
115
  block: OptionalNullable[int] = UNSET,
116
+ user_address: OptionalNullable[str] = UNSET,
116
117
  retries: OptionalNullable[utils.RetryConfig] = UNSET,
117
118
  server_url: Optional[str] = None,
118
119
  timeout_ms: Optional[int] = None,
119
120
  http_headers: Optional[Mapping[str, str]] = None,
120
- ) -> models.PendleGetUserPositionResponse:
121
- r"""Check User's Market Position
121
+ ) -> models.PendleGetMarketResponse:
122
+ r"""Get Market & User Position
122
123
 
123
- Check the SY, PT, YT and Underlying Token positions for a given market.
124
+ Get the market's implied APY, maturity date and the associated token data.
125
+
126
+ The user position is only included if 'user_address' parameter is included.
124
127
 
125
128
  :param chain: The chain to use.
126
- :param user_address: The user address of the desired position.
127
129
  :param market_address: The market address of the desired position.
128
130
  :param block: Optional block number (defaults to latest).
131
+ :param user_address: The user address of the desired market position. Only include if you would like the user position included in the response. Defaults to `None`.
129
132
  :param retries: Override the default retry configuration for this method
130
133
  :param server_url: Override the default server URL for this method
131
134
  :param timeout_ms: Override the default request timeout configuration for this method in milliseconds
@@ -141,16 +144,16 @@ class Pendle(BaseSDK):
141
144
  else:
142
145
  base_url = self._get_url(base_url, url_variables)
143
146
 
144
- request = models.PendlePositionRequest(
147
+ request = models.PendleMarketRequest(
145
148
  chain=chain,
146
149
  block=block,
147
- user_address=user_address,
148
150
  market_address=market_address,
151
+ user_address=user_address,
149
152
  )
150
153
 
151
154
  req = self._build_request_async(
152
155
  method="GET",
153
- path="/v0/pendle/position",
156
+ path="/v0/pendle/market",
154
157
  base_url=base_url,
155
158
  url_variables=url_variables,
156
159
  request=request,
@@ -176,7 +179,7 @@ class Pendle(BaseSDK):
176
179
  hook_ctx=HookContext(
177
180
  config=self.sdk_configuration,
178
181
  base_url=base_url or "",
179
- operation_id="pendle_position",
182
+ operation_id="pendle_market",
180
183
  oauth2_scopes=[],
181
184
  security_source=self.sdk_configuration.security,
182
185
  ),
@@ -187,11 +190,9 @@ class Pendle(BaseSDK):
187
190
 
188
191
  response_data: Any = None
189
192
  if utils.match_response(http_res, "200", "application/json"):
190
- return utils.unmarshal_json_response(
191
- models.PendleGetUserPositionResponse, http_res
192
- )
193
+ return unmarshal_json_response(models.PendleGetMarketResponse, http_res)
193
194
  if utils.match_response(http_res, "422", "application/json"):
194
- response_data = utils.unmarshal_json_response(
195
+ response_data = unmarshal_json_response(
195
196
  errors.HTTPValidationErrorData, http_res
196
197
  )
197
198
  raise errors.HTTPValidationError(response_data, http_res)
@@ -279,11 +280,11 @@ class Pendle(BaseSDK):
279
280
 
280
281
  response_data: Any = None
281
282
  if utils.match_response(http_res, "200", "application/json"):
282
- return utils.unmarshal_json_response(
283
+ return unmarshal_json_response(
283
284
  models.PendleListUserPositionsResponse, http_res
284
285
  )
285
286
  if utils.match_response(http_res, "422", "application/json"):
286
- response_data = utils.unmarshal_json_response(
287
+ response_data = unmarshal_json_response(
287
288
  errors.HTTPValidationErrorData, http_res
288
289
  )
289
290
  raise errors.HTTPValidationError(response_data, http_res)
@@ -371,201 +372,11 @@ class Pendle(BaseSDK):
371
372
 
372
373
  response_data: Any = None
373
374
  if utils.match_response(http_res, "200", "application/json"):
374
- return utils.unmarshal_json_response(
375
+ return unmarshal_json_response(
375
376
  models.PendleListUserPositionsResponse, http_res
376
377
  )
377
378
  if utils.match_response(http_res, "422", "application/json"):
378
- response_data = utils.unmarshal_json_response(
379
- errors.HTTPValidationErrorData, http_res
380
- )
381
- raise errors.HTTPValidationError(response_data, http_res)
382
- if utils.match_response(http_res, "4XX", "*"):
383
- http_res_text = await utils.stream_to_text_async(http_res)
384
- raise errors.APIError("API error occurred", http_res, http_res_text)
385
- if utils.match_response(http_res, "5XX", "*"):
386
- http_res_text = await utils.stream_to_text_async(http_res)
387
- raise errors.APIError("API error occurred", http_res, http_res_text)
388
-
389
- raise errors.APIError("Unexpected response received", http_res)
390
-
391
- def market(
392
- self,
393
- *,
394
- chain: models.PendleMarketChain = models.PendleMarketChain.ARBITRUM_MAINNET,
395
- market_address: str = "0x46d62a8dede1bf2d0de04f2ed863245cbba5e538",
396
- block: OptionalNullable[int] = UNSET,
397
- retries: OptionalNullable[utils.RetryConfig] = UNSET,
398
- server_url: Optional[str] = None,
399
- timeout_ms: Optional[int] = None,
400
- http_headers: Optional[Mapping[str, str]] = None,
401
- ) -> models.PendleGetMarketResponse:
402
- r"""Get Market Data
403
-
404
- Get the market's implied APY, maturity date and the associated token data.
405
-
406
- :param chain: The chain to use.
407
- :param market_address: The market address of the desired position.
408
- :param block: Optional block number (defaults to latest).
409
- :param retries: Override the default retry configuration for this method
410
- :param server_url: Override the default server URL for this method
411
- :param timeout_ms: Override the default request timeout configuration for this method in milliseconds
412
- :param http_headers: Additional headers to set or replace on requests.
413
- """
414
- base_url = None
415
- url_variables = None
416
- if timeout_ms is None:
417
- timeout_ms = self.sdk_configuration.timeout_ms
418
-
419
- if server_url is not None:
420
- base_url = server_url
421
- else:
422
- base_url = self._get_url(base_url, url_variables)
423
-
424
- request = models.PendleMarketRequest(
425
- chain=chain,
426
- block=block,
427
- market_address=market_address,
428
- )
429
-
430
- req = self._build_request(
431
- method="GET",
432
- path="/v0/pendle/market",
433
- base_url=base_url,
434
- url_variables=url_variables,
435
- request=request,
436
- request_body_required=False,
437
- request_has_path_params=False,
438
- request_has_query_params=True,
439
- user_agent_header="user-agent",
440
- accept_header_value="application/json",
441
- http_headers=http_headers,
442
- security=self.sdk_configuration.security,
443
- timeout_ms=timeout_ms,
444
- )
445
-
446
- if retries == UNSET:
447
- if self.sdk_configuration.retry_config is not UNSET:
448
- retries = self.sdk_configuration.retry_config
449
-
450
- retry_config = None
451
- if isinstance(retries, utils.RetryConfig):
452
- retry_config = (retries, ["429", "500", "502", "503", "504"])
453
-
454
- http_res = self.do_request(
455
- hook_ctx=HookContext(
456
- config=self.sdk_configuration,
457
- base_url=base_url or "",
458
- operation_id="pendle_market",
459
- oauth2_scopes=[],
460
- security_source=self.sdk_configuration.security,
461
- ),
462
- request=req,
463
- error_status_codes=["422", "4XX", "5XX"],
464
- retry_config=retry_config,
465
- )
466
-
467
- response_data: Any = None
468
- if utils.match_response(http_res, "200", "application/json"):
469
- return utils.unmarshal_json_response(
470
- models.PendleGetMarketResponse, http_res
471
- )
472
- if utils.match_response(http_res, "422", "application/json"):
473
- response_data = utils.unmarshal_json_response(
474
- errors.HTTPValidationErrorData, http_res
475
- )
476
- raise errors.HTTPValidationError(response_data, http_res)
477
- if utils.match_response(http_res, "4XX", "*"):
478
- http_res_text = utils.stream_to_text(http_res)
479
- raise errors.APIError("API error occurred", http_res, http_res_text)
480
- if utils.match_response(http_res, "5XX", "*"):
481
- http_res_text = utils.stream_to_text(http_res)
482
- raise errors.APIError("API error occurred", http_res, http_res_text)
483
-
484
- raise errors.APIError("Unexpected response received", http_res)
485
-
486
- async def market_async(
487
- self,
488
- *,
489
- chain: models.PendleMarketChain = models.PendleMarketChain.ARBITRUM_MAINNET,
490
- market_address: str = "0x46d62a8dede1bf2d0de04f2ed863245cbba5e538",
491
- block: OptionalNullable[int] = UNSET,
492
- retries: OptionalNullable[utils.RetryConfig] = UNSET,
493
- server_url: Optional[str] = None,
494
- timeout_ms: Optional[int] = None,
495
- http_headers: Optional[Mapping[str, str]] = None,
496
- ) -> models.PendleGetMarketResponse:
497
- r"""Get Market Data
498
-
499
- Get the market's implied APY, maturity date and the associated token data.
500
-
501
- :param chain: The chain to use.
502
- :param market_address: The market address of the desired position.
503
- :param block: Optional block number (defaults to latest).
504
- :param retries: Override the default retry configuration for this method
505
- :param server_url: Override the default server URL for this method
506
- :param timeout_ms: Override the default request timeout configuration for this method in milliseconds
507
- :param http_headers: Additional headers to set or replace on requests.
508
- """
509
- base_url = None
510
- url_variables = None
511
- if timeout_ms is None:
512
- timeout_ms = self.sdk_configuration.timeout_ms
513
-
514
- if server_url is not None:
515
- base_url = server_url
516
- else:
517
- base_url = self._get_url(base_url, url_variables)
518
-
519
- request = models.PendleMarketRequest(
520
- chain=chain,
521
- block=block,
522
- market_address=market_address,
523
- )
524
-
525
- req = self._build_request_async(
526
- method="GET",
527
- path="/v0/pendle/market",
528
- base_url=base_url,
529
- url_variables=url_variables,
530
- request=request,
531
- request_body_required=False,
532
- request_has_path_params=False,
533
- request_has_query_params=True,
534
- user_agent_header="user-agent",
535
- accept_header_value="application/json",
536
- http_headers=http_headers,
537
- security=self.sdk_configuration.security,
538
- timeout_ms=timeout_ms,
539
- )
540
-
541
- if retries == UNSET:
542
- if self.sdk_configuration.retry_config is not UNSET:
543
- retries = self.sdk_configuration.retry_config
544
-
545
- retry_config = None
546
- if isinstance(retries, utils.RetryConfig):
547
- retry_config = (retries, ["429", "500", "502", "503", "504"])
548
-
549
- http_res = await self.do_request_async(
550
- hook_ctx=HookContext(
551
- config=self.sdk_configuration,
552
- base_url=base_url or "",
553
- operation_id="pendle_market",
554
- oauth2_scopes=[],
555
- security_source=self.sdk_configuration.security,
556
- ),
557
- request=req,
558
- error_status_codes=["422", "4XX", "5XX"],
559
- retry_config=retry_config,
560
- )
561
-
562
- response_data: Any = None
563
- if utils.match_response(http_res, "200", "application/json"):
564
- return utils.unmarshal_json_response(
565
- models.PendleGetMarketResponse, http_res
566
- )
567
- if utils.match_response(http_res, "422", "application/json"):
568
- response_data = utils.unmarshal_json_response(
379
+ response_data = unmarshal_json_response(
569
380
  errors.HTTPValidationErrorData, http_res
570
381
  )
571
382
  raise errors.HTTPValidationError(response_data, http_res)
@@ -650,11 +461,9 @@ class Pendle(BaseSDK):
650
461
 
651
462
  response_data: Any = None
652
463
  if utils.match_response(http_res, "200", "application/json"):
653
- return utils.unmarshal_json_response(
654
- models.PendleListMarketsResponse, http_res
655
- )
464
+ return unmarshal_json_response(models.PendleListMarketsResponse, http_res)
656
465
  if utils.match_response(http_res, "422", "application/json"):
657
- response_data = utils.unmarshal_json_response(
466
+ response_data = unmarshal_json_response(
658
467
  errors.HTTPValidationErrorData, http_res
659
468
  )
660
469
  raise errors.HTTPValidationError(response_data, http_res)
@@ -739,11 +548,9 @@ class Pendle(BaseSDK):
739
548
 
740
549
  response_data: Any = None
741
550
  if utils.match_response(http_res, "200", "application/json"):
742
- return utils.unmarshal_json_response(
743
- models.PendleListMarketsResponse, http_res
744
- )
551
+ return unmarshal_json_response(models.PendleListMarketsResponse, http_res)
745
552
  if utils.match_response(http_res, "422", "application/json"):
746
- response_data = utils.unmarshal_json_response(
553
+ response_data = unmarshal_json_response(
747
554
  errors.HTTPValidationErrorData, http_res
748
555
  )
749
556
  raise errors.HTTPValidationError(response_data, http_res)
@@ -848,11 +655,9 @@ class Pendle(BaseSDK):
848
655
 
849
656
  response_data: Any = None
850
657
  if utils.match_response(http_res, "200", "application/json"):
851
- return utils.unmarshal_json_response(
852
- models.PendleGetQuoteResponse, http_res
853
- )
658
+ return unmarshal_json_response(models.PendleGetQuoteResponse, http_res)
854
659
  if utils.match_response(http_res, "422", "application/json"):
855
- response_data = utils.unmarshal_json_response(
660
+ response_data = unmarshal_json_response(
856
661
  errors.HTTPValidationErrorData, http_res
857
662
  )
858
663
  raise errors.HTTPValidationError(response_data, http_res)
@@ -957,11 +762,9 @@ class Pendle(BaseSDK):
957
762
 
958
763
  response_data: Any = None
959
764
  if utils.match_response(http_res, "200", "application/json"):
960
- return utils.unmarshal_json_response(
961
- models.PendleGetQuoteResponse, http_res
962
- )
765
+ return unmarshal_json_response(models.PendleGetQuoteResponse, http_res)
963
766
  if utils.match_response(http_res, "422", "application/json"):
964
- response_data = utils.unmarshal_json_response(
767
+ response_data = unmarshal_json_response(
965
768
  errors.HTTPValidationErrorData, http_res
966
769
  )
967
770
  raise errors.HTTPValidationError(response_data, http_res)
@@ -1063,9 +866,9 @@ class Pendle(BaseSDK):
1063
866
 
1064
867
  response_data: Any = None
1065
868
  if utils.match_response(http_res, "200", "application/json"):
1066
- return utils.unmarshal_json_response(models.TxResponse, http_res)
869
+ return unmarshal_json_response(models.TxResponse, http_res)
1067
870
  if utils.match_response(http_res, "422", "application/json"):
1068
- response_data = utils.unmarshal_json_response(
871
+ response_data = unmarshal_json_response(
1069
872
  errors.HTTPValidationErrorData, http_res
1070
873
  )
1071
874
  raise errors.HTTPValidationError(response_data, http_res)
@@ -1167,9 +970,9 @@ class Pendle(BaseSDK):
1167
970
 
1168
971
  response_data: Any = None
1169
972
  if utils.match_response(http_res, "200", "application/json"):
1170
- return utils.unmarshal_json_response(models.TxResponse, http_res)
973
+ return unmarshal_json_response(models.TxResponse, http_res)
1171
974
  if utils.match_response(http_res, "422", "application/json"):
1172
- response_data = utils.unmarshal_json_response(
975
+ response_data = unmarshal_json_response(
1173
976
  errors.HTTPValidationErrorData, http_res
1174
977
  )
1175
978
  raise errors.HTTPValidationError(response_data, http_res)
@@ -1271,9 +1074,9 @@ class Pendle(BaseSDK):
1271
1074
 
1272
1075
  response_data: Any = None
1273
1076
  if utils.match_response(http_res, "200", "application/json"):
1274
- return utils.unmarshal_json_response(models.TxResponse, http_res)
1077
+ return unmarshal_json_response(models.TxResponse, http_res)
1275
1078
  if utils.match_response(http_res, "422", "application/json"):
1276
- response_data = utils.unmarshal_json_response(
1079
+ response_data = unmarshal_json_response(
1277
1080
  errors.HTTPValidationErrorData, http_res
1278
1081
  )
1279
1082
  raise errors.HTTPValidationError(response_data, http_res)
@@ -1375,9 +1178,9 @@ class Pendle(BaseSDK):
1375
1178
 
1376
1179
  response_data: Any = None
1377
1180
  if utils.match_response(http_res, "200", "application/json"):
1378
- return utils.unmarshal_json_response(models.TxResponse, http_res)
1181
+ return unmarshal_json_response(models.TxResponse, http_res)
1379
1182
  if utils.match_response(http_res, "422", "application/json"):
1380
- response_data = utils.unmarshal_json_response(
1183
+ response_data = unmarshal_json_response(
1381
1184
  errors.HTTPValidationErrorData, http_res
1382
1185
  )
1383
1186
  raise errors.HTTPValidationError(response_data, http_res)
@@ -1479,9 +1282,9 @@ class Pendle(BaseSDK):
1479
1282
 
1480
1283
  response_data: Any = None
1481
1284
  if utils.match_response(http_res, "200", "application/json"):
1482
- return utils.unmarshal_json_response(models.TxResponse, http_res)
1285
+ return unmarshal_json_response(models.TxResponse, http_res)
1483
1286
  if utils.match_response(http_res, "422", "application/json"):
1484
- response_data = utils.unmarshal_json_response(
1287
+ response_data = unmarshal_json_response(
1485
1288
  errors.HTTPValidationErrorData, http_res
1486
1289
  )
1487
1290
  raise errors.HTTPValidationError(response_data, http_res)
@@ -1583,9 +1386,9 @@ class Pendle(BaseSDK):
1583
1386
 
1584
1387
  response_data: Any = None
1585
1388
  if utils.match_response(http_res, "200", "application/json"):
1586
- return utils.unmarshal_json_response(models.TxResponse, http_res)
1389
+ return unmarshal_json_response(models.TxResponse, http_res)
1587
1390
  if utils.match_response(http_res, "422", "application/json"):
1588
- response_data = utils.unmarshal_json_response(
1391
+ response_data = unmarshal_json_response(
1589
1392
  errors.HTTPValidationErrorData, http_res
1590
1393
  )
1591
1394
  raise errors.HTTPValidationError(response_data, http_res)
@@ -1687,9 +1490,9 @@ class Pendle(BaseSDK):
1687
1490
 
1688
1491
  response_data: Any = None
1689
1492
  if utils.match_response(http_res, "200", "application/json"):
1690
- return utils.unmarshal_json_response(models.TxResponse, http_res)
1493
+ return unmarshal_json_response(models.TxResponse, http_res)
1691
1494
  if utils.match_response(http_res, "422", "application/json"):
1692
- response_data = utils.unmarshal_json_response(
1495
+ response_data = unmarshal_json_response(
1693
1496
  errors.HTTPValidationErrorData, http_res
1694
1497
  )
1695
1498
  raise errors.HTTPValidationError(response_data, http_res)
@@ -1791,9 +1594,9 @@ class Pendle(BaseSDK):
1791
1594
 
1792
1595
  response_data: Any = None
1793
1596
  if utils.match_response(http_res, "200", "application/json"):
1794
- return utils.unmarshal_json_response(models.TxResponse, http_res)
1597
+ return unmarshal_json_response(models.TxResponse, http_res)
1795
1598
  if utils.match_response(http_res, "422", "application/json"):
1796
- response_data = utils.unmarshal_json_response(
1599
+ response_data = unmarshal_json_response(
1797
1600
  errors.HTTPValidationErrorData, http_res
1798
1601
  )
1799
1602
  raise errors.HTTPValidationError(response_data, http_res)
@@ -1887,9 +1690,9 @@ class Pendle(BaseSDK):
1887
1690
 
1888
1691
  response_data: Any = None
1889
1692
  if utils.match_response(http_res, "200", "application/json"):
1890
- return utils.unmarshal_json_response(models.TxResponse, http_res)
1693
+ return unmarshal_json_response(models.TxResponse, http_res)
1891
1694
  if utils.match_response(http_res, "422", "application/json"):
1892
- response_data = utils.unmarshal_json_response(
1695
+ response_data = unmarshal_json_response(
1893
1696
  errors.HTTPValidationErrorData, http_res
1894
1697
  )
1895
1698
  raise errors.HTTPValidationError(response_data, http_res)
@@ -1983,9 +1786,9 @@ class Pendle(BaseSDK):
1983
1786
 
1984
1787
  response_data: Any = None
1985
1788
  if utils.match_response(http_res, "200", "application/json"):
1986
- return utils.unmarshal_json_response(models.TxResponse, http_res)
1789
+ return unmarshal_json_response(models.TxResponse, http_res)
1987
1790
  if utils.match_response(http_res, "422", "application/json"):
1988
- response_data = utils.unmarshal_json_response(
1791
+ response_data = unmarshal_json_response(
1989
1792
  errors.HTTPValidationErrorData, http_res
1990
1793
  )
1991
1794
  raise errors.HTTPValidationError(response_data, http_res)
@@ -2091,9 +1894,9 @@ class Pendle(BaseSDK):
2091
1894
 
2092
1895
  response_data: Any = None
2093
1896
  if utils.match_response(http_res, "200", "application/json"):
2094
- return utils.unmarshal_json_response(models.TxResponse, http_res)
1897
+ return unmarshal_json_response(models.TxResponse, http_res)
2095
1898
  if utils.match_response(http_res, "422", "application/json"):
2096
- response_data = utils.unmarshal_json_response(
1899
+ response_data = unmarshal_json_response(
2097
1900
  errors.HTTPValidationErrorData, http_res
2098
1901
  )
2099
1902
  raise errors.HTTPValidationError(response_data, http_res)
@@ -2199,9 +2002,9 @@ class Pendle(BaseSDK):
2199
2002
 
2200
2003
  response_data: Any = None
2201
2004
  if utils.match_response(http_res, "200", "application/json"):
2202
- return utils.unmarshal_json_response(models.TxResponse, http_res)
2005
+ return unmarshal_json_response(models.TxResponse, http_res)
2203
2006
  if utils.match_response(http_res, "422", "application/json"):
2204
- response_data = utils.unmarshal_json_response(
2007
+ response_data = unmarshal_json_response(
2205
2008
  errors.HTTPValidationErrorData, http_res
2206
2009
  )
2207
2010
  raise errors.HTTPValidationError(response_data, http_res)
@@ -2308,9 +2111,9 @@ class Pendle(BaseSDK):
2308
2111
 
2309
2112
  response_data: Any = None
2310
2113
  if utils.match_response(http_res, "200", "application/json"):
2311
- return utils.unmarshal_json_response(models.TxResponse, http_res)
2114
+ return unmarshal_json_response(models.TxResponse, http_res)
2312
2115
  if utils.match_response(http_res, "422", "application/json"):
2313
- response_data = utils.unmarshal_json_response(
2116
+ response_data = unmarshal_json_response(
2314
2117
  errors.HTTPValidationErrorData, http_res
2315
2118
  )
2316
2119
  raise errors.HTTPValidationError(response_data, http_res)
@@ -2417,9 +2220,9 @@ class Pendle(BaseSDK):
2417
2220
 
2418
2221
  response_data: Any = None
2419
2222
  if utils.match_response(http_res, "200", "application/json"):
2420
- return utils.unmarshal_json_response(models.TxResponse, http_res)
2223
+ return unmarshal_json_response(models.TxResponse, http_res)
2421
2224
  if utils.match_response(http_res, "422", "application/json"):
2422
- response_data = utils.unmarshal_json_response(
2225
+ response_data = unmarshal_json_response(
2423
2226
  errors.HTTPValidationErrorData, http_res
2424
2227
  )
2425
2228
  raise errors.HTTPValidationError(response_data, http_res)