Handle response objects and JSON serialization
mainThe client returns response objects that can be used directly or serialized to JSON. Use the .to_json() method on the response object to get a JSON string representation of the result.
# Example of using the response object
print(response)
# Example of converting the response to a JSON string
print(response.to_json())