Procedures: CLI `call` interface
Design and implement a way to call procedures and await their results from the SpacetimeDB CLI. Note that procedures live at a different HTTP route than reducers (/database/:name/procedure/:name vs /database/:name/call/:name), at least for now. As such, we'll have to decide between:
spacetime calldoes some extra work internally to determine whether it's calling a reducer or a procedure, but hides the difference from the user.- There's a separate subcommand, possibly
spacetime procedure, which calls procedures. Attempting tospacetime calla procedure is an error.
We like the former version, where the same call CLI command can do either. We intend to modify the /v1/database/:name/call/:func route to call either reducers or procedures, at which point this should require only very minimal modifications to the CLI.
another proposal i thought of is adding the commands:
spacetime reducer db name
spacetime procedure db name
Then the call is gone and its not ambigous (call would get marked deprecated and removed in 2.0 in that version) :)
Idk lemme know what you think :>