Webkul
Services
Technologies Bagisto QloApps
iOS Android SAP BigCommerce Wix
Trusted by
Samsung Intel Toyota Walmart Disney Nokia Nestlé Decathlon
See all customers
Back to Top
DOC

Guide for Bagisto Marketplace Live stream

The Bagisto Marketplace Live Stream module lets marketplace sellers run live video broadcasts. Also, sellers can showcase products during the stream and talk to viewers through real-time chat.

First, the admin and the sellers invite influencers and schedule streams for them. Then, the influencers go live from their customer account, and the module records each broadcast for replay. Meanwhile, guests can watch the live streams, and logged-in customers can chat and buy the showcased products.

In addition, customers can view the live, upcoming, and previous streams from the Live Stream page of the store.

Note – Bagisto Marketplace Live Stream is an add-on for the Laravel Multi Vendor Marketplace. So, you must install that extension before you use this module.

Features of Bagisto Marketplace Live Stream

  • The store admin and the sellers can invite unlimited influencers.
  • For a new influencer, the module creates a customer account. Otherwise, it links the existing customer account.
  • A new influencer gets a temporary password in the invitation email only, and the module does not store it afterwards.
  • Admin and sellers can create and schedule streams for their influencers.
  • The admin can attach any product to a stream. However, a seller can attach only their own products and the admin products they offer.
  • Anyone who created a stream can edit it until it starts.
  • Influencers manage a public profile with a logo, banner, description, and social links.
  • Influencers go live from their customer account, and the module records the broadcast for replay.
  • Guest customers can watch the live streams.
  • Logged-in customers can also chat in real time while the stream is live.
  • Sellers can showcase their products during a live stream, so customers can buy them right away.
  • Admin can set the STUN/TURN server details and the stream clip duration from the admin panel.
  • Moreover, the module works on MySQL 8.0, MariaDB 10.11, and PostgreSQL 16.

Requirements

Before you install Bagisto Marketplace Live Stream, check that your server has the following:

  • Bagisto: v2.5.0
  • Bagisto Marketplace: v2.5.0.0
  • Redis: apt install redis-server
  • Bagisto Marketplace Live Stream Installation

    Step 1: First, unzip the extension zip. Then, merge the “packages” folder into the project root directory.

    Bagisto Marketplace Live Stream installation

    Step 2: Next, open the root composer.json file and add this line under autoload.psr-4:

"Webkul\\MarketplaceLiveStream\\": "packages/Webkul/MarketplaceLiveStream/src"

Step 3: After that, regenerate the autoloader:

composer dump-autoload

Step 4: Now, open the bootstrap/providers.php file (not config/app.php). Then, add the service provider after the Marketplace service provider:

Webkul\MarketplaceLiveStream\Providers\MarketplaceLiveStreamServiceProvider::class,

Step 5: Next, install the runtime packages and run the installer:

composer require predis/predis
composer require pbmedia/laravel-ffmpeg
php artisan livestream:install
php artisan optimize:clear

The livestream:install command migrates the module tables and moves old images into the current folders. Also, it publishes the assets and clears the cache.

Step 6: After that, open the .env file and set the broadcast and queue connections to Redis. Note that Bagisto v2.5 uses BROADCAST_CONNECTION instead of the old BROADCAST_DRIVER.

BROADCAST_CONNECTION=redis
QUEUE_CONNECTION=redis
REDIS_HOST=127.0.0.1
REDIS_PORT=6379

Step 7: Finally, copy laravel-echo-server.json to the project root and set your own values. Then, start the socket server and a queue worker:

laravel-echo-server start
php artisan queue:work

Note: The store admin must install and configure a TURN/STUN server. Also, keep the socket server and the queue worker running with a process manager such as Supervisor or pm2.

If you upgrade from v2.4.x, follow the UPGRADE.md file that comes with the module.

Real-time Setup for Live Stream Chat

The storefront connects with Laravel Echo over Socket.IO. Then, the laravel-echo-server sends the Laravel broadcasts to the viewers through Redis.

Bagisto v2.5 no longer ships a redis broadcast connection. So, the module adds its own. However, a redis entry in your config/broadcasting.php file takes precedence.

Next, set these values in laravel-echo-server.json:

  • authHost – your store URL, for example https://your-domain.com. The socket server uses it to check presence channels.
  • apiOriginAllow.allowOrigin – your store origin (CORS).
  • databaseConfig.redis.keyPrefix – it must match the Laravel Redis prefix. By default, Laravel builds it from APP_NAME as bagisto_database_. Otherwise, the broadcasts never reach the viewers.
  • Keep protocol: “http” and port: “6001” when a reverse proxy handles TLS in front of the socket server. Also, do not expose port 6001 to the public.

The /broadcasting/auth route must return 200, not 419. Otherwise, the chat and the video will not work. For this reason, the module skips the request forgery check on this route, because the socket server calls it from the server side.

Note: Keep the laravel-echo-server running at all times. If it stops, all real-time features stop too.

Recording Setup (Optional)

Live viewing works without FFmpeg. However, you need FFmpeg to record the streams for replay.

  • First, install FFmpeg and make sure it is on the server PATH.
  • Then, raise the PHP upload limits for the video clips. For example, set upload_max_filesize and post_max_size to 64M. Also, raise any proxy or CDN request-size limit.

Bagisto Marketplace Live Stream Admin Configuration

After you install the module, go to Configuration >> Live Stream >> Server Settings in the admin panel.

Bagisto Marketplace Live Stream admin configuration

General

Status- Turn the Live Stream module on or off for the channel.

