Hey, samsogade, could you please add some details about what you are trying to achieve and what you mean when asking "How do we define...?" With more information, someone will be able to help
Continuing with my example above. Let's say I want to list the files in my current directory:
q)key':.
KDB Insights introduces object storage that allows us to e.g. list files in an S3 bucket:
q)key''$":s3://kxinsights-marketplace-data/"
'''s#'_inventory'db'par.txt'sym'symlinks
The functionality to interact with S3 is not part of vanilla Q. It's provided by KDB Insights - in particular the shared object libobjstor.so shipped with KDB Insights.
My question is how do we create such custom protocols using the C API? As a contrived example, perhaps I wanted to list all open positions in my IBKR trading account:
q)key'$":ibkr://account1/"
Of course, I could create a regular function to do this, but let's assume I really, really like this new syntax.