In this workshop, you deploy a small Render stack and build an agent that inspects it.
You will use:
- A Render web service for the agent.
- A second Render web service as the target.
- Render Postgres for memory.
- The Render API for services, deploys, logs, and metrics.
- Anthropic's Messages API for the agent loop.
Clone the workshop repo and switch to the starter branch:
git clone https://github.com/render-examples/render-ops-agent-workshop.git
cd render-ops-agent-workshop
git switch starterInstall dependencies:
npm installVerify the project builds:
npm run checkCheckpoint: the build passes and the test suite passes.
Create a Blueprint from this repo in the Render Dashboard.
The Blueprint creates:
ops-agentops-targetops-agent-db
After Render creates the resources, set these secret values on ops-agent:
RENDER_API_KEYANTHROPIC_API_KEY
Render wires DATABASE_URL from ops-agent-db.
Checkpoint: both web services show a healthy deploy, and ops-agent has a successful pre-deploy migration.
Use the deployed ops-agent URL:
curl -X POST https://YOUR-OPS-AGENT.onrender.com/runAt this point, the agent can list services. It should see ops-agent and ops-target.
Checkpoint: the response mentions the services in your Render account.
Open the tool files in agent/tools/.
The room path wires these tools:
list_servicesfetch_deploysfetch_logsfetch_metrics
Each tool has three parts:
- A name the model can call.
- A JSON schema for input.
- A function that fetches read-only Render data.
Run the tests:
npm test -- test/render-tools.test.ts test/tool-registry.test.tsDeploy again after the tools are wired.
Checkpoint: the agent can inspect ops-target deploys, logs, or metrics instead of only listing service names.
Open migrations/001_memory.sql and agent/memory.ts.
The memory layer stores:
runs: one row per agent execution.findings: one row per stable finding fingerprint.
Render runs migrations with preDeployCommand:
preDeployCommand: npm run db:migrateRun the memory tests:
npm test -- test/memory.test.ts test/run-agent.test.tsDeploy again after memory is wired.
Checkpoint: a second run should recognize recent findings instead of treating everything as brand-new.
Set AGENT_URL in .env to your deployed ops-agent URL:
AGENT_URL=https://YOUR-OPS-AGENT.onrender.comRun the Ink terminal client:
npm run tuiAsk it to inspect your services.
Checkpoint: the TUI prints the agent run lifecycle and final summary.
If /run fails, check:
RENDER_API_KEYis set onops-agent.ANTHROPIC_API_KEYis set onops-agent.DATABASE_URLexists onops-agent.- The
preDeployCommandcompleted. - The Render API wrapper is still blocking non-GET requests.
If the model hits max turns, narrow tool output before increasing MAX_TURNS.
Keep ops-agent as the control plane. Move the heavier analysis step into a Render Workflow task so the analysis can run with Workflow retries and observability.
The high-level flow:
ops-agentcreates arunsrow.ops-agentstarts a Workflow task.- The Workflow task gathers data and runs analysis.
ops-agentstores the result and findings in Postgres.
Workflows do not yet have Blueprint support, so this path uses Dashboard setup.
After Workflow-backed analysis works, add a cron job that calls ops-agent on a schedule.
The cron job should stay small. It only wakes up ops-agent; ops-agent handles auth, memory, and Workflow orchestration.
Point the agent at services you run outside the workshop. You can also explore the Render Diagnostic Agent for a browser-based daily workflow.