Real-world services for OpenAI Agents
The Agents SDK gives you tools, handoffs, and guardrails. It doesn't give you a notary. Add ROJI as a tool and your agent can order one.
The problem
Agents built on the OpenAI Agents SDK stop cleanly at human-shaped steps — the SDK's human-approval patterns pause the run and wait. But approval flows assume the human you need is in your org and watching a queue. When the step is "get this filed at the county clerk" or "photograph the site," there is no queue to route to.
The pattern
Expose ROJI as a function tool. The tool places the order and returns the order id immediately — the run continues or ends, and your app picks the result up on the webhook. Illustrative sketch:
# illustrative — not a published SDK
from agents import Agent, function_tool
import roji
@function_tool
def order_service(service_id: str, inputs: dict,
fee_preview_id: str) -> dict:
"""Order a listed service from a verified business on roji and return
the order id. The listing sets the price and the SLA; fee_preview_id is
the itemized total you accepted from get_service, before any charge.
The deliverable arrives later via webhook — do not wait for it."""
order = roji.orders.create(
service_id=service_id, inputs=inputs,
fee_preview_id=fee_preview_id,
)
return {"order_id": order.id, "state": order.state}
agent = Agent(
name="compliance-ops",
instructions="When a step requires a licensed or physical-world action, "
"search the catalog, read the listing's price and SLA, then "
"use order_service and record the order id. Never block on it.",
tools=[order_service],
)
When order.question_asked fires, answer it programmatically against the attached answer schema — a second, tiny agent run with the order context loaded is usually enough. When order.delivered fires, the deliverable is schema-validated data your code consumes directly.
If your stack prefers MCP over bespoke tools, skip the sketch entirely: the Agents SDK speaks MCP, and mcp.roji.ai exposes the full surface.
What to expect
Category-dependent turnaround: minutes for verification calls, hours for field capture, days for document review and expert judgment. The number your agent plans against is not a guess — it is the SLA the business published on the listing, readable before ordering. Spend is capped by platform-enforced policies your Principal sets, so the tool physically cannot exceed them, and payment happens at order with ROJI never holding the money. If the business rejects the order or misses its SLA, the refund is automatic and full — the rest of the guarantees are on the ordering page.
Design partners
Your agent already knows
when it needs a human.
Give it somewhere to send that work. We're onboarding OpenAI Agents SDK teams now.