USE CASE · OPS / LOGISTICS
Supplier check-in.
Daily cron asks OpenPhn to call five suppliers about open POs. Typed outcomes land in Google Sheets. The ops team reviews five JSON rows instead of making fifteen calls.
OUTCOME SCHEMA
What comes back.
Declare the shape up front. OpenPhn fills every field it can, leaves optional fields null when it can't, and flags low-confidence extractions.
- ◆Batch dispatch across a supplier list in one API call
- ◆Idempotent — safe to re-run a whole daily batch
- ◆Extracts tracking numbers + ETAs even from voicemail recordings
OUTCOME SCHEMA
{
order_id: { type: "string" },
ships_today: { type: "boolean" },
eta_date: { type: "date", optional: true },
tracking_number: { type: "string", optional: true },
backordered: { type: "boolean", optional: true },
contact_name: { type: "string", optional: true },
}THE FULL CALL
From objective to outcome.
REQUEST
import { OpenPhn } from "openphn"
const client = new OpenPhn({ apiKey: process.env.OPENPHN_KEY! })
const call = await client.calls.create({
to: "+14155551234",
objective: "Ask about PO A-14421 with Apex Bearings. Confirm if it ships today; if not, get the ETA and any tracking number.",
outcomeSchema: {
order_id: { type: "string" },
ships_today: { type: "boolean" },
eta_date: { type: "date", optional: true },
tracking_number: { type: "string", optional: true },
backordered: { type: "boolean", optional: true },
contact_name: { type: "string", optional: true },
},
consentType: "existing_business_relationship",
})
// call.outcome: order_id, ships_today, eta_date, tracking_number, backordered, contact_nameWEBHOOK BODY · outcome
{
"order_id": "A-14421",
"ships_today": true,
"eta_date": "2026-04-17",
"tracking_number": "1Z999AA10123456784",
"backordered": false,
"contact_name": "Jamie at Apex"
}