Binance::Responses::ServerResponse
Inherits JSON::Serializable < Reference < Object
The ServerResponse class is the base class returned for all endpoint calls
- If the endpoint call was successfully executed and parsed, then the success property will be true. Otherwise it will be false and error property will contain the error message.
- If the endpoint itself is returning an error, the error_code will also be populated.
- If an exception occurred (for example timeout error), then it's message is captured to the error property and the exception itself is captured to the exception property. In all cases, the raw response from the endpoint is captured to the response property.
Constructors
new(pull : JSON::PullParser)
Sourcenew(*, __pull_for_json_serializable pull : JSON::PullParser)
SourceClass methods
consume_body(response)
SourceInstance methods
consume_body(response)
SourceThe error message from either the API endpoint or Exception captured (if any).
The full HTTP Response object captured (if any).
used_weight
Source