CLI reference
The commands below use the CLI built in a Lookalyke source checkout. Start the server in one terminal, then run commands from a second terminal in the same checkout.
Inspect a running server
Section titled “Inspect a running server”node packages/server/dist/cli.js statusnode packages/server/dist/cli.js appsnode packages/server/dist/cli.js env stripenode packages/server/dist/cli.js activity --limit 20 --app stripeUse --json on commands that print data when a script needs to parse the result. For example, keys --json prints the current sandbox credentials. Keep keys out of shared logs and CI output.
Trigger a scenario
Section titled “Trigger a scenario”node packages/server/dist/cli.js trigger stripenode packages/server/dist/cli.js trigger stripe payment.succeedednode packages/server/dist/cli.js break stripe slow 3snode packages/server/dist/cli.js break stripe normaltrigger stripe lists available Stripe triggers. For a specific invoice, pass --invoice with its ID. Use a seeded sandbox or make an open invoice before triggering a Stripe payment.
Common flags
Section titled “Common flags”| Flag | Applies when | Behavior |
|---|---|---|
--port 4101 |
Starting a server | Listen on that port. Use 0 to choose a free port. |
--memory |
Starting a server | Keep data in memory for this run. |
--demo |
Starting a server | Load sample data and demo Activity. |
--apps stripe,resend |
Starting a server | Enable just those apps in the main sandbox. |
--url http://127.0.0.1:4101 |
Talking to a running server | Target an instance other than the default at port 4100. |
--sandbox feature-x |
Talking to a running server | Use the named sandbox. |
For all options, run node packages/server/dist/cli.js help or see the full running guide.