Skip to main content

RequestWidgetSentiments

Request for the "Crowd Sentiment" indicator for the widget

Request format

{
"CollectSuffixes": true,
"Book" : "BBook",
"Symbols" : ["EURUSD", "GBPUSD"],
"RequestId": "c1549b18-3ccb-4500-a928-7ff27e8d1fe9",
"Nodes": [
Node1
],
"RequestName": "RequestWidgetSentiments"
}

Request parameters:

NameDescription
RequestIdUnique request GUID
CollectSuffixestrue - aggregate all suffix symbols into one symbol, otherwise display separate statistics for them, including their contracts
BookEnumeration NoBook, ABook, BBook
SymbolsFilter - a list of calculated instruments
NodesList of nodes that participate in the request. If the list is empty, then all available nodes are called.
RequestNameRequest type

The following structure is returned in the list:

public class WidgetSentimentSymbol 
{
public string Symbol { get; set; }
public DateTime Time { get; set; }
public decimal Bid { get; set; }
public decimal Ask { get; set; }
public int Digits { get; set; }
public decimal Spread { get; set; }
public decimal MinSpread { get; set; }
public int Buyers { get; set; }
public int Sellers { get; set; }
public decimal VolumeBuyInUsd { get; set; }
public decimal VolumeSellInUsd { get; set; }
}

Response ResponseSentiments

 {
"Result": [{
"Symbol": "EURUSD",
"Time": "2020-12-30 16:12:16:133",
"Bid": 1.22856,
"Ask": 1.2287,
"Digits": 5,
"Spread": 1.4,
"MinSpread": 1.4,
"Buyers": 2187,
"Sellers": 1700,
"VolumeBuyInUsd": 410152896.85,
"VolumeSellInUsd": 552228483.79
}, {
"Symbol": "GBPUSD",
"Time": "2020-12-30 16:12:14:760",
"Bid": 1.35928,
"Ask": 1.35958,
"Digits": 5,
"Spread": 3.0,
"MinSpread": 2.3,
"Buyers": 653,
"Sellers": 691,
"VolumeBuyInUsd": 58702171.66,
"VolumeSellInUsd": 187611065.02
}],
"RequestId": "c1549b18-3ccb-4500-a928-7ff27e8d1fe9",
"Errors": [
{
"Node": "Node3",
"Platform": "Mt4",
"Result": "Error message",
"ResponseNode": "ResponseNodeError"
}],
"ResponseMaster": "ResponseWidgetSentiments"
}

Errors is either an empty list or a list of responses of the ResponseNodeError nodes