Skip to content

Latest commit

 

History

History
201 lines (145 loc) · 5.24 KB

FcmForestVPNAPI.md

File metadata and controls

201 lines (145 loc) · 5.24 KB

FcmForestVPNAPI

All URIs are relative to https://api.forestvpn.com/v2

Method HTTP request Description
createFCMDevice POST /notification/fcm/ Device registration for push notification through out Firebase Cloud Messaging
deleteFCMDevice DELETE /notification/fcm/{registrationID}/ Delete fcm device
getFCMDevice GET /notification/fcm/{registrationID}/ Device info
updateFCMDevice PATCH /notification/fcm/{registrationID}/ Update device fcm properties

createFCMDevice

FCMDevice createFCMDevice(createFCMDeviceRequest)

Device registration for push notification through out Firebase Cloud Messaging

Example

// Import classes:
//import com.forestvpn.api.client.infrastructure.*
//import com.forestvpn.api.client.models.*

val apiInstance = FcmForestVPNAPI()
val createFCMDeviceRequest : CreateFCMDeviceRequest =  // CreateFCMDeviceRequest | 
try {
    val result : FCMDevice = apiInstance.createFCMDevice(createFCMDeviceRequest)
    println(result)
} catch (e: ClientException) {
    println("4xx response calling FcmForestVPNAPI#createFCMDevice")
    e.printStackTrace()
} catch (e: ServerException) {
    println("5xx response calling FcmForestVPNAPI#createFCMDevice")
    e.printStackTrace()
}

Parameters

Name Type Description Notes
createFCMDeviceRequest CreateFCMDeviceRequest

Return type

FCMDevice

Authorization

Configure bearerAuth: ApiClient.accessToken = ""

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json

deleteFCMDevice

deleteFCMDevice(registrationID)

Delete fcm device

Example

// Import classes:
//import com.forestvpn.api.client.infrastructure.*
//import com.forestvpn.api.client.models.*

val apiInstance = FcmForestVPNAPI()
val registrationID : kotlin.String = registrationID_example // kotlin.String | 
try {
    apiInstance.deleteFCMDevice(registrationID)
} catch (e: ClientException) {
    println("4xx response calling FcmForestVPNAPI#deleteFCMDevice")
    e.printStackTrace()
} catch (e: ServerException) {
    println("5xx response calling FcmForestVPNAPI#deleteFCMDevice")
    e.printStackTrace()
}

Parameters

Name Type Description Notes
registrationID kotlin.String

Return type

null (empty response body)

Authorization

Configure bearerAuth: ApiClient.accessToken = ""

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

getFCMDevice

FCMDevice getFCMDevice(registrationID)

Device info

Example

// Import classes:
//import com.forestvpn.api.client.infrastructure.*
//import com.forestvpn.api.client.models.*

val apiInstance = FcmForestVPNAPI()
val registrationID : kotlin.String = registrationID_example // kotlin.String | 
try {
    val result : FCMDevice = apiInstance.getFCMDevice(registrationID)
    println(result)
} catch (e: ClientException) {
    println("4xx response calling FcmForestVPNAPI#getFCMDevice")
    e.printStackTrace()
} catch (e: ServerException) {
    println("5xx response calling FcmForestVPNAPI#getFCMDevice")
    e.printStackTrace()
}

Parameters

Name Type Description Notes
registrationID kotlin.String

Return type

FCMDevice

Authorization

Configure bearerAuth: ApiClient.accessToken = ""

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

updateFCMDevice

FCMDevice updateFCMDevice(registrationID, updateFCMDeviceRequest)

Update device fcm properties

Example

// Import classes:
//import com.forestvpn.api.client.infrastructure.*
//import com.forestvpn.api.client.models.*

val apiInstance = FcmForestVPNAPI()
val registrationID : kotlin.String = registrationID_example // kotlin.String | 
val updateFCMDeviceRequest : UpdateFCMDeviceRequest =  // UpdateFCMDeviceRequest | 
try {
    val result : FCMDevice = apiInstance.updateFCMDevice(registrationID, updateFCMDeviceRequest)
    println(result)
} catch (e: ClientException) {
    println("4xx response calling FcmForestVPNAPI#updateFCMDevice")
    e.printStackTrace()
} catch (e: ServerException) {
    println("5xx response calling FcmForestVPNAPI#updateFCMDevice")
    e.printStackTrace()
}

Parameters

Name Type Description Notes
registrationID kotlin.String
updateFCMDeviceRequest UpdateFCMDeviceRequest

Return type

FCMDevice

Authorization

Configure bearerAuth: ApiClient.accessToken = ""

HTTP request headers

  • Content-Type: application/json
  • Accept: application/json