# UnknownDeVPN
**Simple & beautiful V2Ray VPN client for Android**
Built with Jetpack Compose + v2raylibs
---
## What v2raylibs needs to work
### 1. Config JSON
You **must** send a valid V2Ray outbound JSON.
**Name of the extra:** `CoreService.EXTRA_CONFIG_JSON`
Example (used in this app):
```json
{
"tag": "proxy",
"protocol": "vless",
"settings": {
"vnext": [{
"address": "SERVER_IP",
"port": 8080,
"users": [{
"id": "UUID",
"encryption": "none",
"flow": ""
}]
}]
},
"streamSettings": {
"network": "xhttp",
"xhttpSettings": {
"path": "/your-path"
}
}
}You can change the server, port, UUID, etc.
val intent = Intent(this, CoreService::class.java).apply {
action = CoreService.ACTION_START
putExtra(CoreService.EXTRA_CONFIG_JSON, getV2rayConfig()) // your JSON string
putExtra(CoreService.EXTRA_PROFILE_NAME, "UnknownDeVPN")
}
ContextCompat.startForegroundService(this, intent)val intent = Intent(this, CoreService::class.java).apply {
action = CoreService.ACTION_STOP
}
startService(intent)val isRunning = CoreService.isActive // BooleanAlways check and request permission before starting:
val intent = VpnService.prepare(this)
if (intent != null) {
prepareLauncher.launch(intent) // ActivityResultLauncher
} else {
startVpnService()
}The app automatically asks for:
Manifest.permission.POST_NOTIFICATIONSThis is required to show the VPN notification.
- User taps Power button
- Checks notification permission (Android 13+)
- Calls
VpnService.prepare() - Starts
CoreServicewith the JSON - Shows "CONNECTING..." → "CONNECTED" + live timer
- Tap again to stop
Everything is already implemented in MainActivity.kt.
CoreService must be declared as foreground service (already done in the library).
Ready to use. Just replace the JSON with your own server and you're good to go.
Made with ❤️ by UnknownDeVPN