Skip to content

Build Your First Workflow

Create and execute a workflow in 10 minutes

Learn by building a simple greeting workflow with parameters and validation.

A workflow that accepts a name and returns a personalized greeting.

  1. Open the Code Editor from the header.

    alt text

  2. Create a new file called hello_world.py:

    alt text

    from bifrost import workflow, param, ExecutionContext
    import logging
    logger = logging.getLogger(__name__)
    @workflow(
    name="hello_world",
    description="A simple greeting workflow",
    category="Examples"
    )
    @param("name", type="string", label="Your Name", required=True)
    async def hello_world(context: ExecutionContext, name: str):
    """Generate a personalized greeting."""
    logger.info(f"Generating greeting for {name}")
    greeting = f"Hello, {name}! Welcome to Bifrost."
    return {"greeting": greeting, "name": name}
  3. Hit CTRL/CMD + S to save.

  4. Navigate to WorkflowsExamplesHello World

    alt text

  5. Click Execute, enter your name, and click Run

alt text

{
"greeting": "Hello, Alice! Welcome to Bifrost.",
"name": "Alice"
}

Navigate to Executions to see all runs with logs and results.