Skip to main content

Build with MediaSFU Expo

Essential next steps​

Use mediasfu-reactnative-expo@2.5.5 in Expo-managed React Native applications.

You can begin locally with restricted development credentials. Before sharing or releasing the app, move reusable Cloud credentials behind the production credential boundary.

npm install mediasfu-reactnative-expo@2.5.5

Build by operation​

TaskStart here
Secure room authority and callback boundariesExpo room operations
Prepare media, start microphone/camera, consume media, screen share, and leaveExpo operation table
Waiting, requests, moderation, and collaborationExpo collaboration
Device and failure recoveryRecovery and media controls
Rendered media responsibilitiesScreen and rendered media
Build a familiar call productProduct recipes
Check exact declarationsExpo API reference

Copy/paste starter​

import type { JoinRoomOnMediaSFUType } from 'mediasfu-reactnative-expo';

export const joinMediaSFURoom: JoinRoomOnMediaSFUType = async ({ payload }) => {
const response = await appFetch('https://api.example.test/rooms/join', {
method: 'POST',
headers: { 'Content-Type': 'application/json' },
body: JSON.stringify(payload),
});
if (!response.ok) throw new Error(`Join failed: ${response.status}`);
return response.json();
};

The prebuilt create/join screen in this package version still expects its credential-shaped configuration before calling the custom callback. Do not put a reusable MediaSFU key in an Expo bundle to satisfy that screen. Use the application-backend handoff explained in the linked guide.

Before release​

Use physical devices to verify native permissions, microphone, camera, remote audio/video, screen sharing, app backgrounding, reconnect, leave, and cleanup. Repeat the call twice to catch stale state or tracks left by the first session.