mirror of
https://github.com/MHSanaei/3x-ui.git
synced 2026-12-03 21:18:19 +07:00
[GH-ISSUE #6715] [Feature]: Serve Xray JSON only for expired/depleted Happ subscriptions #4474
Labels
No labels
backlog
bug
clarification needed
documentation
duplicate
enhancement
github_actions
good first issue
invalid
javascript
New Feature
PR welcomed
pull-request
question
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
MHSanaei/3x-ui#4474
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @Fiksit on GitHub (Oct 1, 2026).
Original GitHub issue: https://github.com/MHSanaei/3x-ui/issues/6715
Is your feature request related to a problem?
Yes.
In 3x-ui v3.8.5, the "Separate info config / dummy node" feature works well for showing an informational node when a subscription expires.
However, on mobile Happ (Android/iOS), when an expired subscription contains only the dummy SOCKS node in the normal raw/Base64 format, Happ may return "Unknown content type".
The workaround is to enable Xray JSON auto-detection for Happ using:
(?i)\bhapp\bThis makes the expired dummy node work, but then all active Happ subscriptions are also returned as JSON.
For active JSON servers in Happ, TCP ping may show N/A, while "Via Proxy (GET)" works normally and the servers themselves connect and work.
Describe the solution you'd like
Please add an option to return Xray JSON only when the subscription is expired or traffic-depleted, while keeping the normal raw/Base64 format for active subscriptions.
Desired behavior for Happ on the same subscription URL:
A possible UI option could be:
Use JSON only for expired/depleted subscriptionsor
Auto-detect JSON only when expired/depletedAlternatives you've considered
Currently I use JSON auto-detection for Happ with:
(?i)\bhapp\bThis fixes the expired dummy node on mobile Happ, but forces all active servers into JSON format.
Another workaround would be a custom build of 3x-ui that checks the subscription state before selecting JSON, but maintaining a custom binary after every update is inconvenient.
Concrete use case
I provide one subscription URL to users.
While the subscription is active, Happ should receive normal VLESS/Hysteria links so TCP ping and normal server handling work as usual.
When the subscription expires, the same URL should automatically return a JSON dummy node such as:
⛔ Subscription expired: {{EXPIRE_DATE}}This allows the user to clearly see that the subscription has expired without changing the subscription URL.
Mockups, screenshots, or examples
Environment:
(?i)\bhapp\bWhich parts of the panel would this affect?
Subscription (share links / Clash / JSON)
Are you willing to help?
Before submitting