This repository provides Python scripts to manage Lyzr Agents and Workflows using the CLI. You can create, update, list, fetch, and delete agents and workflows with simple commands.
-
Python 3.9+
-
Virtual environment activated (
.venvrecommended) -
API key configured in
.envor shell environmentexport LYZR_API_KEY="your-api-key-here"
python -m scripts.list_agentspython -m scripts.create_single_task_agent yaml/single_task/email_summarizer.yamlpython -m scripts.get_agent <agent_id>python -m scripts.update_agent <agent_id> examples/kyc_agent.yamlpython -m scripts.delete_agent <agent_id>python -m scripts.delete_all_agentspython -m scripts.list_workflowspython -m scripts.delete_all_workflows-
Check what agents exist
python -m scripts.list_agents
-
Delete all existing agents
python -m scripts.delete_all_agents
-
Confirm they are gone
python -m scripts.list_agents
-
Create a new agent from YAML
python -m scripts.create_single_task_agent yaml/single_task/email_summarizer.yaml
-
Fetch and update agent details
python -m scripts.get_agent <agent_id> python -m scripts.update_agent <agent_id> examples/kyc_agent.yaml
- Replace
<agent_id>with the actual agent ID returned from the list or create commands. - Scripts are modular and can be chained in CI/CD pipelines.
- Use YAML files (
examples/,yaml/single_task/) to define reusable agent behaviors.