Note: The module menus appear only when you turn on both the Live Stream status and the Marketplace status. After you change the status, run php artisan optimize:clear. Otherwise, the cached configuration hides the menu change.

STUN Server

URL- Enter the STUN server URL. You need it when the STUN server is active.

Active- Turn the STUN server on or off.

TURN Server

URL- Enter the TURN server URL. You need it when the TURN server is active.

Username- Enter the TURN server username.

Credential- Enter the TURN server credential.

Active- Turn the TURN server on or off.

Note: STUN is enough when the influencer and the viewers share one network. However, viewers on other networks or on mobile data need a TURN server.

Stream Clip Duration

Duration- Set the length of each recorded clip in seconds. For best results, use at least 15 seconds. If you set 0, the module uses the default of 30 seconds.

Finally, click the Save button.

Admin – Invite Influencers

To manage influencers, go to Live Stream >> Influencers. Then, click the Invite button in the top-right corner.

Bagisto Marketplace Live Stream influencers page

Next, a popup opens. Enter the first name, last name, and email of the influencer, and click Invite.

invite influencers

If no customer account exists for the email, the module creates one. In that case, it sends the temporary password in the invitation email. Otherwise, it links the existing account. As a result, the influencer appears in the list.

saved influencers list

Admin – Create Streams

To manage streams, go to Live Stream >> Streams. Then, click the Add Stream button in the top-right corner.

Bagisto Marketplace Live Stream streams list
add stream form

Add Stream

Title- Enter the title of the stream. You must fill this field.

Description- Enter a short description of the stream. You must fill this field too.

Scheduled Date- Pick the date and time when the stream starts.

Influencer- Select the influencer who runs the stream.

Media- Upload the stream thumbnail in bmp, jpeg, jpg, png, or webp format.

Products- Select the products to showcase during the stream. Here, the admin can select any product.

Then, click Save. Now the stream appears in the list with the Pending status. Also, you can edit the stream until it starts.

added stream

Seller View – Bagisto Marketplace Live Stream

Sellers get the Influencers and Streams options in the sidebar of their dashboard.

Bagisto Marketplace Live Stream seller dashboard

To add an influencer, open Influencers and click the Invite button.

seller influencers page

Next, enter the first name, last name, and email of the influencer. After that, click Invite.

seller invite influencer

To create a stream, open Streams and click the button to add a new stream.

seller add stream

Then, fill in the title, description, scheduled date, influencer, thumbnail, and products. However, a seller can select only their own products and the admin products they offer.

seller edit stream

Finally, save the form. As a result, the stream appears in the list with the Pending status.

seller created stream

Influencer View – Go Live

First, the influencer logs in with their customer account. Then, two options appear in the account menu: Manage Influencer Profile and Streams.

Bagisto Marketplace Live Stream influencer profile

Under Manage Influencer Profile, the influencer edits the title, URL, description, logo, and banner. Also, they can add social links for Twitter, Facebook, YouTube, Instagram, and Pinterest. Anyone can open this profile at /live-stream/{profile-url}.

edit influencer profile

Under Streams, the influencer sees each assigned stream with its Pending or Completed status.

influencer streams list

To start a stream, click the eye icon in the Action column. Then, click the Go Live button and allow camera and microphone access in the browser.

Bagisto Marketplace Live Stream go live

During the stream, its status shows as live. Also, the influencer sees the viewer count next to the eye icon. Meanwhile, the module records the broadcast in clips of the set duration.

To end the stream, click the Stop Broadcast button and confirm.

stop broadcast

After that, the stream shows the Completed status.

completed stream

Watch Bagisto Marketplace Live Stream on the Storefront

Customers and guests open the Live Stream page (/live-stream) from the top of the store. There, they see the live, upcoming, and previous streams.

Bagisto Marketplace Live Stream storefront page

Next, click a live stream to watch it. Guests can watch the video. In addition, logged-in customers can chat with the influencer while the stream is live.

customer watching live stream

The stream products show next to the video. So, customers can click a product to open it and buy it.

For an upcoming stream, the page shows the start date and time. Once a stream ends, it moves to the previous streams. Then, customers can watch the recorded replay.

stream replay

Usage Flow

  1. First, the admin or a seller invites an influencer.
  2. Then, they create a stream, assign the influencer, set the schedule, and add products.
  3. Next, the influencer logs in and goes live from My Account >> Streams.
  4. Finally, customers and guests open /live-stream, watch the video, chat, and buy the products.

Troubleshooting

  • Live Stream menus do not appear: turn on both the Live Stream status and the Marketplace status. Then, run php artisan optimize:clear.
  • Chat or video does not load: check that laravel-echo-server and the queue worker run. Also, check that /broadcasting/auth returns 200 and that both Redis prefixes match.
  • Viewers on other networks see a black screen: set up and turn on a TURN server.
  • Replay is missing: check that FFmpeg is on the server PATH. Also, check that the PHP upload limits fit the video clips.

So, that was all about the Bagisto Marketplace Live Stream module. If you have any queries, raise a ticket at our HelpDesk System.

Also, explore our Laravel Development Services and quality Bagisto Extensions.

Current Product Version - v2.5.0

Supported Framework Version - Bagisto v2.5.0

Blog Version - Bagisto v2.5.0
  • Version v2.2.2
  • Version Bagisto v2.5.0
. . .

Leave a Comment

Your email address will not be published. Required fields are marked*


Be the first to comment.

Back to Top

Message Sent!

If you have more details or questions, you can reply to the received confirmation email.

Back to Home
IN THIS ARTICLE

Table of Content

Back to top