라이브 스트리밍
호스트가 영상으로 라이브를 하면 시청자가 보고, 채팅하고, 선물을 보내고, 하트를 누릅니다. 국가, 친구, 팔로우 목록, 게스트 자리, 스트림 관리자와 신고. PK와 뷰티 필터는 애드온입니다.
مروان القحطاني 제작최초 게시 2026. 11. 29.최종 업데이트 2026. 12. 1.
이 기능에 대하여
호스트가 영상으로 라이브를 하면 시청자가 보고, 채팅하고, 선물을 보내고, 하트를 누릅니다. 국가, 친구, 팔로우 목록, 게스트 자리, 스트림 관리자와 신고. PK와 뷰티 필터는 애드온입니다.
하는 일
- 라이브 시작: 호스트가 제목, 소개, 커버 사진으로 방송을 시작합니다(호스트당 방송 하나). 호스트가 실제로 영상을 게시해야 라이브 목록에 나타나며, 진행 중에도 수정할 수 있습니다(제목, 소개, 커버, 채팅 탭 켜기 또는 끄기). 호스트는 언제든 방송을 끝낼 수 있고 합계는 저장됩니다. 패널의 차단 엔진에서 사용자가 방송을 열거나 들어오지 못하도록 차단할 수 있습니다.
- 시청: 시청자가 방송에 들어가 영상을 보고, 채팅에 쓰고, 선물을 보냅니다(일반 선물과 럭키 선물은 같은 선물 시스템을 통해 방송으로 갑니다). 들어가면 앱은 호스트의 프로필(이름, 사진, VIP와 ID), 하트 합계, 방송의 다이아몬드, 관리자와 권한, 게스트 자리, 그리고 다른 기능이 추가한 정보를 가져옵니다. 방송은 새 시청자에게 닫을 수 있습니다.
- 목록: 메인 목록에는 지금 방송 중인 것만 표시되며, 15개씩 페이지로 나뉘고(최대 30), 고정된 것, 인기 순으로 정렬되며, 가장 많이 본 순(trend)으로 정렬하거나 호스트의 국가로 거를 수 있습니다. 추가 목록: 라이브 중인 친구, 팔로우하는 사람 중 라이브 중인 사람, 그리고 열린 방송이 있는 국가와 그 수를 보여 주는 국가 목록. 각 방송 카드는 제목, 커버, 호스트, 시청자, 이번 세션과 전체에서 번 다이아몬드를 보여 줍니다.
- 하트: 시청자가 하트를 누르면 군중이 얼마나 많든 모두가 매초 하나의 누적 합계를 봅니다. 자동 클릭 방지가 있습니다(사람당 초당 5번, 분당 120건의 요청). 방송이 끝나면 합계가 저장됩니다. 각 시청자는 방송마다 한 번 집계되며, 호스트는 자기 방송의 시청자로 집계되지 않습니다.
- 게스트와 관리자: 방송에는 무대의 게스트 자리가 있고(각각 위치, 그 자리의 사용자, 상태가 있음), 소유자는 선택한 권한으로 스트림 관리자를 임명, 변경 또는 해제할 수 있습니다(관리자 수에는 한도가 있습니다). 모든 변경은 즉시 시청자에게 전달됩니다.
- 신고: 시청자는 방송 안의 사람을 신고할 수 있습니다(자기 자신은 안 됨): 유형(기능 문제, 제안, 충전 또는 기타), 10~2000자의 세부 내용, 선택 사항인 사진. 사람마다 분당 최대 5건입니다. 패널에는 읽기 전용 Live Reports 화면이 있습니다. 차단은 별도이며 채팅과 차단 엔진을 통해 이루어집니다.
- 관리 패널: Live Rooms 화면(관리자와 국가가 관리하며, 지역은 읽기 전용), Live Reports 화면, Third Party Settings 아래 비디오 엔진 키를 위한 Live Broadcast Settings 탭, 그리고 대시보드의 라이브 수치(지역별 방송, 활성, 비활성, 지금 시청자가 있는 방송). 화면마다 고유한 권한(보기, 표시, 수정, 삭제, 생성)이 있으며, 기본적으로 관리자 직책에 부여됩니다.
- 파일: 커버는 파일 내용에서 시스템이 인식하는 모든 사진을 받습니다(PNG, JPG, GIF, BMP, TIFF, WebP). 신고 사진도 이미지입니다. 라이브 영상 자체는 UTD Stream 엔진이 전달하며, 파일로 업로드하지 않습니다.
- 모든 테마와 호환: 홈 화면의 Live 탭과 라이브 화면은 활성 테마의 색을 따릅니다.
- 이 기능의 가치: 라이브 영상은 선물을 수익으로 바꾸는 가장 강력한 방법입니다. 호스트는 방송하면서 선물로 벌고, 시청자는 하트, 채팅, 게스트 자리를 통해 쇼의 일부라고 느끼며, 여러분은 국가 목록, 차단, 신고, 관리자 화면으로 통제를 유지합니다.
의존 대상
기본 사용자와 영상을 전달하는 UTD Stream 엔진. 방송에 선물을 보내기 위한 선물, 호스트 시간을 위한 에이전시, 호스트 프로필에 표시되는 것을 위한 VIP와 특별 ID는 선택 사항입니다. 방송은 더 이상 음성 룸에 의존하지 않으며 자체 테이블을 가집니다.
앱 화면
옆으로 넘겨 더 보기
설치 및 제거
구매 후에는 “내 구매 내역”에서도 이 명령어를 확인할 수 있습니다.
설치
php artisan feature:install live --apply제거(데이터는 그대로 남음)
명령 하나로 기본 설정에서 기능을 끕니다(이 페이지에 표시됨). 먼저 추가 기능을 제거하세요. 라이브 목록, 하트, 신고, Live Rooms 화면이 사라지고 음성 룸은 계속 작동합니다. 제거하기 전에 진행 중인 방송을 닫으세요. 저장된 데이터는 보존되며 기능과 함께 돌아옵니다.
php artisan feature:remove live먼저 부가 기능을 제거하세요. 부가 기능이 설치된 상태에서 기능을 제거하는 것은 거부됩니다.
이 기능의 부가 기능
필요한 기능
요구 사항이 없습니다: 단독으로 설치할 수 있습니다.
설치 및 제거
이 명령어가 기능의 테이블, 관리자 패널 페이지, 권한, 설정, 기본 데이터를 준비해 줍니다. 앱에서는 기능이 알아서 제자리에 나타납니다. 기능이 앱과 관리자 패널에서 사라지지만 데이터는 그대로 남습니다. 다시 설치하면 모든 것이 이전 그대로 돌아옵니다.
구매 후에는 “내 구매 내역”에서도 이 명령어를 확인할 수 있습니다.
설치
php artisan feature:install live --apply제거(데이터는 그대로 남음)
명령 하나로 기본 설정에서 기능을 끕니다(이 페이지에 표시됨). 먼저 추가 기능을 제거하세요. 라이브 목록, 하트, 신고, Live Rooms 화면이 사라지고 음성 룸은 계속 작동합니다. 제거하기 전에 진행 중인 방송을 닫으세요. 저장된 데이터는 보존되며 기능과 함께 돌아옵니다.
php artisan feature:remove live먼저 부가 기능을 제거하세요. 부가 기능이 설치된 상태에서 기능을 제거하는 것은 거부됩니다.
이 기능을 내 기능 안에서 사용하기
The short truth: the broadcast offers other features no port, one webhook event to listen to (LiveStreamWebhookReceived, inside the feature), three FeatureCalls and six places in the app for add-ons. Never call a class inside Modules/Live directly.
Install and remove
- Install:
php artisan feature:install live --apply(without--applyit is a dry run). It creates the broadcast migrations, the menu row and permissions, and the switch closed; open it withphp artisan feature:open live. - Remove:
php artisan feature:remove live --apply. - Requires:
base:users@1,voice_rooms@^1.5.200,pk_room@^1.
Ports (server)
None. The base does not know the broadcast. Other features ask it with FeatureCalls (below) and read the relation ownerLiveStream of a user.
Events
- What the broadcast listens to:
Modules\Live\Events\LiveStreamWebhookReceived(video track: on air / stopped) andModules\VoiceRooms\Events\UtdStreamWebhookReceived. What the add-ons listen to:LiveStreamWebhookReceivedforpk_startedandpk_ended(thepk_liveadd-on). The event is synchronous inside the webhook: a listener that throws makes the webhook answer 500 and the engine retries, so write your listener idempotent. - What the broadcast emits: the realtime room message
live_taps_total(the tap total, at most once a second). No Laravel events.
Data you may read
live_tap_totals(a total per ended broadcast),live_session_viewersandf_live__streams.live_viewers_total(the running broadcast). Read only; the broadcast writes.
Slots (app): the broadcast places for add-ons (features/live/api.dart)
| Slot | What it holds |
|---|---|
liveControlSlot | a button in the broadcast control bar (the PK button) |
liveToolSlot | a camera tool in the broadcast setup and in the "More" sheet (beauty) |
liveVideoProcessorSlot | the camera processor (fresh for each capture) |
livePkConfigSlot | the PK setup for the kit (without it the kit runs without PK) |
liveSessionEndSlot | clean-up when the room closes |
liveMessageLayerSlot | a layer over the broadcast chat (a paid message flying over the broadcast and its send-refusal listener); the add-on receives LiveMessageContext{roomId, ownerId, isHost} |
Server example: a feature that listens to the start of a broadcast
use Modules\Live\Events\LiveStreamWebhookReceived;
use Illuminate\Support\Facades\Event;
// in the provider of your feature (an add-on inside the broadcast, requires live): the event belongs to the broadcast
Event::listen(LiveStreamWebhookReceived::class, function (LiveStreamWebhookReceived $w) {
if ($w->name !== 'track_published' || $w->trackType() !== 'VIDEO') {
return;
}
// $w->roomName() and $w->participantId(); it must be idempotent (the engine retries)
});Make an add-on inside the broadcast
An add-on widens the broadcast itself (like PK and beauty). Another feature that deals with the broadcast (gifts, for example) is not an add-on; it goes through a port.
Server: a module Modules/<X>/ with feature.json, module.json, FEATURE.md, CHANGELOG.md, Providers/<X>ServiceProvider.php (registers the ports and listeners and loads the migrations), Database/Migrations (additive only) and market/listing.json. In Database/Migrations add a migration settle_the_<slug>_switch_row that puts the switch row in app_features (open on a server that has data, closed on a new install, and never touching an existing row). The shape of feature.json (from the real Modules/LiveBeauty/feature.json):
{
"contract": "2.1",
"slug": "live_beauty",
"kind": "addon",
"parent": "live",
"version": "1.0.0",
"name": {"key": "live_beauty::feature.name"},
"description": {"key": "live_beauty::feature.description"},
"app_switch": "live_beauty",
"requires": ["base:users@1", "live@^1"],
"namespace": "Modules\\LiveBeauty"
}parent is live and requires must hold live@^1. Wrap your routes in appFeatureEnable:<slug> (as live_team_pk does over pk_live). After any new file run php artisan feature:catalogue <slug> --sign.
App: lib/src/features/<slug>/ with <slug>_module.dart (a FeatureModule); in registerDependencies register into the broadcast places above, with feature: '<slug>' in each InternalSlot. Add two lines to tools/features.yaml: <slug>: {enabled: true, paths: [features/<slug>], components: [], of: live} and a line under modules: for the module class. Native packages and permissions are declared in deps.yaml and native.yaml next to the module (as in features/live_beauty).
A small real example (beauty fills three places):
@override
void registerDependencies(GetIt di) {
liveVideoProcessorSlot.register(liveBeautyProcessorEntry);
liveToolSlot.register(liveBeautyToolEntry);
liveSessionEndSlot.register(liveBeautySessionEndEntry);
}Install and remove commands: server php artisan feature:install <slug> --apply and php artisan feature:remove <slug> --apply (without --apply it is a dry run); app python tools/apply_features.py --set <slug> on|off (--check when the generated files are old, --analyze-without <slug> proves the rest analyzes without it). feature:remove live refuses while an add-on is installed.
Settings, permissions and menu
- The switch: the row
app_features.live(open it withphp artisan feature:open live) decides. The app readsfeatures.livefrom the app check. - Engine settings: the keys
live.utd_stream.*(app id, server secret, callback secret, base URL), the switch "send the identity of each user to the broadcast" and the switch "show the live voice rooms on the broadcast page" (GET live/streams/optionsanswersshow_voice_rooms, which is false by itself while the voice rooms are closed). Saved from the tab "Live Broadcast Settings" in Third Party Settings. The screenlive-engine-settingsis aPOSTonly and has no menu row (declared so infeature:contractas a warning): it has noGETpage of its own, so a menu row would be a dead link. The controller itself checks the permission to save. - Old setting:
live_status(the settings table, the card "Live Feature" in the Features page; old apps read it fromVersionController). It stays until the old apps are gone; do not build on it. - Limits:
POST live/streams/tapshasthrottle:120,1and theActionAbuseGuardprotection (5 taps a second);POST live/reportshasthrottle:live-report. - Permissions (
panel_permissions, legacy, category Room):browse-live-roomsandshow-live-rooms(admin, country, region),edit-live-roomsanddelete-live-rooms(admin),create-live-rooms(country); andlive.browse-reportsfor the reports page. - Menu: the row "Live Rooms" (
uri: live-rooms, permissionbrowse-rooms) inside the section "Live Broadcast", and the row for the reports page. Three screens onlive-rooms: admin and country (without create/store) and region (read-only).
The broadcast table f_live__streams
A broadcast has its own table. The columns carry the meaning they had in rooms: id (the same id as the old room, because the engine knows the broadcast by it; a new id starts a million above any room), owner_id (was rooms.uid), numid, title (was room_name), cover (was room_cover), intro, status (1 open ... 4), is_live, is_broadcasting (the host is publishing video), live_viewers_total (unique viewers of the running broadcast), pin, is_top, hot and hour_hot (the order of the list), is_comment_closed, created_at, updated_at. The model is Modules\Live\Models\LiveStream (owner() is the host). Copy the data with php artisan live:copy-streams (dry run by default, --apply, --undo); it never touches rooms.
Before publishing (moving broadcasts to their table)
- Empty the queue before
live:copy-streams: gift and lucky jobs queued before the move carry the kindroom(the default). If the target was an old broadcast (aroomsrow of typelive), they would writesessionand the leaderboard and level rows on the oldroomsrow instead of the new broadcast. No coins or diamonds move (only counters are lost), but the queue must be empty before--apply. New jobs carryroom_kindfrom the request (target = stream). - The request from the app: a gift (normal or lucky) to a broadcast must carry
target = streamandroom_id = stream_id; without the field it goes to the room that has the same number.
UserPayload keys
App\Support\UserPayload keys this feature registers or answers (the base does not know feature names; the explanation is here). The one that asks writes the default.
- Extras place
live.stream.extras: the keys other features add to the answer of entering a broadcast (ctx['viewer']is the viewer).
FeatureCalls it answers
Small questions others ask with FeatureCalls::call (the name, who asks, what the answer is; the asker holds the default when the feature is not installed):
live.stream_of(live team PK: the running broadcast a user owns,{id, uid}, null when none or without the live feature)live.streams(live team PK: which of some stream ids run a broadcast now, stream id => owner id;[]without the live feature)live.send_command(one custom command to the engine room of a broadcast; the team PK add-on tells the people in a stream about its task)
변경 내역
1.0.1122026. 12. 1. 출시مروان القحطاني 제작
- 1.0.112: A new switch in the broadcast panel, "Show the voice rooms on the broadcast page" (Settings > Third Party > the broadcast tab > Live page), off by default; when on, the app lists the open voice rooms beside the streams on a card like a stream card, and a tap opens the room. The voice rooms page itself is unchanged.
1.0.1112026. 12. 1. 출시مروان القحطاني 제작
- 1.0.111: PK start and end events now reach the customer's server: the add-on hears them from the single webhook address, so a battle is recorded and closed in the PK battles table. Before this the PK add-on never heard these events. 1.0.110: test improvements only.
1.0.1102026. 12. 1. 출시مروان القحطاني 제작
- 1.0.110 and 1.0.109: Kick and ban review in the broadcast: the host ban is recorded before the engine is asked and restored if the engine refuses; lifting the host ban never frees the user for a moment while another ban holds him; one lock per (stream, user); the rest is tests.
1.0.1072026. 11. 29. 출시مروان القحطاني 제작
- Release 1.0.107 (signed build 5397f37)
