Embedding a video conferencing API lets you add video conferencing to your website or app without building WebRTC infrastructure from scratch. With Digital Samba, you create a room through the REST API, generate a participant token, then load the prebuilt video interface with the JavaScript SDK or a simple iframe – typically in under an hour. This guide walks through the full process, with code examples, a WordPress option and answers to common questions.
Whether you are building a virtual classroom, supporting remote teams or running telehealth consultations, a reliable video conferencing API lets you keep video calls on your own domain instead of sending users to a third-party tool. Below you will find every step, from creating your account to customising the embedded call with the SDK.
Table of contents
Adding video conferencing to your website keeps the whole interaction – booking, conversation and follow-up – inside your product, under your brand. Your users never leave your domain, you control the experience end to end, and you avoid asking customers to install or trust a separate meeting app.
The pattern fits any product where people need to talk face to face: online learning platforms, telehealth services, customer support, recruitment, legal consultations and remote team tools. In each case, embedded video turns your website from a brochure into the place where the actual work happens. We cover the business case in more depth in our guide to the advantages of embedding video calls in your app.
The practical question is how to do it without months of WebRTC development. That is what an embedded video conferencing platform solves: the provider runs the infrastructure, and you integrate a ready interface through an API, an SDK or a plain iframe.
The sections below show exactly how to do this with Digital Samba.
You can add live video calls to your website in a few steps using Digital Samba Embedded. Whether you want a quick HTML embed or full control via the API and SDK, this section walks through each option, from basic to advanced.
First, sign up for a free Digital Samba account.
Once you're in, open the Team section of the dashboard to find your Team ID and Developer key – these are the credentials that authenticate your API requests. The Developer key also signs participant tokens, so treat it like a password and keep it on your server.
The simplest option. Create a room, then place an iframe with the room URL anywhere in your HTML. No build step, no JavaScript – the full video interface loads inside your page.
The backend layer. Use it to create rooms, assign roles, manage recordings and connect video sessions to the rest of your stack. This is the right tool when rooms need to be created programmatically – one per lesson, consultation or support ticket.
The frontend layer. The SDK embeds the same prebuilt interface but gives your code control over it: you can set the user's name and language before joining, react to in-room events in real time and call methods such as muting or ending the session.
To create a room, send a POST request to the /rooms endpoint, authenticating with your Team ID and Developer key. The only required field is privacy. Here's an example that also sets a friendly URL and roles:
curl --request POST \
--header "Content-Type: application/json" \
--url https://api.digitalsamba.com/api/v1/rooms \
--user YOUR_TEAM_ID:YOUR_DEVELOPER_KEY \
--data '{
"privacy": "public",
"friendly_url": "my-first-room",
"roles": ["moderator", "speaker", "attendee"],
"default_role": "attendee"
}'
The response includes the room's details, and the room becomes available at https://YOUR_TEAM.digitalsamba.com/my-first-room. If you skip friendly_url, the API generates one for you. See the room creation docs for the full field list.
The privacy setting determines who can access the room:
Roles define what participants can do in the room. Digital Samba provides preset roles, and you can create custom ones with their own permission sets:
When a room has more than one role, you must set a default_role – the role applied to anyone who joins without a token. Keep it the least powerful role, so nobody enters as a moderator by accident.
Prefer clicking to coding? You can create and configure the same rooms visually – see our guide on how to configure your Digital Samba rooms using the dashboard.
Private rooms authenticate participants with a JWT token. You can sign tokens yourself with any JWT library, using your Developer key as the secret, or request them from the REST API. A token carries a few short claims:
Signing tokens on your own server is the better route when you issue many tokens at once, since the API is rate-limited. The token docs include ready-made examples in several languages.
For the quickest result, embed the room with a plain iframe. The allow attribute matters – without it, the browser blocks camera and microphone access inside the frame:
<iframe src="https://YOUR_TEAM.digitalsamba.com/my-first-room" allow="camera; microphone; display-capture; autoplay" style="width: 100%; height: 600px; border: 0;"> </iframe>
For production integrations, the SDK is the recommended route. It is distributed as the @digitalsamba/embedded-sdk npm module, and for quick prototyping you can load it from a CDN:
<script crossorigin src="https://unpkg.com/@digitalsamba/embedded-sdk"></script>
<script>
const sambaFrame = DigitalSambaEmbedded.createControl({
url: 'https://YOUR_TEAM.digitalsamba.com/my-first-room'
});
sambaFrame.load();
</script>
Or, with npm and a bundler:
npm install @digitalsamba/embedded-sdk
import DigitalSambaEmbedded from '@digitalsamba/embedded-sdk';
const sambaFrame = DigitalSambaEmbedded.createControl({
url: 'https://YOUR_TEAM.digitalsamba.com/my-first-room'
});
sambaFrame.load();
That's the whole integration: the prebuilt interface loads inside your page, with screen sharing, chat and the rest of the feature set already working.
The SDK gives you control over how the embedded call starts and where it lives on your page, so the room feels like a native part of your product rather than a bolt-on.
Everything starts with the DigitalSambaEmbedded class. You can initialise it with the constructor, which loads the room immediately, or with the createControl factory method, which lets you decide later when to call load() – useful when the room should only appear after a user action, such as clicking 'Join lesson'.
InitOptions control where and how the room is embedded:
For example, to load the room inside a specific container element:
import DigitalSambaEmbedded from '@digitalsamba/embedded-sdk';
const container = document.querySelector('#video-call-container');
const sambaFrame = DigitalSambaEmbedded.createControl({
url: 'https://YOUR_TEAM.digitalsamba.com/my-first-room',
root: container,
token: 'PARTICIPANT_TOKEN_IF_PRIVATE'
});
sambaFrame.load();
The optional roomSettings object defines what happens when a user enters the room. Among other things, you can:
Here's a typical configuration:
const sambaFrame = DigitalSambaEmbedded.createControl({
url: 'https://YOUR_TEAM.digitalsamba.com/my-first-room',
roomSettings: {
username: 'Jane Smith',
initials: 'JS',
appLanguage: 'en',
layoutMode: 'tiled',
videoEnabled: false,
audioEnabled: false,
virtualBackground: { blur: 'balanced' }
}
});
sambaFrame.load();
After setting InitOptions and roomSettings, calling load() embeds the configured room into your page. For every option and the valid combinations, see the DigitalSambaEmbedded class documentation, and for a worked example read our tutorial on how to embed a video conference widget with the Digital Samba SDK.
The SDK exposes real-time events and control methods, so your frontend can react to what happens in the room – users joining, hands raised, audio toggled – and act on it from your own code.
Subscribe with on(), unsubscribe with off(), or use once() for one-time subscriptions. The SDK emits events such as userJoined, userLeft, handRaised, handLowered, audioEnabled, audioDisabled, recordingStarted and many more:
const onUserJoined = (event) => {
console.log('A participant joined:', event);
};
sambaFrame.on('userJoined', onUserJoined); // subscribe
sambaFrame.off('userJoined', onUserJoined); // unsubscribe
Want to show a message when someone leaves the call? Use the userLeft event:
sambaFrame.on('userLeft', () => {
showNotification('A participant has left the call');
});
For debugging, subscribe to '*' to log every event the room emits – handy in development environments:
sambaFrame.on('*', (event) => console.log('SDK event:', event));
Methods let your code act on the room. Initialise the SDK and load the room first, and wait for the userJoined event before calling methods that affect the local user. A few examples:
sambaFrame.on('userJoined', () => {
sambaFrame.enableVideo(); // start the local camera
});
sambaFrame.requestUnmute(participantId); // ask a participant to unmute
sambaFrame.endSession(); // end the call for everyone
For a complete walkthrough of joining, moderating and reacting to room activity from code, see our guide on how to join and control the embedded video conference with the Digital Samba SDK. And if your backend needs to know about room events too, you can use webhooks to integrate Digital Samba into your platform.
If your website runs on WordPress, you can embed GDPR-compliant video calls without touching the API at all, using the free Digital Samba Embedded WordPress plugin. The rooms it creates are the same Digital Samba rooms, with screen sharing, chat and virtual backgrounds included.
The setup takes a few minutes:
If you're new to shortcodes, the WordPress documentation explains how to place them. For anything beyond simple embedded rooms – custom join flows, tokens per user, event handling – switch to the API and SDK route described above.
You now have the full picture: create a room through the REST API, issue tokens for private access, embed the interface with an iframe or the SDK, and customise the experience with roomSettings, events and methods. Developers get full programmatic control, and WordPress users get a no-code path to the same GDPR-compliant rooms.
Ready to bring real-time video to your platform?
Start building with Digital Samba today, or talk to our team about the best way to integrate video conferencing into your website.
An embedded video conferencing API lets you add real-time video calls directly to your website or app without building WebRTC infrastructure yourself. You use the API to create and manage rooms on the backend, and an SDK or iframe to display the video interface on the frontend.
Create a room via the Digital Samba REST API, generate a participant token if the room is private, then load the prebuilt video interface with the JavaScript SDK or a simple iframe. No WebRTC development is required, and a basic embed can be live in under an hour.
The fastest way is an iframe embed. Create a public room, paste an iframe with the room URL into your HTML, and the call interface loads on your page with no development work.
A video conferencing API manages backend tasks such as creating rooms and setting participant roles, while the SDK controls the frontend, including how the call looks and behaves on your site. Most integrations use both together. We unpack the distinction in our API vs SDK guide.
You need your Team ID and Developer key, both shown in the Team section of the Digital Samba dashboard. The Developer key authenticates your REST API requests and signs participant tokens, so keep it on your server and never expose it in frontend code.
Yes. Digital Samba has a free plan that includes 10,000 participation minutes per month, with no card required, so you can build and test the API and SDK before scaling. Current plans are listed on the pricing page.
Yes. Digital Samba provides an official WordPress plugin that adds fully functional video rooms to any page or post using shortcodes, with no coding required. It connects with the same Team ID and Developer key used by the API.
Yes. Digital Samba is a European provider and hosts meeting data on EU servers, with encryption in transit and at rest and optional end-to-end encryption. That makes it suitable for healthcare, education and other privacy-sensitive sectors.
A room supports up to 100 participants when everyone can broadcast, or up to 500 participants with up to 15 simultaneous broadcasters. The right configuration depends on your use case.
Yes. You can customise logos, colours and fonts, and white-label options extend to the domain your rooms run on. The SDK adds runtime control too, such as changing branding colours and the layout mode from your own code.
Yes. Pass a roomSettings object when initialising the SDK: username pre-fills the participant's name, and setting joinScreenEnabled to false skips the join screen. You can set the app language, initials and starting devices the same way.
Yes. Assign roles when creating a room and set a default_role for anyone who joins without a token. Each role defines permissions such as broadcasting, screen sharing and moderation, and you can create custom roles via the API or dashboard.
Yes. Full developer documentation is available at docs.digitalsamba.com, covering the REST API, the JavaScript SDK, webhooks and code examples in multiple languages.