Skip to content

Latest commit

 

History

History
57 lines (38 loc) · 1.58 KB

AuthAPI.md

File metadata and controls

57 lines (38 loc) · 1.58 KB

AuthAPI

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

Method HTTP request Description
getAccessToken POST /auth/token/ Get an access token

getAccessToken

    open class func getAccessToken(accessTokenRequest: AccessTokenRequest, completion: @escaping (_ data: AccessToken?, _ error: Error?) -> Void)

Get an access token

Example

// The following code samples are still beta. For any issue, please report via http://github.com/OpenAPITools/openapi-generator/issues/new
import ForestVPNCloudSDKAPI

let accessTokenRequest = AccessTokenRequest(grantType: "grantType_example", refreshToken: "refreshToken_example") // AccessTokenRequest | 

// Get an access token
AuthAPI.getAccessToken(accessTokenRequest: accessTokenRequest) { (response, error) in
    guard error == nil else {
        print(error)
        return
    }

    if (response) {
        dump(response)
    }
}

Parameters

Name Type Description Notes
accessTokenRequest AccessTokenRequest

Return type

AccessToken

Authorization

BearerTokenAuth

HTTP request headers

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

[Back to top] [Back to API list] [Back to Model list] [Back to README]