MCPcopy Create free account
hub / github.com/omkarcloud/botasaurus / serialize

Function serialize

botasaurus_server/botasaurus_server/validation.py:5–10  ·  view source on GitHub ↗
(data)

Source from the content-addressed store, hash-verified

3
4
5def serialize(data):
6 if data is None:
7 return None
8 if isinstance(data, list):
9 return [item.to_json() for item in data]
10 return data.to_json()
11
12def create_task_not_found_error(task_id):
13 return JsonHTTPResponse(

Callers 4

perform_create_all_taskFunction · 0.70
perform_create_tasksFunction · 0.70
get_task_from_dbFunction · 0.70
refetch_tasksFunction · 0.70

Calls 1

to_jsonMethod · 0.45

Tested by

no test coverage detected