Your First Agent
Outcome: a completed agent run that is compiled to and executed as a Conductor workflow.
Time: about 5 minutes.
Conductor Agents are available in Python, Java, TypeScript/JavaScript, and C#. Choose a language below to see its complete install and first-run steps.
For using an existing framework agent, such as LangChain, use framework agent quickstarts. You can also call LLMs and tools directly from workflow tasks using Conductor's native AI tasks.
Prerequisites
Complete Connect to Conductor, including the hosted model integration or local provider API-key setup required by the selected model. You also need the runtime or SDK tooling for the language you select.
Language-specific quickstart
The CONDUCTOR_SERVER_URL connection variables (and CONDUCTOR_AUTH_KEY/CONDUCTOR_AUTH_SECRET when required) are configured in Connect to Conductor. Keep provider credentials in the environment or secret system used by the agent workers; do not put them in workflow input.
Choose a language to reveal its install and runnable first-agent steps.
1. Install Python support
2. Save and run an agent
Save this as hello.py:
from conductor.ai.agents import Agent, AgentRuntime
agent = Agent(
name="greeter",
model="openai/gpt-4o-mini",
instructions="You are a friendly assistant. Keep responses brief.",
)
with AgentRuntime() as runtime:
result = runtime.run(agent, "Say hello and share a fun Python fact.")
result.print_result()
See the Python agent guide for more examples.
1. Install Java support
Gradle:
Maven:
<dependency>
<groupId>org.conductoross</groupId>
<artifactId>conductor-client-ai</artifactId>
<version>VERSION</version>
</dependency>
2. Define and run an agent
import org.conductoross.conductor.ai.Agent;
import org.conductoross.conductor.ai.AgentRuntime;
import org.conductoross.conductor.ai.model.AgentResult;
Agent agent = Agent.builder()
.name("java_greeter")
.model("openai/gpt-4o-mini")
.instructions("You are friendly and concise.")
.build();
try (AgentRuntime runtime = new AgentRuntime()) {
AgentResult result = runtime.run(agent, "Share a fun Java fact.");
result.printResult();
}
Run the class with your Gradle or Maven application task. See the Java agent guide for project setup and runnable examples.
1. Install TypeScript / JavaScript support
2. Save and run an agent
Save this as my-agent.ts:
import { Agent, AgentRuntime } from "@io-orkes/conductor-javascript/agents";
const agent = new Agent({
name: "greeter",
model: "openai/gpt-4o-mini",
instructions: "You are friendly and concise.",
});
const runtime = new AgentRuntime();
try {
const result = await runtime.run(agent, "Share a fun TypeScript fact.");
result.printResult();
} finally {
await runtime.shutdown();
}
See the TypeScript agent guide for more examples.
1. Install C# support
2. Define and run an agent
using Conductor.AI;
var agent = new Agent("greeter")
{
Model = "openai/gpt-4o-mini",
Instructions = "You are friendly and concise.",
};
await using var runtime = new AgentRuntime();
var result = await runtime.RunAsync(agent, "Share a fun C# fact.");
result.PrintResult();
See the C# agent guide for project setup and runnable examples.
3. Verify and recover
In the Conductor UI, locate the execution created by the run. Verify its terminal status and inspect its task timeline, inputs, and output. If the run cannot reach the model, first confirm the server URL and provider credential in the worker environment; then inspect the failed task in the execution before retrying.
Add your agent to a workflow
After deploying an agent, a workflow can invoke it as an AGENT task alongside ordinary API calls, retrieval, approval, retries, branches, and parallel work. The workflow owns the durable business process; the agent owns the model-driven decision or action inside it.
{
"name": "ask_agent",
"taskReferenceName": "ask_agent_ref",
"type": "AGENT",
"inputParameters": {
"agentType": "conductor",
"name": "greeter",
"prompt": "Summarize this workflow context: ${fetch_context.output.response.body}",
"pollIntervalSeconds": 5
}
}
The task records the agent execution ID, state, text, and structured output, so operators can inspect the parent workflow and the agent run together. See the complete workflow-plus-agent example or the AGENT task integration guide.
What you built
Each language uses the same durable execution model: the runtime compiles and runs the agent as a Conductor workflow, preserving an inspectable execution record. A later design can add approval, waits, retries, composition, and operational recovery without moving the agent logic into one long-lived process.
Next production step
Next: Bring your framework agent — run an existing OpenAI Agents, LangChain, LangGraph, or ADK agent through the same durable runtime.
Continue with the production agent architecture. It covers governance, evaluation, deployment, composition, recovery, and operations.