(consensusRatings())
- get - Get Consensus Ratings
Get Consensus Ratings for a given symbol
package hello.world;
import com.benzinga.bzclient.Bzclient;
import com.benzinga.bzclient.models.operations.GetConsensusRatingsV1Request;
import com.benzinga.bzclient.models.operations.GetConsensusRatingsV1Response;
import java.lang.Exception;
public class Application {
public static void main(String[] args) throws Exception {
Bzclient sdk = Bzclient.builder()
.apiKeyAuth("<YOUR_API_KEY_HERE>")
.build();
GetConsensusRatingsV1Request req = GetConsensusRatingsV1Request.builder()
.build();
GetConsensusRatingsV1Response res = sdk.consensusRatings().get()
.request(req)
.call();
if (res.apiConsensusRating().isPresent()) {
// handle response
}
}
}
Parameter | Type | Required | Description |
---|---|---|---|
request |
GetConsensusRatingsV1Request | ✔️ | The request object to use for the request. |
Error Type | Status Code | Content Type |
---|---|---|
models/errors/APIException | 4XX, 5XX | */* |