diff --git a/README.md b/README.md
index 832f9aa..b46474c 100644
--- a/README.md
+++ b/README.md
@@ -10,6 +10,7 @@
**Radio is an application with a minimalist approach to listening to radio over the Internet.**
**Radio only offers a very basic search option, and it imports audio streaming links when you tap them in a web browser.**
**Radio now also supports Android TV and Cast to Devices (Beta) with the Version 14.5 and above.**
+**New Feature Update: Web Control with API for devs.**
**Pull request are welcome at any time.**
**Radio is free software. It is released under the [GPLv3 open source license](https://opensource.org/licenses/GPL-3.0).**
@@ -91,7 +92,6 @@ You can help out the radio-browser.info community by [adding the missing station
When **Edit Stations** is enabled:
- Press **← (Left)** on the remote to open the detailed station editing area
-- Press **3** or **Back** to close the editing area
**General TV** Controls:
- Press **0** or **DEL** to remove the selected radio station
diff --git a/SECURITY.md b/SECURITY.md
index 71b80b8..54e95ca 100644
--- a/SECURITY.md
+++ b/SECURITY.md
@@ -18,9 +18,9 @@ We appreciate responsible disclosure and will credit researchers who report vali
## Supported Versions
| Version | Supported |
-| ------- | ------------------ |
-| > 14.5 | :white_check_mark: |
-| < 14.5 | :x: |
+|---------| ------------------ |
+| > 15 | :white_check_mark: |
+| < 15 | :x: |
Only the latest stable release receives security updates. Users on older versions are encouraged to update.
diff --git a/app/build.gradle.kts b/app/build.gradle.kts
index 2f31802..69a735e 100644
--- a/app/build.gradle.kts
+++ b/app/build.gradle.kts
@@ -1,5 +1,6 @@
plugins {
alias(libs.plugins.android.application)
+ alias(libs.plugins.kotlin.serialization)
id("kotlin-parcelize")
}
@@ -22,12 +23,12 @@ android {
buildFeatures {
buildConfig = true
+ viewBinding = true
}
buildTypes {
debug {
isMinifyEnabled = false
- //noinspection NotShrinkingResources
isShrinkResources = false
isCrunchPngs = false
proguardFiles.addAll(listOf(getDefaultProguardFile("proguard-android-optimize.txt"), file("proguard-rules.pro")))
@@ -36,8 +37,8 @@ android {
}
release {
- isMinifyEnabled = true
- isShrinkResources = true
+ isMinifyEnabled = false
+ isShrinkResources = false
isCrunchPngs = true
proguardFiles.addAll(listOf(getDefaultProguardFile("proguard-android-optimize.txt"), file("proguard-rules.pro")))
buildConfigField("boolean", "IS_DEBUG_ENABLED", "false")
@@ -52,6 +53,13 @@ android {
version = "3.22.1"
}
}
+
+ packaging {
+ resources {
+ excludes += "/META-INF/INDEX.LIST"
+ excludes += "/META-INF/io.netty.versions.properties"
+ }
+ }
}
dependencies {
@@ -78,6 +86,13 @@ dependencies {
implementation(libs.freedroidwarn)
+ // Ktor //
+ implementation(libs.ktor.server.core)
+ implementation(libs.ktor.server.netty)
+ implementation(libs.ktor.server.content.negotiation)
+ implementation(libs.ktor.serialization.kotlinx.json)
+ implementation(libs.ktor.serialization.gson)
+
// Volley HTTP request //
implementation(libs.volley)
implementation(libs.material3)
diff --git a/app/src/main/assets/web/favicon.png b/app/src/main/assets/web/favicon.png
new file mode 100644
index 0000000..ade7dcd
Binary files /dev/null and b/app/src/main/assets/web/favicon.png differ
diff --git a/app/src/main/assets/web/index.html b/app/src/main/assets/web/index.html
new file mode 100644
index 0000000..443b5be
--- /dev/null
+++ b/app/src/main/assets/web/index.html
@@ -0,0 +1,176 @@
+
+
+
The Radio app provides a REST API to control playback and query information.
+ +/api/statusReturns current playback status.
+
+{
+ "isPlaying": true,
+ "playWhenReady": true,
+ "playbackState": 3,
+ "currentStationUuid": "fc080549-...",
+ "metadata": "Artist - Title",
+ "starred": true
+}
+ /api/stationsReturns all stations in collection.
+
+[
+ {
+ "uuid": "fc080549-...",
+ "name": "Station Name",
+ "hasImage": true,
+ "starred": true
+ }
+]
+ /api/image/{uuid}Returns the image for a specific station.
+/api/configReturns the app version.
+{ "version": "15.1" }
+ /api/play/{uuid}Starts playback of a specific station.
+{ "status": "ok" }
+ /api/pausePauses current playback.
+{ "status": "ok" }
+ /api/resumeResumes current playback.
+{ "status": "ok" }
+ /api/nextPlays the next station.
+{ "status": "ok" }
+ /api/prevPlays the previous station.
+{ "status": "ok" }
+