- Overview
- Getting Started with UiPath Agents
- Getting Started with UiPath Agents using LangGraph
- Building a Low-Code Agent in Studio Web
- Adding Tools to Your UiPath Agent
Use your coding agent and UiPath skills to build, configure, and run a LangGraph agent locally.
With the CLI installed, skills in place, and your account authenticated, you are ready to scaffold the local project.
Step 4 - Set up the local project
Create a new folder for your agent project and open it in VS Code (File → Open Folder). All commands from this step onward run from the project folder root.
Create the Python environment
Create a virtual environment pinned to a supported Python version and activate it:
mkdir QuestIntake
cd QuestIntake
uv venv --python 3.13
source .venv/bin/activate
mkdir QuestIntake
cd QuestIntake
uv venv --python 3.13
source .venv/bin/activate
Windows: Use .venv\Scripts\activate instead of source .venv/bin/activate.
Python version: uv downloads and manages Python automatically if 3.13 is not on your PATH. Supported versions are 3.11, 3.12, and 3.13.
Install the LangGraph integration
LangGraph is a Python framework for building stateful LLM agents as graphs of nodes and edges. uipath-langchain is the UiPath integration layer that packages a LangGraph agent for deployment and evaluation on the UiPath platform.
Install the UiPath LangGraph package into the active venv. This also makes the framework available for project scaffolding in the next step:
uv pip install uipath-langchain
uv pip install uipath-langchain
Register Python with the UiPath CLI
Tell the CLI where the UiPath-compatible Python executable lives:
uip codedagent setup --force
uip codedagent setup --force
You should see "Result": "Success". This step is required once per machine (and after any venv changes) before using uip codedagent commands.
Scaffold the project
Create the UiPath project structure. uip codedagent new detects the installed framework and generates the right scaffold files:
uip codedagent new QuestIntake
uip codedagent new QuestIntake
This creates pyproject.toml, main.py, langgraph.json, uipath.json, entry-points.json, bindings.json, and coding agent context files (AGENTS.md, CLAUDE.md, .agent/). The main.py is a placeholder; your coding agent replaces it in Step 5.
Add the local dev server dependency and sync the lockfile:
uv add uipath-dev --dev
uv sync
uv add uipath-dev --dev
uv sync
Generate entry points
Run init to generate the entry point schemas from the scaffold code:
uip codedagent init
uip codedagent init
The project has a placeholder entry point at this stage. Re-run init in Step 5 after your coding agent writes the real agent code.
Step 5 - Build the agent with your coding agent
This is where the UiPath skills pay off. Open your coding agent and prompt it to create the agent logic. The prompt below is short: it describes what the agent should do, not how to build it.
The uipath-agents skill your coding agent has installed already knows the LangGraph integration patterns, correct SDK imports, Pydantic schema conventions, and the lazy LLM initialization requirement (the LLM client must be initialized inside the node function, not at module load time — UiPath's container runtime does not support module-level LLM objects; see the SDK quick start for a working example). Without skills, you would need to specify all of that in the prompt itself.
Use the following prompt (or adapt it to your use case):
Create a UiPath coded agent using LangGraph.
The agent is a quest intake classifier for a D&D adventurer's guild. Given a
description of an incoming quest, it classifies the difficulty as one of four tiers:
- Trivial: Simple errands anyone can handle (e.g., deliver a letter, clear rats from a cellar)
- Standard: Moderate quests requiring some skill (e.g., escort a merchant caravan)
- Heroic: Difficult quests requiring significant expertise (e.g., slay a wyvern, infiltrate a thieves' guild)
- Legendary: Extreme quests requiring top-tier heroes and special approval (e.g., defeat a lich, close a planar rift)
Return the classification tier and a brief reasoning.
Use these exact field names in the State schema:
- Input field: `description` (string)
- Output fields: `tier` (string) and `reasoning` (string)
Create a langgraph.json and an input.json with a sample D&D quest for testing.
Create a UiPath coded agent using LangGraph.
The agent is a quest intake classifier for a D&D adventurer's guild. Given a
description of an incoming quest, it classifies the difficulty as one of four tiers:
- Trivial: Simple errands anyone can handle (e.g., deliver a letter, clear rats from a cellar)
- Standard: Moderate quests requiring some skill (e.g., escort a merchant caravan)
- Heroic: Difficult quests requiring significant expertise (e.g., slay a wyvern, infiltrate a thieves' guild)
- Legendary: Extreme quests requiring top-tier heroes and special approval (e.g., defeat a lich, close a planar rift)
Return the classification tier and a brief reasoning.
Use these exact field names in the State schema:
- Input field: `description` (string)
- Output fields: `tier` (string) and `reasoning` (string)
Create a langgraph.json and an input.json with a sample D&D quest for testing.
Coding agents are non-deterministic. Your generated code will differ from any examples shown here; that is expected. What matters is that main.py runs without errors and returns a classification.
Delivery question: If your coding agent presents a 'Delivery' question (Studio Web, local dev server, or skip), select Skip - I'm done for now. Connect to Studio Web in Step 9.
After the coding agent finishes, re-run init to pick up the updated entry points from the new Pydantic schemas:
uip codedagent init
uip codedagent init
You should see output confirming the entry point was detected along with an ASCII graph diagram:
Created 'entry-points.json' file with 1 entrypoint(s).
Created 'entry-points.json' file with 1 entrypoint(s).
Before continuing, open pyproject.toml and add an authors entry under [project] if one is not already there. UiPath requires this field to package the project:
authors = [{ name = "Your Name" }]
authors = [{ name = "Your Name" }]
With the agent running locally and the entry points registered, you are ready to run it and build an evaluation set in the next section.