Huawei Android SDK
Try our SDK in your Android application
1. Integrate dependencies
To integrate our SDK into your application edit your build.gradle:
Add this block to the root section:
Add this block to the dependencies section:
2. Configurate SDK
To start using the SDK, you need to create a WireSdk instance. Initialize FendSDK with a WireConfig:
Value | Description |
backend URL | Base URL for the API calls (login, fetching locations, etc.) |
project id | A unique identifier of the project |
app version | The application version for analytics purposes |
For backend URL and project ID please contact partners@fend.ai
3. Use API
After SDK initialization you need to authenticate the user on the backend and acquire the list of available locations to connect.
3.1 Authentication
3.2 Available locations
4. Manage VPN
After getting a virtual location configuration, you are ready to start a VPN session.
4.1 Start / Stop
4.2 Statistics
An active VPN connection provides statistics on the amount of traffic, connection start time, and the chosen VPN server IP.
4.3 State
The SDK can provide information on the current VPN tunnel state.
Value | Description |
VpnState.IDLE | No active VPN connection exists |
VpnState.CONNECTING | Establishing a VPN connection right now |
VpnState.CONNECTED | A VPN connection is established and active |
VpnState.ERROR | A VPN connection process has failed |
Last updated