Invoking processes
Once a Process is deployed, you can run it on demand from your application, or let its triggers run it automatically.
From the SDK
Section titled “From the SDK”const result = await sdk.processes.execute('computeAverage', { window: '1h' });See SDK → Processes for the full client API
(getProcesses, changeTriggers).
Over HTTP
Section titled “Over HTTP”Two HTTP forms are available:
POST /machhub/processes/executeAuthorization: Bearer <token>Content-Type: application/json
{ "name": "computeAverage", "input": { "window": "1h" } }The Bearer token is read from localStorage['machhub_token'] in browser clients.
For a process with an HTTP trigger, you can also call its slug endpoint directly, with the JSON body merged into the process inputs:
POST /process/<slug>Content-Type: application/json
{ "window": "1h" }Import / export
Section titled “Import / export”Processes can be exported and imported as JSON (snake_case keys). Runtime-managed
fields such as enabled, log_enabled, version, id, and domain_id are not part
of the exported definition.
Packages
Section titled “Packages”Each domain’s worker has its own dependency set. Add the pip (Python) or npm
(TypeScript) packages your process code needs, per domain.