How do I view scandies CRM rates from the shell?
Table of Contents
Reproduce, from the command line, the scandies slice of what the
removed desktop client's cross-rates matrix window showed, via the crm_commands shell
command. The ores-shell block below is tangled into the runnable
script library as crm_rates_scandies.ores.
1. Question
How do I view the scandies CRM rates from ores.shell?
2. Answer
The crm rates command
(projects/ores.shell/src/app/commands/crm_commands.cpp) sends the
same get_crm_rates_request (subject marketdata.v1.crm.rates) the
desktop client's matrix window sent and formatted through the same
crm_rate_formatter. Runs in the logged-in account's own default
party by default; expects the services up (compass services
start) and a tenant/party provisioned (e.g. via the Acme Corporation
provisioning recipe, which also seeds this party's scandies CRM
from refdata.crm_topology_bundles).
crm rates scandies logout
./ores.shell ${log_args} ${connect_args} ${login_args} << 'EOF'
<<crm-rates-scandies>>
EOF
3. Script
projects/ores.shell/scripts/library/marketdata/crm_rates_scandies.ores
– generated from this recipe's ores-shell block by compass build
--direct tangle_shell_scripts (do not edit the .ores by hand).
4. Tested by
Manual: run against a Acme-provisioned database (compass db
recreate -y -k then the Acme Corporation provisioning recipe), then
compass shell -u tenant_admin@acme_corporation -p Secure-Password-123 -f
crm_rates_scandies.ores. Prints a table (CRM, Pair, Rate, Change,
Status, As Of) scoped to the scandies CRM; rows show
unavailable until the marketdata feed has ticked at least once for
that party.