Skip to content


This module provides APIs relating to streaming analytics. For full documentation with examples, please see the Streaming Analytics documentation.

As of KX Control version 4.2.1, the streamingapi.q can be loaded into standalone processes. On startup, it will check which mode is running and create stub functions accordingly.

Publish data to a stream.


Name Type Description
uID long Stream ID
data table Data


 data:([] time:.z.p; sym:`$"EUR/USD"; price:3?10.0; src:3?`4);[10j; data];


Register unsubscription and snapshot functions for a streaming analytic name.


Name Type Description
subF symbol Sub function
unsubF symbol Unsub function
snapF symbol Snapshot function


 .fx.unsub:{ delete from `.fx.subs where id=x };
 .fx.snapshot:{ select from .fx.cache where id=x };
 .sa.registerfuncs[`; `.fx.unsub; `.fx.snapshot];