<?php
include "db.php";

$result=$conn->query("SELECT * FROM menus WHERE status=1 ORDER BY id ASC");

$data=[];

while($row=$result->fetch_assoc()){

$data[]=[
"type"=>$row['stream_type'],
"name"=>$row['menu_name'],
"url"=>$row['stream_url'],
"enabled"=>true
];

}

echo json_encode($data);
?>