Skip to content

Latest commit

 

History

History
98 lines (66 loc) · 2.23 KB

AuthAPI.md

File metadata and controls

98 lines (66 loc) · 2.23 KB

AuthAPI

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

Method HTTP request Description
migrateLegacyAuth GET /legacy/auth/ Legacy auth migration
whoAmI GET /auth/whoami/ Who am I

migrateLegacyAuth

    open class func migrateLegacyAuth(completion: @escaping (_ data: LegacyAuthMigrationToken?, _ error: Error?) -> Void)

Legacy auth migration

Example

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


// Legacy auth migration
AuthAPI.migrateLegacyAuth() { (response, error) in
    guard error == nil else {
        print(error)
        return
    }

    if (response) {
        dump(response)
    }
}

Parameters

This endpoint does not need any parameter.

Return type

LegacyAuthMigrationToken

Authorization

bearerAuth

HTTP request headers

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

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

whoAmI

    open class func whoAmI(completion: @escaping (_ data: User?, _ error: Error?) -> Void)

Who am I

Example

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


// Who am I
AuthAPI.whoAmI() { (response, error) in
    guard error == nil else {
        print(error)
        return
    }

    if (response) {
        dump(response)
    }
}

Parameters

This endpoint does not need any parameter.

Return type

User

Authorization

bearerAuth

HTTP request headers

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

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