mediasfu

n8n nodes for MediaSFU: start AI agent phone calls, create video rooms, and trigger workflows when rooms start or end, recordings are ready, or calls end.

Package Information

Released: this month
Downloads: 0 weekly / 0 monthly
Latest Version: 0.1.0
Author: MediaSFU

Documentation

n8n-nodes-mediasfu

Add AI phone agents and video rooms to your n8n workflows with MediaSFU.
Start an outbound AI agent call from a form, CRM or schedule; react when a call ends, a recording is ready or a room
starts or ends.

Install

In n8n: Settings → Community Nodes → Install, enter n8n-nodes-mediasfu, and accept the prompt.
Self-hosted from the command line: npm install n8n-nodes-mediasfu in your n8n custom folder.

Credentials

Create a MediaSFU API credential with your API username and API key from
mediasfu.com/api-keys.
n8n checks it by reading your balance. A sandbox key creates sandbox rooms; a production key creates billed rooms.

MediaSFU node (actions)

Resource Operations
Agent Call Start Agent Call (outbound call from your SIP number; the agent attached to it talks), Get State, Get Summary, Get Transcript, Hand to Agent, Hand to Person, End
Room Create (optionally with phone calls, live translation, low-bandwidth video, recording, a webhook), Get Join Link, Get, Get Many, End
Recording Get Many (optionally for one room)
Account Get Balance

Start Agent Call needs a live room created with Allow Phone Calls and someone already in it under Initiator
Name
. Add purpose, objective, reference ID, urgency and a short script so the agent knows why it is calling.

The node can also be used as a tool by n8n's AI Agent node.

MediaSFU Trigger

Event Fires when
Room Started / Room Ended A room is created / ends
Recording Ready / Recording Failed A recording finished processing
Participant Joined / Left Someone joins or leaves a room
Phone Call Ended A call on your number ends (caller, number, duration, whether the agent answered)
Phone Call Summary Ready The AI summary of a call is ready (includes the transcript)
Callback Requested The caller booked a callback (the PIN itself is never passed on)
Human Handoff Requested The agent asked for a person to take over, with priority and reason

Room events, automatic setup (default): while the workflow is active, your account's room webhook points at this
trigger with a fresh signing secret, and every request is checked against it. If your account already sends room events
somewhere else, the trigger stops and asks you to turn on Replace Existing Webhook (the old URL comes back when you
deactivate the workflow). Your n8n must be reachable over public HTTPS.

Room events, manual setup: pass the trigger's URL as webhookUrl when you create a room (the MediaSFU node's
Create Room has this option), and put the room's webhookSecret in Room Webhook Secret.
Room events require a configured signing secret; unsigned or incorrectly signed requests are rejected.

Phone call events: in the MediaSFU dashboard, open Phone & SIP Setup, set the number's webhook URL (call ended,
summary, handoff) and its callback webhook URL (callback requested) to the trigger's production URL, and put the
number's secure code in Call Webhook Token.
Phone call events require this token. An empty token does not accept incoming events.

Example: AI receptionist follow-up

  1. MediaSFU Trigger on Phone Call Summary Ready.
  2. IF the summary mentions a callback.
  3. Google Sheets / HubSpot / Slack: log the caller and summary.

Starter receptionist service and agent prompts: https://github.com/MediaSFU/starter-ai-receptionist.

Develop

npm ci           # Node.js 24 for the development tools
npm test          # builds with tsc and runs the tests in test/
npm run lint      # official n8n strict community-node checks

The package has no runtime dependencies. Releases are published from GitHub Actions with npm provenance
(.github/workflows/publish.yml).

Links

MIT licensed.

Discussion