JET Quote subscribe to all available fields

Does anyone know if it's possible to make a Quote subscription via JET api (without having to provide a Field) for all available fields?

This is the code to subscribe:


var quote = JET.Quotes.create()
.rics("GOOG.O")
.onUpdate(function (subscription, ric, updatedValues) {
var allFieldsValues = subscription.getFieldsValues(ric);
})
.start();


This is the ERROR:

Uncaught Chain or a RICs and at least one field should be specified to start a subscription
Quote.js: 435

Does JET Quote plugin always require the field list (at least one field)?

I understand you can specify the fields in the request (but I want to get back the full list of fields)

.rawFields("CF_BID")

or


.formattedFields("PCTCHNG")



Thanks

Best Answer

  • I found the answer:

    You can use “*” as a parameter in rawFields() or formattedFields() in Quotes plug-in object.

    var quote = JET.Quotes.create()

    .rics("GOOG.O")

    .rawFields("*")

    .onUpdate(function (subscription, ric, updatedValues) {

    console.log(subscription.getFieldsValues(ric));
    })

    .start();

Answers