Changes

1,589 bytes added ,  Yesterday at 22:01
no edit summary
Line 1: Line 1: −
<pre style="background-color: #ACC8E5; color: #112A46; border-radius: 10px; padding: 10px;">
+
<pre class="header-style">This trigger will fire when a VPN (Virtual Private Network) is connected or disconnected. It monitors network connectivity changes to detect VPN state transitions.</pre>
This trigger will fire when the a VPN (Virtual Private Network) is connected/ disconnected.
+
 
</pre>
+
''' Options '''
 +
 
 +
* '''Enabled''': Trigger when a VPN connection is established
 +
* '''Disabled''': Trigger when a VPN connection is terminated
 +
 
 +
''' Requirements '''
 +
 
 +
* Requires Android 5.0 (Lollipop, API 21) or higher
 +
 
 +
''' Configuration '''
 +
 
 +
Select whether to trigger when a VPN is connected (Enabled) or disconnected (Disabled). The trigger monitors network connectivity changes to detect VPN state.
 +
 
 +
''' Examples '''
 +
 
 +
  <pre class="trigger-style">Triggers
 +
 
 +
VPN State (Enabled)</pre>
 +
  <pre class="action-style">Actions
 +
 
 +
Notification: VPN Connected
 +
    Your connection is now secure
 +
Set Variable: [vpn_status] = Connected</pre>
 +
 
 +
''Notify when VPN connection is established.''
 +
 
 +
----
 +
 
 +
  <pre class="trigger-style">Triggers
 +
 
 +
VPN State (Disabled)</pre>
 +
  <pre class="action-style">Actions
 +
 
 +
Notification: VPN Disconnected - Warning!
 +
    Your connection is no longer protected
 +
Speak Text: VPN has disconnected</pre>
 +
 
 +
''Alert when VPN disconnects unexpectedly.''
 +
 
 +
''' Notes '''
 +
 
 +
* The trigger works with any VPN app that uses standard Android VPN APIs.
 +
* Detection is based on network connectivity changes, so there may be a brief delay between the actual VPN state change and trigger activation.
 +
* Useful for security-conscious workflows that require awareness of VPN connection status.
 +
* Consider pairing with a VPN constraint to ensure actions only run when VPN is in the desired state.
 +
* Works with both system VPN connections and third-party VPN applications.
 +
 
 +
''' See Also '''
 +
 
 +
* [[Constraint:_VPN_State|VPN State Constraint]]
 +
* [[Trigger:_Wifi_State_Change|Wifi State Change Trigger]]