'.z.ws undefined
[0] show r
q).hbc.h
0Niq).ws.w
h| hostname callback
-| -----------------------
| api.hitbtc.com .hbc.updSo there was a bug in my ws.q library – I didn’t realise that kdb+ already adds a number of WebSocket-related headers to requests to ws:// or wss:// URLs; my library added some of these headers as well, which caused problems on some hosts (I guess any I’d tried before just ignored duplicated headers)
I have updated the library so that it now works with the hitbtc example:
q).hbc.upd:{show .j.k x};
q).hbc.h:.ws.open["wss://api.hitbtc.com/api/2/ws";`.hbc.upd]
q).hbc.h .j.j `method`params`id!(`getCurrency;(1#`currency)!1#`ETH;123)
q)jsonrpc| "2.0"
result | `id`fullName`crypto`payinEnabled`payinPaymentId`payinConfirmations`payoutEnabled`payoutIsPaymentId`transferEnabled`delisted`payoutFee!("ETH";"Ethereum";1b;1b;0b;2f;1b;0b;1b;0b;"0.00958")
id | 123f
GitHub issue: https://github.com/jonathonmcmurray/ws.q/issues/1
--
You received this message because you are subscribed to the Google Groups "Kdb+ Personal Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to
personal-kdbpl...@googlegroups.com.
To post to this group, send email to
personal...@googlegroups.com.
Visit this group at https://groups.google.com/group/personal-kdbplus.
For more options, visit https://groups.google.com/d/optout.