Skip to content

1.0.29

Choose a tag to compare

@nums nums released this 28 Nov 18:53
· 16 commits to main since this release
a92f3ba

Add new methods :

  • Get current live channels of your space
$blastream->getCurrentLiveChannels();
  • Get all channels of your space
$blastream->getChannels();
  • Create a RTMP channel
$channel = $blastream->createOrGetChannel('my-rtmp-channel');
$channel->setMode('rtmp');
  • Upload a file from an url and automatically add to the blastream document library of the channel
$channel = $blastream->createOrGetChannel('my-channel');
$channel->uploadFromUrl('https://.........'); //can be jpg, png, pdf, mp4, avi (any extension of video)

Add banners feature :

  • Create a channel and enable banner module
$channel = $blastream->createOrGetChannel('my-channel-with-banners');
$channel->setBannerModule(1);
  • Create your first banner
$upload = $channel->uploadPic('banner_test.jpg');
$bannerData = [
   'name' => 'banner name',
   'title' => 'My awesome banner',
   'text' => 'Lorem ipsum is so cool !',
   'btn' => 'KNOW MORE',
   'media_url_live' => $upload['file'], //if banner live
   'media_url_chat' => $upload['file'], //if banner chat (can be both)
   'link' => 'https://www.mywebsite.com',
   'qty_available' => 50,
   'show_qty' => true,
   'show_timer' => true,
   'price' => 99,
   'show_price' => true,
   'timer' => 200,
   'gong' => true
];
$channel->createBanner($bannerData);
  • Get all banners
$channel->getBanners()
  • Get banner
$channel->getBanner($bannerId)
  • Update banner
$channel->updateBanner($bannerId, $bannerData)
  • Remove banner
$channel->removeBanner($bannerId)
  • Get banners logs
$channel->getBannerLogs()