diff --git a/WebFlix/build.gradle.kts b/WebFlix/build.gradle.kts
new file mode 100644
index 0000000..956eb3b
--- /dev/null
+++ b/WebFlix/build.gradle.kts
@@ -0,0 +1,26 @@
+// use an integer for version numbers
+version = 1
+
+
+cloudstream {
+ // All of these properties are optional, you can safely remove them
+
+ description = "Adds multiple sites using WebFlix. This includes sites in English, Polish, Portuguese and Arabic"
+ authors = listOf("Cloudburst")
+
+ /**
+ * Status int as the following:
+ * 0: Down
+ * 1: Ok
+ * 2: Slow
+ * 3: Beta only
+ * */
+ status = 1 // will be 3 if unspecified
+ tvTypes = listOf(
+ "Movies",
+ "TvSeries",
+ "Live"
+ )
+
+ iconUrl = "https://raw.githubusercontent.com/recloudstream/cloudstream-extensions-multilinugal/master/WebFlix/icon.png"
+}
diff --git a/WebFlix/icon.png b/WebFlix/icon.png
new file mode 100644
index 0000000..0bd09f7
Binary files /dev/null and b/WebFlix/icon.png differ
diff --git a/WebFlix/src/main/AndroidManifest.xml b/WebFlix/src/main/AndroidManifest.xml
new file mode 100644
index 0000000..29aec9d
--- /dev/null
+++ b/WebFlix/src/main/AndroidManifest.xml
@@ -0,0 +1,2 @@
+
+
\ No newline at end of file
diff --git a/WebFlix/src/main/kotlin/com/lagradost/WebFlixProvider.kt b/WebFlix/src/main/kotlin/com/lagradost/WebFlixProvider.kt
new file mode 100644
index 0000000..0eb0366
--- /dev/null
+++ b/WebFlix/src/main/kotlin/com/lagradost/WebFlixProvider.kt
@@ -0,0 +1,222 @@
+package com.lagradost
+
+import android.util.Base64
+import android.util.Log
+import com.lagradost.WebFlixProvider.Companion.toHomePageList
+import com.lagradost.cloudstream3.*
+import com.lagradost.cloudstream3.utils.AppUtils.toJson
+import com.lagradost.cloudstream3.utils.AppUtils.tryParseJson
+import com.lagradost.cloudstream3.utils.ExtractorLink
+import com.lagradost.cloudstream3.utils.Qualities
+import com.lagradost.cloudstream3.utils.loadExtractor
+import java.net.URLEncoder
+
+
+class WebFlixProvider(override var lang: String, override var mainUrl: String, override var name: String, override val supportedTypes: Set) : MainAPI() {
+ val magicPath = base64Decode("NEY1QTlDM0Q5QTg2RkE1NEVBQ0VEREQ2MzUxODUvZDUwNmFiZmQtOWZlMi00YjcxLWI5NzktZmVmZjIxYmNhZDEzLw==")
+ override val hasMainPage = true
+ override val hasChromecastSupport = true
+
+ override suspend fun getMainPage(
+ page: Int,
+ request : MainPageRequest
+ ): HomePageResponse? {
+ val res = tryParseJson(app.get("$mainUrl/api/first/$magicPath").text) ?: return null
+ return HomePageResponse(
+ res.getHomePageLists(this),
+ false
+ )
+ }
+
+ override suspend fun search(query: String): List? {
+ val res = tryParseJson(app.get("$mainUrl/api/search/${query.encodeUri()}/$magicPath").text) ?: return null
+ return res.posters.map { it.toSearchResponse(this) }
+ }
+
+ override suspend fun load(url: String): LoadResponse? {
+ val data = tryParseJson(app.get(url).text) ?: return null
+ return data.toLoadResponse(this)
+ }
+
+ override suspend fun loadLinks(
+ data: String,
+ isCasting: Boolean,
+ subtitleCallback: (SubtitleFile) -> Unit,
+ callback: (ExtractorLink) -> Unit
+ ): Boolean {
+ val sources = tryParseJson>(data) ?: return false
+ sources.forEach {
+ it.load(subtitleCallback, callback)
+ }
+ return true
+ }
+
+ private data class ApiSearchResponse(
+ val posters: List
+ )
+
+ private data class HomeResponse(val genres: List, val channels: List, val slides: List) {
+ fun getHomePageLists(provider: WebFlixProvider): List {
+ val lists = mutableListOf()
+ if (channels.isNotEmpty()) {
+ channels.forEach {
+ if (it.type == null) it.type = "channel"
+ }
+ lists.add(channels.toHomePageList("Channels", provider))
+ }
+ if (slides.isNotEmpty()) lists.add(slides.toHomePageList("Slides", provider))
+ lists.addAll(genres.map { it.toHomePageList(provider) })
+ return lists
+ }
+ }
+ private data class HomeReponseGenre(
+ val title: String,
+ val posters: List
+ ) {
+ fun toHomePageList(provider: WebFlixProvider) = posters.toHomePageList(title, provider)
+ }
+
+ data class Source(
+ val title: String?,
+ val url: String?,
+ val quality: String?,
+ ) {
+ suspend fun load(subtitleCallback: (SubtitleFile) -> Unit, callback: (ExtractorLink) -> Unit) {
+ if (url == null) return;
+ when (url.split(".").last()) {
+ "mp4", "m3u8", "mov" -> callback.invoke(
+ ExtractorLink(
+ quality ?: "",
+ title ?: "",
+ url,
+ "",
+ Qualities.Unknown.value,
+ isM3u8 = (url.endsWith("m3u8"))
+ ))
+ else -> loadExtractor(url, subtitleCallback, callback)
+ }
+ }
+ }
+
+ private data class ApiEpisode(
+ val id: Int,
+ val title: String?,
+ val description: String?,
+ val sources: List