Demo can be found here.
The example uses app.windmill.dev as a backend to create an account there and use your credentials to login.
This project demonstrates how Windmill can be whitelabelled in a React app using webpack.
Whitelabelling requires a special license and the package
@windmill-labs/windmill-react-sdk is not public. Please contact us at
[email protected] to get started.
Have a windmill instance available at localhost:8000 (or change
package.json/proxy) that accepts [email protected] / changeme
npm install
npm run dev
Monaco workers need to be available at the /assets/ path. This is done by
calling ./copy_workers.sh which will pull them from node_modules. It is
already done on this repo.
To update the API reference below after an SDK upgrade:
bash generate-api-docs.sh
Then paste the output into this README, replacing the API Reference section.
Auto-generated by generate-api-docs.sh from SDK type definitions.
| Prop | Type | Required |
|---|---|---|
mode |
{ type: "create"; path: string } | { type: "edit"; path: string } | { type: "fork"; path: string; forkPath: string } |
Yes |
onDeploy |
(path: string) => void |
Yes |
onDetails |
(path: string) => void |
Yes |
onSaveDraft |
(path: string, status: "new" | "pathChange" | undefined) => void |
Yes |
onDraftSaved |
(path: string) => void |
No |
onDraftError |
(error: Error) => void |
No |
onDeployError |
(error: Error) => void |
No |
customUi |
FlowBuilderWhitelabelCustomUi |
No |
disableAi |
boolean |
No |
disableFlowInputs |
boolean |
No |
setDraftCb |
(cb: () => void) => void |
No |
| Prop | Type | Required |
|---|---|---|
mode |
{ type: "create"; path: string; lang: ScriptLang; summary?: string; description?: string; timeout?: number } | { type: "edit"; path: string } | { type: "fork"; path: string; forkPath: string } |
Yes |
onDeploy |
(path: string) => void |
Yes |
onDetails |
(path: string) => void |
Yes |
onSaveInitial |
(path: string) => void |
Yes |
onSaveDraft |
(path: string) => void |
No |
onDraftError |
(error: Error) => void |
No |
onDeployError |
(error: Error) => void |
No |
customUi |
ScriptBuilderWhitelabelCustomUi |
No |
neverShowMeta |
boolean |
No |
| Prop | Type | Required |
|---|---|---|
path |
string |
Yes |
code |
string |
Yes |
lang |
ScriptLang |
Yes |
tag |
string |
No |
onChange |
(code: string, schema: string) => void |
No |
| Prop | Type | Required |
|---|---|---|
schema |
object |
Yes |
onChange |
(schema: object) => void |
No |
customUi |
{ noAddPopover?: boolean } |
No |
| Prop | Type | Required |
|---|---|---|
newResource |
boolean |
Yes |
resource_type |
string |
Yes |
path |
string |
No |
hidePath |
boolean |
No |
onChange |
(e: { path: string, args: any, description: string }) => void |
Yes |
| Prop | Type | Required |
|---|---|---|
flow |
{ summary: string; description?: string; value: FlowValue; schema?: any } |
Yes |
| Prop | Type | Required |
|---|---|---|
jobId |
string |
Yes |
workspaceId |
string |
No |
hideFlowResult |
boolean |
No |
hideDownloadInGraph |
boolean |
No |
hideNodeDefinition |
boolean |
No |
hideTimeline |
boolean |
No |
hideJobId |
boolean |
No |
hideDownloadLogs |
boolean |
No |
| Prop | Type | Required |
|---|---|---|
path |
string |
Yes |
onHistoryRestore |
() => void |
No |
| Export | Description |
|---|---|
switchWorkspace(workspace: string) |
Switch the active workspace context |
OpenAPI |
OpenAPI configuration object (set OpenAPI.BASE to your Windmill API URL) |
INITIAL_CODE |
Default code templates per language |
customIcon |
Custom icon URLs ({ normal: string, white: string }) |
type ScriptLang =
| 'python3' | 'deno' | 'go' | 'bash' | 'powershell'
| 'postgresql' | 'mysql' | 'bigquery' | 'snowflake' | 'mssql'
| 'oracledb' | 'graphql' | 'nativets' | 'bun' | 'php'
| 'rust' | 'ansible' | 'csharp' | 'nu' | 'java' | 'ruby'
| 'duckdb' | 'bunnative';These types control which UI elements are shown. All boolean fields default to true (visible).
Set a field to false to hide the corresponding UI element.
type FlowBuilderWhitelabelCustomUi = {
topBar?: {
path?: boolean;
export?: boolean;
history?: boolean;
aiBuilder?: boolean;
tutorials?: boolean;
diff?: boolean;
extraDeployOptions?: boolean;
editableSummary?: boolean;
settings?: boolean;
draft?: boolean;
};
settingsPanel?: boolean;
settingsTabs?: {
schedule?: boolean;
sharedDiretory?: boolean;
earlyStop?: boolean;
earlyReturn?: boolean;
workerGroup?: boolean;
concurrency?: boolean;
debouncing?: boolean;
cache?: boolean;
};
triggers?: boolean;
flowNode?: boolean;
hub?: boolean;
hubCode?: boolean;
graph?: {
aiBuilder?: boolean;
dataflow?: boolean;
};
stepInputs?: {
ai?: boolean;
};
stepAdvancedSettings?: boolean;
languages?: (SupportedLanguage | 'docker' | 'bunnative')[];
scriptFork?: boolean;
scriptEdit?: boolean;
tagEdit?: boolean;
editorBar?: EditorBarUi;
downloadLogs?: boolean;
tagSelectPlaceholder?: string;
tagSelectNoLabel?: boolean;
tagLabel?: string;
aiAgent?: boolean;
aiSandbox?: boolean;
};type DisplayResultUi = {
disableAiFix?: boolean;
disableDownload?: boolean;
};type PreviewPanelUi = {
disableHistory?: boolean;
disableTracing?: boolean;
disableTriggerCaptures?: boolean;
disableTriggerButton?: boolean;
displayResult?: DisplayResultUi;
disableVariablePicker?: boolean;
disableDownload?: boolean;
tagLabel?: string;
};type EditorBarUi = {
contextVar?: boolean;
variable?: boolean;
resource?: boolean;
reset?: boolean;
type?: boolean;
assistants?: boolean;
multiplayer?: boolean;
autoformatting?: boolean;
editorSettings?: boolean;
vimMode?: boolean;
relativeLineNumbers?: boolean;
aiGen?: boolean;
aiCompletion?: boolean;
library?: boolean;
useVsCode?: boolean;
diffMode?: boolean;
s3object?: boolean;
database?: boolean;
ducklake?: boolean;
dataTable?: boolean;
debug?: boolean;
history?: boolean;
saveToWorkspace?: boolean;
};type EditableSchemaFormUi = {
jsonOnly?: boolean;
disableVariablePicker?: boolean;
};type SettingsPanelMetadataUi = {
languages?: SupportedLanguage[];
disableScriptKind?: boolean;
editableSchemaForm?: EditableSchemaFormUi;
disableMute?: boolean;
disableAiFilling?: boolean;
};type SettingsPanelUi = {
metadata?: SettingsPanelMetadataUi;
disableMetadata?: boolean;
disableRuntime?: boolean;
disableGeneratedUi?: boolean;
disableTriggers?: boolean;
};type ScriptEditorWhitelabelCustomUi = {
editorBar?: EditorBarUi;
previewPanel?: PreviewPanelUi;
disableTooltips?: boolean;
};type ScriptBuilderWhitelabelCustomUi = {
topBar?: {
path?: boolean;
editablePath?: boolean;
settings?: boolean;
extraDeployOptions?: boolean;
editableSummary?: boolean;
diff?: boolean;
tagEdit?: boolean;
};
settingsPanel?: SettingsPanelUi;
disableTooltips?: boolean;
editorBar?: EditorBarUi;
previewPanel?: PreviewPanelUi;
tagSelectPlaceholder?: string;
};