MCPcopy Create free account
hub / github.com/21st-dev/21st-sdk / _to_api_object

Function _to_api_object

packages/python-sdk/src/twentyfirst_sdk/client.py:14–19  ·  view source on GitHub ↗
(value: Any)

Source from the content-addressed store, hash-verified

12
13
14def _to_api_object(value: Any) -> Any:
15 if isinstance(value, dict):
16 return APIObject({key: _to_api_object(item) for key, item in value.items()})
17 if isinstance(value, list):
18 return [_to_api_object(item) for item in value]
19 return value
20
21
22class AgentClientError(Exception):

Callers 1

_fetchMethod · 0.85

Calls 1

APIObjectClass · 0.85

Tested by

no test coverage detected