Skip to main content

LangGraph agent with approval

A LangGraph agent whose risky tool runs only after the person approved on their phone.

StarterDraftView source
This page is a draft. The code exists, and not all of it has been run for this page yet. The page says what was checked.
Packages
lumoauth
Works with
PythonLangChain / LangGraph

What you get​

  • A graph with a planning node, an ask_human node and a tool node.
  • A cancelled action that the model learns about.

Create it​

pip install -r requirements.txt
cp .env.example .env
python wire_agent.py

Settings​

VariableValue
LUMOAUTH_URLhttps://app.lumoauth.dev, or https://eu.app.lumoauth.dev for the EU region.
LUMOAUTH_ORG_IDYour organization, for example acme-corp.
AGENT_CLIENT_ID, AGENT_CLIENT_SECRETThe credentials of the agent.
APPROVER_EMAILThe person to ask. They need the LumoAuth app.
OPENAI_API_KEYA key for the model.

Next steps​