Skip to main content
Staffify Docs
Updated

How It Works

┌─────────────────┐     ┌─────────────────┐     ┌─────────────────┐
│   Phone Call    │────▶│   AI Agent   │────▶│   Your API      │
│   Comes In      │     │   (Staffify)    │     │   (CRM, ERP)    │
└─────────────────┘     └─────────────────┘     └─────────────────┘

Step-by-Step Flow

  1. 1You configurean API connection to your system (once)
  2. 2You define actions(API endpoints) the AI can call
  3. 3You assign actionsto specific AI agents
  4. 4During calls, the AI automatically calls these actions when relevant
  5. 5Results are usedto personalize the conversation

Example Conversation

Caller:"Hi, I'd like to check my account balance."
AI internally calls lookup_customer API with customer's phone number
API returns: { name: "Sarah", balance: "$542.00", dob: "1990-05-20" }
AI:"I found your account. For security, can you confirm your date of birth?"
Caller:"May 20th, 1990"
AI:"Thank you Sarah! Your current balance is $542.00. Is there anything else I can help you with?"

Email agent: sending with actions

In the email agent, actions that change something (for example creating a lead or adding a note in your system) wait in the draft until the email is sent. When the draft is approved, in the inbox or through the review link in the forwarded email, Staffify handles the draft and its actions as one unit:

  1. 1Check first. Every action is checked before anything runs. If one can not be carried out, nothing is sent and nothing is changed.
  2. 2Own actions first, external last. Bookings, tickets and other actions in Staffify run first. Actions of your custom integrations run last.
  3. 3Stop at the first failure. If an action fails, the email is not sent and the actions that already ran in Staffify are undone.
  4. 4Retry or remove. A failed action blocks sending until you retry it or remove it from the draft.
External integrations can not be undone. A call to your own API changes data in your system, and Staffify has no way to reverse it automatically. That is why these actions run after every other step. If something fails after such an action ran, check your own system.
Custom Integrations - How It Works