Skip to content

Introduction

Welcome to Lunar Stream - a professional live streaming platform designed for seamless integration into your applications.

What is Lunar Stream?

Lunar Stream provides enterprise-grade live streaming infrastructure with:

  • RTMP Ingestion - Accept streams from OBS, FFmpeg, mobile apps, and any RTMP-compatible encoder
  • HLS Delivery - Deliver streams with Adaptive Bitrate (ABR) for optimal viewing experience
  • Multi-CDN Support - Built-in support for BunnyCDN and Gcore with automatic failover
  • API-First Design - RESTful API for complete programmatic control

Architecture Overview

┌─────────────────────────────────────────────────────────────────────────┐
│                        PARTNER APPLICATION                               │
├─────────────────────────────────────────────────────────────────────────┤
│  ┌──────────────┐    ┌──────────────┐    ┌──────────────────────────┐  │
│  │ Partner      │    │ Partner      │    │ Partner Mobile/Web App   │  │
│  │ Backend      │───▶│ Database     │    │ (HLS Player)             │  │
│  │ (Node/Python)│    │              │    │                          │  │
│  └──────┬───────┘    └──────────────┘    └────────────▲─────────────┘  │
│         │                                              │                │
│         │ API Key Auth                                 │ HLS Stream     │
│         ▼                                              │                │
├─────────────────────────────────────────────────────────────────────────┤
│                        LUNAR STREAM PLATFORM                             │
├─────────────────────────────────────────────────────────────────────────┤
│  ┌──────────────┐    ┌──────────────┐    ┌──────────────────────────┐  │
│  │ Lunar Stream │    │ Media Server │    │ CDN (BunnyCDN/Gcore)     │  │
│  │ API          │───▶│ (ZLMediaKit) │───▶│                          │  │
│  │              │    │              │    │                          │  │
│  └──────────────┘    └──────┬───────┘    └──────────────────────────┘  │
│                             │                                           │
│                             │ RTMP                                      │
│                             ▼                                           │
│                    ┌──────────────┐                                     │
│                    │ Broadcaster  │                                     │
│                    │ (OBS/Mobile) │                                     │
│                    └──────────────┘                                     │
└─────────────────────────────────────────────────────────────────────────┘

Getting Started

As a partner, you will receive from Lunar Stream admin:

CredentialDescriptionExample
API KeyAuthentication key for API callsls_proj_v1_ydi3lLih...
Project IDYour project identifierce4b77e3-3ed0-47ee-...

TIP

Store these credentials securely in your environment variables. Never expose them in client-side code.

Integration Flow

  1. Receive Credentials

    • Get API Key and Project ID from Lunar Stream admin
  2. Create Livestream

    • Call API to create a new livestream
    • Receive stream key, push token, and HLS URLs
  3. Broadcasting

    • Broadcaster pushes RTMP stream using stream key + push token
    • Media server validates and processes the stream
  4. Playback

    • Viewers receive HLS URLs from your backend
    • Stream is delivered via Multi-CDN

Next Steps

Released under the MIT License.