question

Upvotes
Accepted
582 9 15 23

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
eikoneikon-app-studiojet
icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

1 Answer

· Write an Answer
Upvotes
Accepted
582 9 15 23

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();

icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Just a thought: do you really need all fields ? The more fields you subscribe to, the heavier the load on the app and machine running it.

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.