forestvpn_cloud_api 0.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/Gemfile +9 -0
- data/README.md +139 -0
- data/Rakefile +10 -0
- data/docs/Action.md +32 -0
- data/docs/Activity.md +36 -0
- data/docs/Address.md +28 -0
- data/docs/Billing.md +24 -0
- data/docs/Country.md +26 -0
- data/docs/CreateBillingRequest.md +22 -0
- data/docs/CreateOrUpdateDataUsageLimitRequest.md +20 -0
- data/docs/CreateOrUpdatePaymentProfileRequest.md +34 -0
- data/docs/CreateOrUpdateProfileRequest.md +22 -0
- data/docs/DataUsageLimit.md +24 -0
- data/docs/Error.md +20 -0
- data/docs/GeoApi.md +77 -0
- data/docs/LimitsApi.md +447 -0
- data/docs/Location.md +28 -0
- data/docs/PaymentMethod.md +24 -0
- data/docs/PaymentProfile.md +32 -0
- data/docs/Profile.md +26 -0
- data/docs/ProfileStats.md +26 -0
- data/docs/ProfilesApi.md +996 -0
- data/docs/Project.md +22 -0
- data/docs/ResourceRef.md +20 -0
- data/docs/User.md +32 -0
- data/forestvpn_cloud_api.gemspec +39 -0
- data/git_push.sh +57 -0
- data/lib/forestvpn_cloud_api/api/geo_api.rb +77 -0
- data/lib/forestvpn_cloud_api/api/limits_api.rb +405 -0
- data/lib/forestvpn_cloud_api/api/profiles_api.rb +915 -0
- data/lib/forestvpn_cloud_api/api_client.rb +426 -0
- data/lib/forestvpn_cloud_api/api_error.rb +57 -0
- data/lib/forestvpn_cloud_api/configuration.rb +335 -0
- data/lib/forestvpn_cloud_api/models/action.rb +348 -0
- data/lib/forestvpn_cloud_api/models/activity.rb +360 -0
- data/lib/forestvpn_cloud_api/models/address.rb +269 -0
- data/lib/forestvpn_cloud_api/models/billing.rb +266 -0
- data/lib/forestvpn_cloud_api/models/country.rb +282 -0
- data/lib/forestvpn_cloud_api/models/create_billing_request.rb +252 -0
- data/lib/forestvpn_cloud_api/models/create_or_update_data_usage_limit_request.rb +230 -0
- data/lib/forestvpn_cloud_api/models/create_or_update_payment_profile_request.rb +328 -0
- data/lib/forestvpn_cloud_api/models/create_or_update_profile_request.rb +275 -0
- data/lib/forestvpn_cloud_api/models/data_usage_limit.rb +302 -0
- data/lib/forestvpn_cloud_api/models/error.rb +238 -0
- data/lib/forestvpn_cloud_api/models/location.rb +296 -0
- data/lib/forestvpn_cloud_api/models/payment_method.rb +261 -0
- data/lib/forestvpn_cloud_api/models/payment_profile.rb +313 -0
- data/lib/forestvpn_cloud_api/models/profile.rb +320 -0
- data/lib/forestvpn_cloud_api/models/profile_stats.rb +280 -0
- data/lib/forestvpn_cloud_api/models/project.rb +254 -0
- data/lib/forestvpn_cloud_api/models/resource_ref.rb +238 -0
- data/lib/forestvpn_cloud_api/models/user.rb +307 -0
- data/lib/forestvpn_cloud_api/version.rb +15 -0
- data/lib/forestvpn_cloud_api.rb +61 -0
- data/spec/api/geo_api_spec.rb +45 -0
- data/spec/api/limits_api_spec.rb +102 -0
- data/spec/api/profiles_api_spec.rb +195 -0
- data/spec/api_client_spec.rb +188 -0
- data/spec/configuration_spec.rb +42 -0
- data/spec/models/action_spec.rb +80 -0
- data/spec/models/activity_spec.rb +92 -0
- data/spec/models/address_spec.rb +64 -0
- data/spec/models/billing_spec.rb +52 -0
- data/spec/models/country_spec.rb +58 -0
- data/spec/models/create_billing_request_spec.rb +46 -0
- data/spec/models/create_or_update_data_usage_limit_request_spec.rb +40 -0
- data/spec/models/create_or_update_payment_profile_request_spec.rb +82 -0
- data/spec/models/create_or_update_profile_request_spec.rb +50 -0
- data/spec/models/data_usage_limit_spec.rb +56 -0
- data/spec/models/error_spec.rb +40 -0
- data/spec/models/location_spec.rb +64 -0
- data/spec/models/payment_method_spec.rb +52 -0
- data/spec/models/payment_profile_spec.rb +76 -0
- data/spec/models/profile_spec.rb +62 -0
- data/spec/models/profile_stats_spec.rb +58 -0
- data/spec/models/project_spec.rb +46 -0
- data/spec/models/resource_ref_spec.rb +40 -0
- data/spec/models/user_spec.rb +76 -0
- data/spec/spec_helper.rb +111 -0
- metadata +203 -0
checksums.yaml
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
---
|
2
|
+
SHA256:
|
3
|
+
metadata.gz: 35f0fffbd578794c13a1fadf27a00b404ba1ec5c5e7396196f24c1eceab9aa99
|
4
|
+
data.tar.gz: 6f480714e01c5ef48fb9a7c86b9cccd19ad2ec00a13a6bdccd80460e401d51c2
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: 258c190afd9ad2ab933291f130db6f2a0c21dc9f20cf51f1243071552d5ac6c625fa188c40a992513bf5a9df72ec7f4ce353cad959f82912366270c4e04eaa24
|
7
|
+
data.tar.gz: 8e487c941266c9395ddb0a6998a456b5f9bf67cd3695648f785432ca85711c23c7e5cf4bd4e8e520db42b71fbb8ebd61ff53dee920f4e21e28f68cc14c8170af
|
data/Gemfile
ADDED
data/README.md
ADDED
@@ -0,0 +1,139 @@
|
|
1
|
+
# ForestVPN Cloud API
|
2
|
+
|
3
|
+
The Ruby gem for the ForestVPN Cloud API.
|
4
|
+
|
5
|
+
ForestVPN Cloud - it's a Google Cloud but for VPN apps. Ready to use VPN Cloud Platform minimizes efforts to build fast,
|
6
|
+
secure, and modern VPN apps.
|
7
|
+
|
8
|
+
For more information, please visit [ForestVPN](https://forestvpn.com/)
|
9
|
+
|
10
|
+
## Installation
|
11
|
+
|
12
|
+
### Install from Gems
|
13
|
+
|
14
|
+
```shell
|
15
|
+
gem install forestvpn_cloud_api
|
16
|
+
```
|
17
|
+
|
18
|
+
## Getting Started
|
19
|
+
|
20
|
+
Please follow the [installation](#installation) procedure and then run the following code:
|
21
|
+
|
22
|
+
```ruby
|
23
|
+
# Load the gem
|
24
|
+
require 'forestvpn_cloud_api'
|
25
|
+
|
26
|
+
# Setup authorization
|
27
|
+
ForestVPNCloudAPI.configure do |config|
|
28
|
+
# Configure API key authorization: ApiTokenAuth
|
29
|
+
config.api_key['ApiTokenAuth'] = 'YOUR API KEY'
|
30
|
+
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
|
31
|
+
# config.api_key_prefix['ApiTokenAuth'] = 'Bearer'
|
32
|
+
|
33
|
+
# Configure Bearer authorization (JWT): BearerTokenAuth
|
34
|
+
config.access_token = 'YOUR_BEARER_TOKEN'
|
35
|
+
end
|
36
|
+
|
37
|
+
api_instance = ForestVPNCloudAPI::GeoApi.new
|
38
|
+
|
39
|
+
begin
|
40
|
+
#Location list
|
41
|
+
result = api_instance.list_locations
|
42
|
+
p result
|
43
|
+
rescue ForestVPNCloudAPI::ApiError => e
|
44
|
+
puts "Exception when calling GeoApi->list_locations: #{e}"
|
45
|
+
end
|
46
|
+
|
47
|
+
```
|
48
|
+
|
49
|
+
## Documentation for API Endpoints
|
50
|
+
|
51
|
+
All URIs are relative to *https://api.forestvpn.com/cloud/v1*
|
52
|
+
|
53
|
+
Class | Method | HTTP request | Description
|
54
|
+
------------ | ------------- | ------------- | -------------
|
55
|
+
*ForestVPNCloudAPI::GeoApi* | [**list_locations**](docs/GeoApi.md#list_locations) | **GET** /locations/ | Location list
|
56
|
+
*ForestVPNCloudAPI::LimitsApi* | [**create_data_usage_limit**](docs/LimitsApi.md#create_data_usage_limit) | **
|
57
|
+
POST** /limits/data-usage/ | Create data usage limit
|
58
|
+
*ForestVPNCloudAPI::LimitsApi* | [**delete_data_usage_limit**](docs/LimitsApi.md#delete_data_usage_limit) | **
|
59
|
+
DELETE** /limits/data-usage/{limitId}/ | Delete data usage limit
|
60
|
+
*ForestVPNCloudAPI::LimitsApi* | [**get_data_usage_limit**](docs/LimitsApi.md#get_data_usage_limit) | **
|
61
|
+
GET** /limits/data-usage/{limitId}/ | Data usage limit details
|
62
|
+
*ForestVPNCloudAPI::LimitsApi* | [**lis_data_usage_limits**](docs/LimitsApi.md#lis_data_usage_limits) | **
|
63
|
+
GET** /limits/data-usage/ | Data usage limit list
|
64
|
+
*ForestVPNCloudAPI::LimitsApi* | [**
|
65
|
+
partial_update_data_usage_limit**](docs/LimitsApi.md#partial_update_data_usage_limit) | **
|
66
|
+
PATCH** /limits/data-usage/{limitId}/ | Partial update profile details
|
67
|
+
*ForestVPNCloudAPI::LimitsApi* | [**update_data_usage_limit**](docs/LimitsApi.md#update_data_usage_limit) | **
|
68
|
+
PUT** /limits/data-usage/{limitId}/ | Update data usage limit
|
69
|
+
*ForestVPNCloudAPI::ProfilesApi* | [**create_profile**](docs/ProfilesApi.md#create_profile) | **
|
70
|
+
POST** /profiles/ | Create profile
|
71
|
+
*ForestVPNCloudAPI::ProfilesApi* | [**
|
72
|
+
create_profile_data_usage_limit**](docs/ProfilesApi.md#create_profile_data_usage_limit) | **
|
73
|
+
POST** /profiles/{profileId}/limits/data-usages/ | Create profile data usage limit
|
74
|
+
*ForestVPNCloudAPI::ProfilesApi* | [**delete_profile**](docs/ProfilesApi.md#delete_profile) | **
|
75
|
+
DELETE** /profiles/{profileId}/ | Delete profile
|
76
|
+
*ForestVPNCloudAPI::ProfilesApi* | [**
|
77
|
+
delete_profile_data_usage_limit**](docs/ProfilesApi.md#delete_profile_data_usage_limit) | **
|
78
|
+
DELETE** /profiles/{profileId}/limits/data-usages/{limitId}/ | Delete profile data usage limit
|
79
|
+
*ForestVPNCloudAPI::ProfilesApi* | [**get_profile**](docs/ProfilesApi.md#get_profile) | **
|
80
|
+
GET** /profiles/{profileId}/ | Profile details
|
81
|
+
*ForestVPNCloudAPI::ProfilesApi* | [**
|
82
|
+
get_profile_data_usage_limit**](docs/ProfilesApi.md#get_profile_data_usage_limit) | **
|
83
|
+
GET** /profiles/{profileId}/limits/data-usages/{limitId}/ | Profile data usage limit details
|
84
|
+
*ForestVPNCloudAPI::ProfilesApi* | [**
|
85
|
+
list_profile_data_usage_limits**](docs/ProfilesApi.md#list_profile_data_usage_limits) | **
|
86
|
+
GET** /profiles/{profileId}/limits/data-usages/ | Profile data usage limits list
|
87
|
+
*ForestVPNCloudAPI::ProfilesApi* | [**list_profile_stats**](docs/ProfilesApi.md#list_profile_stats) | **
|
88
|
+
GET** /profiles/{profileId}/stats/ | Profile stats list
|
89
|
+
*ForestVPNCloudAPI::ProfilesApi* | [**list_profiles**](docs/ProfilesApi.md#list_profiles) | **
|
90
|
+
GET** /profiles/ | Profile list
|
91
|
+
*ForestVPNCloudAPI::ProfilesApi* | [**partial_update_profile**](docs/ProfilesApi.md#partial_update_profile) | **
|
92
|
+
PATCH** /profiles/{profileId}/ | Partial update profile details
|
93
|
+
*ForestVPNCloudAPI::ProfilesApi* | [**
|
94
|
+
partial_update_profile_data_usage_limit**](docs/ProfilesApi.md#partial_update_profile_data_usage_limit) | **
|
95
|
+
PATCH** /profiles/{profileId}/limits/data-usages/{limitId}/ | Partial update profile data usage limit
|
96
|
+
*ForestVPNCloudAPI::ProfilesApi* | [**update_profile**](docs/ProfilesApi.md#update_profile) | **
|
97
|
+
PUT** /profiles/{profileId}/ | Update profile details
|
98
|
+
*ForestVPNCloudAPI::ProfilesApi* | [**
|
99
|
+
update_profile_data_usage_limit**](docs/ProfilesApi.md#update_profile_data_usage_limit) | **
|
100
|
+
PUT** /profiles/{profileId}/limits/data-usages/{limitId}/ | Update profile data usage limit
|
101
|
+
|
102
|
+
## Documentation for Models
|
103
|
+
|
104
|
+
- [ForestVPNCloudAPI::Action](docs/Action.md)
|
105
|
+
- [ForestVPNCloudAPI::Activity](docs/Activity.md)
|
106
|
+
- [ForestVPNCloudAPI::Address](docs/Address.md)
|
107
|
+
- [ForestVPNCloudAPI::Billing](docs/Billing.md)
|
108
|
+
- [ForestVPNCloudAPI::Country](docs/Country.md)
|
109
|
+
- [ForestVPNCloudAPI::CreateBillingRequest](docs/CreateBillingRequest.md)
|
110
|
+
- [ForestVPNCloudAPI::CreateOrUpdateDataUsageLimitRequest](docs/CreateOrUpdateDataUsageLimitRequest.md)
|
111
|
+
- [ForestVPNCloudAPI::CreateOrUpdatePaymentProfileRequest](docs/CreateOrUpdatePaymentProfileRequest.md)
|
112
|
+
- [ForestVPNCloudAPI::CreateOrUpdateProfileRequest](docs/CreateOrUpdateProfileRequest.md)
|
113
|
+
- [ForestVPNCloudAPI::DataUsageLimit](docs/DataUsageLimit.md)
|
114
|
+
- [ForestVPNCloudAPI::Error](docs/Error.md)
|
115
|
+
- [ForestVPNCloudAPI::Location](docs/Location.md)
|
116
|
+
- [ForestVPNCloudAPI::PaymentMethod](docs/PaymentMethod.md)
|
117
|
+
- [ForestVPNCloudAPI::PaymentProfile](docs/PaymentProfile.md)
|
118
|
+
- [ForestVPNCloudAPI::Profile](docs/Profile.md)
|
119
|
+
- [ForestVPNCloudAPI::ProfileStats](docs/ProfileStats.md)
|
120
|
+
- [ForestVPNCloudAPI::Project](docs/Project.md)
|
121
|
+
- [ForestVPNCloudAPI::ResourceRef](docs/ResourceRef.md)
|
122
|
+
- [ForestVPNCloudAPI::User](docs/User.md)
|
123
|
+
|
124
|
+
## Documentation for Authorization
|
125
|
+
|
126
|
+
### ApiTokenAuth
|
127
|
+
|
128
|
+
- **Type**: API key
|
129
|
+
- **API key parameter name**: X-API-TOKEN
|
130
|
+
- **Location**: HTTP header
|
131
|
+
|
132
|
+
### BearerTokenAuth
|
133
|
+
|
134
|
+
- **Type**: Bearer authentication (JWT)
|
135
|
+
|
136
|
+
## Credits
|
137
|
+
|
138
|
+
- ForestVPN.com [Free VPN](https://forestvpn.com) for all
|
139
|
+
- SpaceV.net [VPN for teams](https://spacev.net)
|
data/Rakefile
ADDED
data/docs/Action.md
ADDED
@@ -0,0 +1,32 @@
|
|
1
|
+
# ForestVPNCloudAPI::Action
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
|
5
|
+
| Name | Type | Description | Notes |
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
7
|
+
| **id** | **String** | | |
|
8
|
+
| **command** | **String** | | |
|
9
|
+
| **error** | [**Error**](Error.md) | | [optional] |
|
10
|
+
| **status** | **String** | | |
|
11
|
+
| **progress** | **Float** | | |
|
12
|
+
| **resources** | [**Array<ResourceRef>**](ResourceRef.md) | | |
|
13
|
+
| **created_at** | **Time** | | |
|
14
|
+
| **finished_at** | **Time** | | [optional] |
|
15
|
+
|
16
|
+
## Example
|
17
|
+
|
18
|
+
```ruby
|
19
|
+
require 'forestvpn_cloud_api'
|
20
|
+
|
21
|
+
instance = ForestVPNCloudAPI::Action.new(
|
22
|
+
id: null,
|
23
|
+
command: null,
|
24
|
+
error: null,
|
25
|
+
status: null,
|
26
|
+
progress: null,
|
27
|
+
resources: null,
|
28
|
+
created_at: null,
|
29
|
+
finished_at: null
|
30
|
+
)
|
31
|
+
```
|
32
|
+
|
data/docs/Activity.md
ADDED
@@ -0,0 +1,36 @@
|
|
1
|
+
# ForestVPNCloudAPI::Activity
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
|
5
|
+
| Name | Type | Description | Notes |
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
7
|
+
| **id** | **String** | | |
|
8
|
+
| **action_type** | **String** | | [optional] |
|
9
|
+
| **resource_type** | **String** | | |
|
10
|
+
| **user** | [**User**](User.md) | | [optional] |
|
11
|
+
| **api_token** | **String** | | [optional] |
|
12
|
+
| **project** | [**Project**](Project.md) | | [optional] |
|
13
|
+
| **source_ip** | **String** | Source IP Address. Last 3 digits is hidden by security reason. | |
|
14
|
+
| **status** | **String** | | |
|
15
|
+
| **created_at** | **Time** | | |
|
16
|
+
| **finished_at** | **Time** | | [optional] |
|
17
|
+
|
18
|
+
## Example
|
19
|
+
|
20
|
+
```ruby
|
21
|
+
require 'forestvpn_cloud_api'
|
22
|
+
|
23
|
+
instance = ForestVPNCloudAPI::Activity.new(
|
24
|
+
id: null,
|
25
|
+
action_type: null,
|
26
|
+
resource_type: null,
|
27
|
+
user: null,
|
28
|
+
api_token: null,
|
29
|
+
project: null,
|
30
|
+
source_ip: null,
|
31
|
+
status: null,
|
32
|
+
created_at: null,
|
33
|
+
finished_at: null
|
34
|
+
)
|
35
|
+
```
|
36
|
+
|
data/docs/Address.md
ADDED
@@ -0,0 +1,28 @@
|
|
1
|
+
# ForestVPNCloudAPI::Address
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
|
5
|
+
| Name | Type | Description | Notes |
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
7
|
+
| **city** | **String** | City, district, suburb, town, or village. | [optional] |
|
8
|
+
| **country** | [**Country**](Country.md) | | [optional] |
|
9
|
+
| **line1** | **String** | Address line 1 (e.g., street, PO Box, or company name). | [optional] |
|
10
|
+
| **line2** | **String** | Address line 2 (e.g., apartment, suite, unit, or building). | [optional] |
|
11
|
+
| **postal_code** | **String** | ZIP or postal code. | [optional] |
|
12
|
+
| **state** | **String** | State, county, province, or region. | [optional] |
|
13
|
+
|
14
|
+
## Example
|
15
|
+
|
16
|
+
```ruby
|
17
|
+
require 'forestvpn_cloud_api'
|
18
|
+
|
19
|
+
instance = ForestVPNCloudAPI::Address.new(
|
20
|
+
city: null,
|
21
|
+
country: null,
|
22
|
+
line1: null,
|
23
|
+
line2: null,
|
24
|
+
postal_code: null,
|
25
|
+
state: null
|
26
|
+
)
|
27
|
+
```
|
28
|
+
|
data/docs/Billing.md
ADDED
@@ -0,0 +1,24 @@
|
|
1
|
+
# ForestVPNCloudAPI::Billing
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
|
5
|
+
| Name | Type | Description | Notes |
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
7
|
+
| **id** | **String** | | |
|
8
|
+
| **name** | **String** | | |
|
9
|
+
| **country** | [**Country**](Country.md) | | |
|
10
|
+
| **payment_profile** | [**PaymentProfile**](PaymentProfile.md) | | |
|
11
|
+
|
12
|
+
## Example
|
13
|
+
|
14
|
+
```ruby
|
15
|
+
require 'forestvpn_cloud_api'
|
16
|
+
|
17
|
+
instance = ForestVPNCloudAPI::Billing.new(
|
18
|
+
id: null,
|
19
|
+
name: null,
|
20
|
+
country: null,
|
21
|
+
payment_profile: null
|
22
|
+
)
|
23
|
+
```
|
24
|
+
|
data/docs/Country.md
ADDED
@@ -0,0 +1,26 @@
|
|
1
|
+
# ForestVPNCloudAPI::Country
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
|
5
|
+
| Name | Type | Description | Notes |
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
7
|
+
| **id** | **String** | | |
|
8
|
+
| **name** | **String** | | |
|
9
|
+
| **emoji** | **String** | | |
|
10
|
+
| **currency** | **String** | | |
|
11
|
+
| **alternative_names** | **Array<String>** | | |
|
12
|
+
|
13
|
+
## Example
|
14
|
+
|
15
|
+
```ruby
|
16
|
+
require 'forestvpn_cloud_api'
|
17
|
+
|
18
|
+
instance = ForestVPNCloudAPI::Country.new(
|
19
|
+
id: null,
|
20
|
+
name: null,
|
21
|
+
emoji: null,
|
22
|
+
currency: null,
|
23
|
+
alternative_names: null
|
24
|
+
)
|
25
|
+
```
|
26
|
+
|
@@ -0,0 +1,22 @@
|
|
1
|
+
# ForestVPNCloudAPI::CreateBillingRequest
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
|
5
|
+
| Name | Type | Description | Notes |
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
7
|
+
| **name** | **String** | | |
|
8
|
+
| **country** | **String** | | |
|
9
|
+
| **payment_profile** | [**CreateOrUpdatePaymentProfileRequest**](CreateOrUpdatePaymentProfileRequest.md) | | |
|
10
|
+
|
11
|
+
## Example
|
12
|
+
|
13
|
+
```ruby
|
14
|
+
require 'forestvpn_cloud_api'
|
15
|
+
|
16
|
+
instance = ForestVPNCloudAPI::CreateBillingRequest.new(
|
17
|
+
name: null,
|
18
|
+
country: null,
|
19
|
+
payment_profile: null
|
20
|
+
)
|
21
|
+
```
|
22
|
+
|
@@ -0,0 +1,20 @@
|
|
1
|
+
# ForestVPNCloudAPI::CreateOrUpdateDataUsageLimitRequest
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
|
5
|
+
| Name | Type | Description | Notes |
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
7
|
+
| **duration** | **String** | Duration in ISO 8601 format. Example P7D - per week | [optional] |
|
8
|
+
| **value** | **Float** | Limit of bytes | [optional] |
|
9
|
+
|
10
|
+
## Example
|
11
|
+
|
12
|
+
```ruby
|
13
|
+
require 'forestvpn_cloud_api'
|
14
|
+
|
15
|
+
instance = ForestVPNCloudAPI::CreateOrUpdateDataUsageLimitRequest.new(
|
16
|
+
duration: P7D,
|
17
|
+
value: null
|
18
|
+
)
|
19
|
+
```
|
20
|
+
|
@@ -0,0 +1,34 @@
|
|
1
|
+
# ForestVPNCloudAPI::CreateOrUpdatePaymentProfileRequest
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
|
5
|
+
| Name | Type | Description | Notes |
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
7
|
+
| **tax_number** | **String** | In some situations, your tax status will determine your tax treatment. | [optional] |
|
8
|
+
| **business_name** | **String** | | |
|
9
|
+
| **name** | **String** | | |
|
10
|
+
| **address_line1** | **String** | | |
|
11
|
+
| **address_line2** | **String** | | [optional] |
|
12
|
+
| **address_line3** | **String** | Administrative area. Usually it is city or region. | |
|
13
|
+
| **primary_contact_name** | **String** | | |
|
14
|
+
| **primary_contact_phone** | **String** | | |
|
15
|
+
| **primary_contact_email** | **String** | | |
|
16
|
+
|
17
|
+
## Example
|
18
|
+
|
19
|
+
```ruby
|
20
|
+
require 'forestvpn_cloud_api'
|
21
|
+
|
22
|
+
instance = ForestVPNCloudAPI::CreateOrUpdatePaymentProfileRequest.new(
|
23
|
+
tax_number: null,
|
24
|
+
business_name: null,
|
25
|
+
name: null,
|
26
|
+
address_line1: null,
|
27
|
+
address_line2: null,
|
28
|
+
address_line3: null,
|
29
|
+
primary_contact_name: null,
|
30
|
+
primary_contact_phone: null,
|
31
|
+
primary_contact_email: null
|
32
|
+
)
|
33
|
+
```
|
34
|
+
|
@@ -0,0 +1,22 @@
|
|
1
|
+
# ForestVPNCloudAPI::CreateOrUpdateProfileRequest
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
|
5
|
+
| Name | Type | Description | Notes |
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
7
|
+
| **external_key** | **String** | | [optional] |
|
8
|
+
| **metadata** | **Hash<String, String>** | | [optional] |
|
9
|
+
| **status** | **String** | | [optional][default to 'suspended'] |
|
10
|
+
|
11
|
+
## Example
|
12
|
+
|
13
|
+
```ruby
|
14
|
+
require 'forestvpn_cloud_api'
|
15
|
+
|
16
|
+
instance = ForestVPNCloudAPI::CreateOrUpdateProfileRequest.new(
|
17
|
+
external_key: null,
|
18
|
+
metadata: null,
|
19
|
+
status: null
|
20
|
+
)
|
21
|
+
```
|
22
|
+
|
@@ -0,0 +1,24 @@
|
|
1
|
+
# ForestVPNCloudAPI::DataUsageLimit
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
|
5
|
+
| Name | Type | Description | Notes |
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
7
|
+
| **id** | **String** | | |
|
8
|
+
| **duration** | **String** | Duration in ISO 8601 format. Example P7D - per week | |
|
9
|
+
| **value** | **Float** | Value in bytes. For convert to MegaBytes use formula {value} / (1024 * 1024) | |
|
10
|
+
| **scope** | **String** | | |
|
11
|
+
|
12
|
+
## Example
|
13
|
+
|
14
|
+
```ruby
|
15
|
+
require 'forestvpn_cloud_api'
|
16
|
+
|
17
|
+
instance = ForestVPNCloudAPI::DataUsageLimit.new(
|
18
|
+
id: null,
|
19
|
+
duration: P7D,
|
20
|
+
value: null,
|
21
|
+
scope: null
|
22
|
+
)
|
23
|
+
```
|
24
|
+
|
data/docs/Error.md
ADDED
@@ -0,0 +1,20 @@
|
|
1
|
+
# ForestVPNCloudAPI::Error
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
|
5
|
+
| Name | Type | Description | Notes |
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
7
|
+
| **code** | **String** | | |
|
8
|
+
| **message** | **String** | | |
|
9
|
+
|
10
|
+
## Example
|
11
|
+
|
12
|
+
```ruby
|
13
|
+
require 'forestvpn_cloud_api'
|
14
|
+
|
15
|
+
instance = ForestVPNCloudAPI::Error.new(
|
16
|
+
code: null,
|
17
|
+
message: null
|
18
|
+
)
|
19
|
+
```
|
20
|
+
|
data/docs/GeoApi.md
ADDED
@@ -0,0 +1,77 @@
|
|
1
|
+
# ForestVPNCloudAPI::GeoApi
|
2
|
+
|
3
|
+
All URIs are relative to *https://api.forestvpn.com/cloud/v1*
|
4
|
+
|
5
|
+
| Method | HTTP request | Description |
|
6
|
+
| ------ | ------------ | ----------- |
|
7
|
+
| [**list_locations**](GeoApi.md#list_locations) | **GET** /locations/ | Location list |
|
8
|
+
|
9
|
+
|
10
|
+
## list_locations
|
11
|
+
|
12
|
+
> <Array<Location>> list_locations
|
13
|
+
|
14
|
+
Location list
|
15
|
+
|
16
|
+
### Examples
|
17
|
+
|
18
|
+
```ruby
|
19
|
+
require 'time'
|
20
|
+
require 'forestvpn_cloud_api'
|
21
|
+
# setup authorization
|
22
|
+
ForestVPNCloudAPI.configure do |config|
|
23
|
+
# Configure API key authorization: ApiTokenAuth
|
24
|
+
config.api_key['ApiTokenAuth'] = 'YOUR API KEY'
|
25
|
+
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
|
26
|
+
# config.api_key_prefix['ApiTokenAuth'] = 'Bearer'
|
27
|
+
|
28
|
+
# Configure Bearer authorization (JWT): BearerTokenAuth
|
29
|
+
config.access_token = 'YOUR_BEARER_TOKEN'
|
30
|
+
end
|
31
|
+
|
32
|
+
api_instance = ForestVPNCloudAPI::GeoApi.new
|
33
|
+
|
34
|
+
begin
|
35
|
+
# Location list
|
36
|
+
result = api_instance.list_locations
|
37
|
+
p result
|
38
|
+
rescue ForestVPNCloudAPI::ApiError => e
|
39
|
+
puts "Error when calling GeoApi->list_locations: #{e}"
|
40
|
+
end
|
41
|
+
```
|
42
|
+
|
43
|
+
#### Using the list_locations_with_http_info variant
|
44
|
+
|
45
|
+
This returns an Array which contains the response data, status code and headers.
|
46
|
+
|
47
|
+
> <Array(<Array<Location>>, Integer, Hash)> list_locations_with_http_info
|
48
|
+
|
49
|
+
```ruby
|
50
|
+
begin
|
51
|
+
# Location list
|
52
|
+
data, status_code, headers = api_instance.list_locations_with_http_info
|
53
|
+
p status_code # => 2xx
|
54
|
+
p headers # => { ... }
|
55
|
+
p data # => <Array<Location>>
|
56
|
+
rescue ForestVPNCloudAPI::ApiError => e
|
57
|
+
puts "Error when calling GeoApi->list_locations_with_http_info: #{e}"
|
58
|
+
end
|
59
|
+
```
|
60
|
+
|
61
|
+
### Parameters
|
62
|
+
|
63
|
+
This endpoint does not need any parameter.
|
64
|
+
|
65
|
+
### Return type
|
66
|
+
|
67
|
+
[**Array<Location>**](Location.md)
|
68
|
+
|
69
|
+
### Authorization
|
70
|
+
|
71
|
+
[ApiTokenAuth](../README.md#ApiTokenAuth), [BearerTokenAuth](../README.md#BearerTokenAuth)
|
72
|
+
|
73
|
+
### HTTP request headers
|
74
|
+
|
75
|
+
- **Content-Type**: Not defined
|
76
|
+
- **Accept**: application/json
|
77
|
+
|