Skip to content
Dispatch Dispatch Dispatch

dispatch run

Run a Dispatch application

Synopsis

Run a Dispatch application.

The command to start the local application endpoint should be specified after the run command and its options:

dispatch run [options] -- <command>

Dispatch spawns the local application endpoint and then dispatches function calls to it continuously.

Dispatch connects to the local application endpoint on http://127.0.0.1:8000. If the local application is listening on a different host or port, please set the —endpoint option appropriately. The value passed to this option will be exported as the DISPATCH_ENDPOINT_ADDR environment variable to the local application.

A new session is created each time the command is run. A session is a pristine environment in which function calls can be dispatched and handled by the local application. To start the command using a previous session, use the —session option to specify a session ID from a previous run.

dispatch run [flags]

Options

-e, --endpoint string Host:port that the local application endpoint is listening on (default "127.0.0.1:8000")
-h, --help help for run
-s, --session string Optional session to resume
--verbose Enable verbose logging

Options inherited from parent commands

-k, --api-key string Dispatch API key (env: DISPATCH_API_KEY)
--env-file string Path to .env file

SEE ALSO

  • dispatch - Main command for Dispatch CLI