forestvpn_cloud_api 0.1.0 → 1.0.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 35f0fffbd578794c13a1fadf27a00b404ba1ec5c5e7396196f24c1eceab9aa99
4
- data.tar.gz: 6f480714e01c5ef48fb9a7c86b9cccd19ad2ec00a13a6bdccd80460e401d51c2
3
+ metadata.gz: 3c3fd8e416c393d61f1b2bde8d0514e7194dfccf6fd0d5284be0928ea5fc08d1
4
+ data.tar.gz: 9349977890b05499a6f6b2a185987698fe8e878d0b2736ddb2f7b8aa607748a5
5
5
  SHA512:
6
- metadata.gz: 258c190afd9ad2ab933291f130db6f2a0c21dc9f20cf51f1243071552d5ac6c625fa188c40a992513bf5a9df72ec7f4ce353cad959f82912366270c4e04eaa24
7
- data.tar.gz: 8e487c941266c9395ddb0a6998a456b5f9bf67cd3695648f785432ca85711c23c7e5cf4bd4e8e520db42b71fbb8ebd61ff53dee920f4e21e28f68cc14c8170af
6
+ metadata.gz: 072d39af59d250880d386baf546a170b05a7d2198e4b81f35a9a147396b533c7bdb1c6e8f8c07e055404bbe072e8d6e6815c07d80d12cd274d5e9c57721903b5
7
+ data.tar.gz: f1b9d57bde25d13a1fa430800a6bab81378e2f3345351cbb1aebbdedcf302512be38b9833f32c00aaebba6108e420cfb5e058da6b985f0683e54794f49dfc2a8
data/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2022 ForestVPN
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
data/README.md CHANGED
@@ -1,18 +1,49 @@
1
- # ForestVPN Cloud API
1
+ # forestvpn_cloud_api
2
2
 
3
- The Ruby gem for the ForestVPN Cloud API.
3
+ ForestVPNCloudAPI - the Ruby gem for the ForestVPN Cloud API
4
4
 
5
5
  ForestVPN Cloud - it's a Google Cloud but for VPN apps. Ready to use VPN Cloud Platform minimizes efforts to build fast,
6
6
  secure, and modern VPN apps.
7
7
 
8
- For more information, please visit [ForestVPN](https://forestvpn.com/)
8
+ For more information, please visit [https://forestvpn.com/](https://forestvpn.com/)
9
9
 
10
10
  ## Installation
11
11
 
12
- ### Install from Gems
12
+ ### Build a gem
13
+
14
+ To build the Ruby code into a gem:
15
+
16
+ ```shell
17
+ gem build forestvpn_cloud_api.gemspec
18
+ ```
19
+
20
+ Then either install the gem locally:
21
+
22
+ ```shell
23
+ gem install ./forestvpn_cloud_api-ERSION.gem
24
+ ```
25
+
26
+ (for development, run `gem install --dev ./forestvpn_cloud_api-ERSION.gem` to install the development dependencies)
27
+
28
+ or publish the gem to a gem hosting service, e.g. [RubyGems](https://rubygems.org/).
29
+
30
+ Finally add this to the Gemfile:
31
+
32
+ gem 'forestvpn_cloud_api', '~> ERSION'
33
+
34
+ ### Install from Git
35
+
36
+ If the Ruby gem is hosted at a git repository: https://github.com/GIT_USER_ID/GIT_REPO_ID, then add the following in the
37
+ Gemfile:
38
+
39
+ gem 'forestvpn_cloud_api', :git => 'https://github.com/GIT_USER_ID/GIT_REPO_ID.git'
40
+
41
+ ### Include the Ruby code directly
42
+
43
+ Include the Ruby code directly using `-I` as follows:
13
44
 
14
45
  ```shell
15
- gem install forestvpn_cloud_api
46
+ ruby -Ilib script.rb
16
47
  ```
17
48
 
18
49
  ## Getting Started
@@ -133,7 +164,3 @@ PUT** /profiles/{profileId}/limits/data-usages/{limitId}/ | Update profile data
133
164
 
134
165
  - **Type**: Bearer authentication (JWT)
135
166
 
136
- ## Credits
137
-
138
- - ForestVPN.com [Free VPN](https://forestvpn.com) for all
139
- - SpaceV.net [VPN for teams](https://spacev.net)
@@ -5,7 +5,7 @@
5
5
  | Name | Type | Description | Notes |
6
6
  | ---- | ---- | ----------- | ----- |
7
7
  | **duration** | **String** | Duration in ISO 8601 format. Example P7D - per week | [optional] |
8
- | **value** | **Float** | Limit of bytes | [optional] |
8
+ | **value** | **Integer** | Limit of bytes | [optional] |
9
9
 
10
10
  ## Example
11
11
 
@@ -6,7 +6,7 @@
6
6
  | ---- | ---- | ----------- | ----- |
7
7
  | **id** | **String** | | |
8
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) | |
9
+ | **value** | **Integer** | Value in bytes. For convert to MegaBytes use formula {value} / (1024 * 1024) | |
10
10
  | **scope** | **String** | | |
11
11
 
12
12
  ## Example
data/docs/LimitsApi.md CHANGED
@@ -7,7 +7,7 @@ All URIs are relative to *https://api.forestvpn.com/cloud/v1*
7
7
  | [**create_data_usage_limit**](LimitsApi.md#create_data_usage_limit) | **POST** /limits/data-usage/ | Create data usage limit |
8
8
  | [**delete_data_usage_limit**](LimitsApi.md#delete_data_usage_limit) | **DELETE** /limits/data-usage/{limitId}/ | Delete data usage limit |
9
9
  | [**get_data_usage_limit**](LimitsApi.md#get_data_usage_limit) | **GET** /limits/data-usage/{limitId}/ | Data usage limit details |
10
- | [**lis_data_usage_limits**](LimitsApi.md#lis_data_usage_limits) | **GET** /limits/data-usage/ | Data usage limit list |
10
+ | [**list_data_usage_limits**](LimitsApi.md#list_data_usage_limits) | **GET** /limits/data-usage/ | Data usage limit list |
11
11
  | [**partial_update_data_usage_limit**](LimitsApi.md#partial_update_data_usage_limit) | **PATCH** /limits/data-usage/{limitId}/ | Partial update profile details |
12
12
  | [**update_data_usage_limit**](LimitsApi.md#update_data_usage_limit) | **PUT** /limits/data-usage/{limitId}/ | Update data usage limit |
13
13
 
@@ -229,9 +229,9 @@ end
229
229
  - **Accept**: application/json
230
230
 
231
231
 
232
- ## lis_data_usage_limits
232
+ ## list_data_usage_limits
233
233
 
234
- > <Array<DataUsageLimit>> lis_data_usage_limits
234
+ > <Array<DataUsageLimit>> list_data_usage_limits
235
235
 
236
236
  Data usage limit list
237
237
 
@@ -255,28 +255,28 @@ api_instance = ForestVPNCloudAPI::LimitsApi.new
255
255
 
256
256
  begin
257
257
  # Data usage limit list
258
- result = api_instance.lis_data_usage_limits
258
+ result = api_instance.list_data_usage_limits
259
259
  p result
260
260
  rescue ForestVPNCloudAPI::ApiError => e
261
- puts "Error when calling LimitsApi->lis_data_usage_limits: #{e}"
261
+ puts "Error when calling LimitsApi->list_data_usage_limits: #{e}"
262
262
  end
263
263
  ```
264
264
 
265
- #### Using the lis_data_usage_limits_with_http_info variant
265
+ #### Using the list_data_usage_limits_with_http_info variant
266
266
 
267
267
  This returns an Array which contains the response data, status code and headers.
268
268
 
269
- > <Array(<Array<DataUsageLimit>>, Integer, Hash)> lis_data_usage_limits_with_http_info
269
+ > <Array(<Array<DataUsageLimit>>, Integer, Hash)> list_data_usage_limits_with_http_info
270
270
 
271
271
  ```ruby
272
272
  begin
273
273
  # Data usage limit list
274
- data, status_code, headers = api_instance.lis_data_usage_limits_with_http_info
274
+ data, status_code, headers = api_instance.list_data_usage_limits_with_http_info
275
275
  p status_code # => 2xx
276
276
  p headers # => { ... }
277
277
  p data # => <Array<DataUsageLimit>>
278
278
  rescue ForestVPNCloudAPI::ApiError => e
279
- puts "Error when calling LimitsApi->lis_data_usage_limits_with_http_info: #{e}"
279
+ puts "Error when calling LimitsApi->list_data_usage_limits_with_http_info: #{e}"
280
280
  end
281
281
  ```
282
282
 
data/docs/ProfileStats.md CHANGED
@@ -5,9 +5,9 @@
5
5
  | Name | Type | Description | Notes |
6
6
  | ---- | ---- | ----------- | ----- |
7
7
  | **id** | **String** | | |
8
- | **connections** | **Float** | | |
9
- | **received_bytes** | **Float** | | |
10
- | **transmitted_bytes** | **Float** | | |
8
+ | **connections** | **Integer** | | |
9
+ | **received_bytes** | **Integer** | | |
10
+ | **transmitted_bytes** | **Integer** | | |
11
11
  | **date** | **Time** | | |
12
12
 
13
13
  ## Example
data/docs/ProfilesApi.md CHANGED
@@ -561,8 +561,8 @@ opts = {
561
561
  aggregate_by: 'hourly', # String |
562
562
  date_after: Date.parse('2013-10-20'), # Date |
563
563
  date_before: Date.parse('2013-10-20'), # Date |
564
- per_page: 8.14, # Float |
565
- page: 8.14 # Float |
564
+ per_page: 56, # Integer |
565
+ page: 56 # Integer |
566
566
  }
567
567
 
568
568
  begin
@@ -600,8 +600,8 @@ end
600
600
  | **aggregate_by** | **String** | | [optional] |
601
601
  | **date_after** | **Date** | | [optional] |
602
602
  | **date_before** | **Date** | | [optional] |
603
- | **per_page** | **Float** | | [optional] |
604
- | **page** | **Float** | | [optional] |
603
+ | **per_page** | **Integer** | | [optional] |
604
+ | **page** | **Integer** | | [optional] |
605
605
 
606
606
  ### Return type
607
607
 
@@ -642,8 +642,8 @@ end
642
642
  api_instance = ForestVPNCloudAPI::ProfilesApi.new
643
643
  opts = {
644
644
  external_key: 'external_key_example', # String |
645
- per_page: 8.14, # Float |
646
- page: 8.14 # Float |
645
+ per_page: 56, # Integer |
646
+ page: 56 # Integer |
647
647
  }
648
648
 
649
649
  begin
@@ -678,8 +678,8 @@ end
678
678
  | Name | Type | Description | Notes |
679
679
  | ---- | ---- | ----------- | ----- |
680
680
  | **external_key** | **String** | | [optional] |
681
- | **per_page** | **Float** | | [optional] |
682
- | **page** | **Float** | | [optional] |
681
+ | **per_page** | **Integer** | | [optional] |
682
+ | **page** | **Integer** | | [optional] |
683
683
 
684
684
  ### Return type
685
685
 
@@ -206,17 +206,17 @@ module ForestVPNCloudAPI
206
206
  # Data usage limit list
207
207
  # @param [Hash] opts the optional parameters
208
208
  # @return [Array<DataUsageLimit>]
209
- def lis_data_usage_limits(opts = {})
210
- data, _status_code, _headers = lis_data_usage_limits_with_http_info(opts)
209
+ def list_data_usage_limits(opts = {})
210
+ data, _status_code, _headers = list_data_usage_limits_with_http_info(opts)
211
211
  data
212
212
  end
213
213
 
214
214
  # Data usage limit list
215
215
  # @param [Hash] opts the optional parameters
216
216
  # @return [Array<(Array<DataUsageLimit>, Integer, Hash)>] Array<DataUsageLimit> data, response status code and response headers
217
- def lis_data_usage_limits_with_http_info(opts = {})
217
+ def list_data_usage_limits_with_http_info(opts = {})
218
218
  if @api_client.config.debugging
219
- @api_client.config.logger.debug 'Calling API: LimitsApi.lis_data_usage_limits ...'
219
+ @api_client.config.logger.debug 'Calling API: LimitsApi.list_data_usage_limits ...'
220
220
  end
221
221
  # resource path
222
222
  local_var_path = '/limits/data-usage/'
@@ -242,7 +242,7 @@ module ForestVPNCloudAPI
242
242
  auth_names = opts[:debug_auth_names] || ['ApiTokenAuth', 'BearerTokenAuth']
243
243
 
244
244
  new_options = opts.merge(
245
- :operation => :"LimitsApi.lis_data_usage_limits",
245
+ :operation => :"LimitsApi.list_data_usage_limits",
246
246
  :header_params => header_params,
247
247
  :query_params => query_params,
248
248
  :form_params => form_params,
@@ -253,7 +253,7 @@ module ForestVPNCloudAPI
253
253
 
254
254
  data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
255
255
  if @api_client.config.debugging
256
- @api_client.config.logger.debug "API called: LimitsApi#lis_data_usage_limits\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
256
+ @api_client.config.logger.debug "API called: LimitsApi#list_data_usage_limits\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
257
257
  end
258
258
  return data, status_code, headers
259
259
  end
@@ -474,8 +474,8 @@ module ForestVPNCloudAPI
474
474
  # @option opts [String] :aggregate_by
475
475
  # @option opts [Date] :date_after
476
476
  # @option opts [Date] :date_before
477
- # @option opts [Float] :per_page
478
- # @option opts [Float] :page
477
+ # @option opts [Integer] :per_page
478
+ # @option opts [Integer] :page
479
479
  # @return [Array<ProfileStats>]
480
480
  def list_profile_stats(profile_id, opts = {})
481
481
  data, _status_code, _headers = list_profile_stats_with_http_info(profile_id, opts)
@@ -488,8 +488,8 @@ module ForestVPNCloudAPI
488
488
  # @option opts [String] :aggregate_by
489
489
  # @option opts [Date] :date_after
490
490
  # @option opts [Date] :date_before
491
- # @option opts [Float] :per_page
492
- # @option opts [Float] :page
491
+ # @option opts [Integer] :per_page
492
+ # @option opts [Integer] :page
493
493
  # @return [Array<(Array<ProfileStats>, Integer, Hash)>] Array<ProfileStats> data, response status code and response headers
494
494
  def list_profile_stats_with_http_info(profile_id, opts = {})
495
495
  if @api_client.config.debugging
@@ -551,8 +551,8 @@ module ForestVPNCloudAPI
551
551
  # Profile list
552
552
  # @param [Hash] opts the optional parameters
553
553
  # @option opts [String] :external_key
554
- # @option opts [Float] :per_page
555
- # @option opts [Float] :page
554
+ # @option opts [Integer] :per_page
555
+ # @option opts [Integer] :page
556
556
  # @return [Array<Profile>]
557
557
  def list_profiles(opts = {})
558
558
  data, _status_code, _headers = list_profiles_with_http_info(opts)
@@ -562,8 +562,8 @@ module ForestVPNCloudAPI
562
562
  # Profile list
563
563
  # @param [Hash] opts the optional parameters
564
564
  # @option opts [String] :external_key
565
- # @option opts [Float] :per_page
566
- # @option opts [Float] :page
565
+ # @option opts [Integer] :per_page
566
+ # @option opts [Integer] :page
567
567
  # @return [Array<(Array<Profile>, Integer, Hash)>] Array<Profile> data, response status code and response headers
568
568
  def list_profiles_with_http_info(opts = {})
569
569
  if @api_client.config.debugging
@@ -38,7 +38,7 @@ module ForestVPNCloudAPI
38
38
  def self.openapi_types
39
39
  {
40
40
  :'duration' => :'String',
41
- :'value' => :'Float'
41
+ :'value' => :'Integer'
42
42
  }
43
43
  end
44
44
 
@@ -67,7 +67,7 @@ module ForestVPNCloudAPI
67
67
  {
68
68
  :'id' => :'String',
69
69
  :'duration' => :'String',
70
- :'value' => :'Float',
70
+ :'value' => :'Integer',
71
71
  :'scope' => :'String'
72
72
  }
73
73
  end
@@ -45,9 +45,9 @@ module ForestVPNCloudAPI
45
45
  def self.openapi_types
46
46
  {
47
47
  :'id' => :'String',
48
- :'connections' => :'Float',
49
- :'received_bytes' => :'Float',
50
- :'transmitted_bytes' => :'Float',
48
+ :'connections' => :'Integer',
49
+ :'received_bytes' => :'Integer',
50
+ :'transmitted_bytes' => :'Integer',
51
51
  :'date' => :'Time'
52
52
  }
53
53
  end
@@ -11,5 +11,5 @@ OpenAPI Generator version: 6.0.0
11
11
  =end
12
12
 
13
13
  module ForestVPNCloudAPI
14
- VERSION = '0.1.0'
14
+ VERSION = '1.0.0'
15
15
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: forestvpn_cloud_api
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 1.0.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Digital Services LLC
8
- autorequire:
8
+ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2022-06-06 00:00:00.000000000 Z
11
+ date: 2022-06-20 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: faraday
@@ -48,22 +48,22 @@ dependencies:
48
48
  name: rspec
49
49
  requirement: !ruby/object:Gem::Requirement
50
50
  requirements:
51
- - - "~>"
52
- - !ruby/object:Gem::Version
53
- version: '3.6'
54
51
  - - ">="
55
52
  - !ruby/object:Gem::Version
56
53
  version: 3.6.0
54
+ - - "~>"
55
+ - !ruby/object:Gem::Version
56
+ version: '3.6'
57
57
  type: :development
58
58
  prerelease: false
59
59
  version_requirements: !ruby/object:Gem::Requirement
60
60
  requirements:
61
- - - "~>"
62
- - !ruby/object:Gem::Version
63
- version: '3.6'
64
61
  - - ">="
65
62
  - !ruby/object:Gem::Version
66
63
  version: 3.6.0
64
+ - - "~>"
65
+ - !ruby/object:Gem::Version
66
+ version: '3.6'
67
67
  description: 'ForestVPN Cloud - it''s a Google Cloud but for VPN apps. Ready to use
68
68
  VPN Cloud Platform minimizes efforts to build fast, secure, and modern VPN apps. '
69
69
  email:
@@ -73,6 +73,7 @@ extensions: []
73
73
  extra_rdoc_files: []
74
74
  files:
75
75
  - Gemfile
76
+ - LICENSE
76
77
  - README.md
77
78
  - Rakefile
78
79
  - docs/Action.md
@@ -155,7 +156,7 @@ homepage: https://forestvpn.com/
155
156
  licenses:
156
157
  - MIT
157
158
  metadata: {}
158
- post_install_message:
159
+ post_install_message:
159
160
  rdoc_options: []
160
161
  require_paths:
161
162
  - lib
@@ -170,34 +171,34 @@ required_rubygems_version: !ruby/object:Gem::Requirement
170
171
  - !ruby/object:Gem::Version
171
172
  version: '0'
172
173
  requirements: []
173
- rubygems_version: 3.2.33
174
- signing_key:
174
+ rubygems_version: 3.0.3.1
175
+ signing_key:
175
176
  specification_version: 4
176
177
  summary: A package to interact api.forestvpn.com/cloud/ (manage vpn profiles / check
177
178
  usage statistics / manage locations / manage servers / etc)
178
179
  test_files:
179
- - spec/api/profiles_api_spec.rb
180
180
  - spec/api/geo_api_spec.rb
181
+ - spec/api/profiles_api_spec.rb
181
182
  - spec/api/limits_api_spec.rb
182
183
  - spec/api_client_spec.rb
183
184
  - spec/configuration_spec.rb
184
185
  - spec/models/error_spec.rb
185
- - spec/models/country_spec.rb
186
- - spec/models/create_or_update_data_usage_limit_request_spec.rb
187
- - spec/models/data_usage_limit_spec.rb
188
186
  - spec/models/resource_ref_spec.rb
187
+ - spec/models/data_usage_limit_spec.rb
188
+ - spec/models/profile_stats_spec.rb
189
189
  - spec/models/project_spec.rb
190
- - spec/models/activity_spec.rb
190
+ - spec/models/country_spec.rb
191
+ - spec/models/create_billing_request_spec.rb
192
+ - spec/models/create_or_update_data_usage_limit_request_spec.rb
191
193
  - spec/models/create_or_update_payment_profile_request_spec.rb
192
194
  - spec/models/create_or_update_profile_request_spec.rb
193
- - spec/models/address_spec.rb
194
- - spec/models/profile_stats_spec.rb
195
- - spec/models/profile_spec.rb
196
195
  - spec/models/location_spec.rb
197
- - spec/models/create_billing_request_spec.rb
198
- - spec/models/billing_spec.rb
199
196
  - spec/models/action_spec.rb
200
- - spec/models/payment_profile_spec.rb
201
- - spec/models/user_spec.rb
197
+ - spec/models/activity_spec.rb
198
+ - spec/models/profile_spec.rb
202
199
  - spec/models/payment_method_spec.rb
200
+ - spec/models/user_spec.rb
201
+ - spec/models/payment_profile_spec.rb
202
+ - spec/models/billing_spec.rb
203
+ - spec/models/address_spec.rb
203
204
  - spec/spec_helper.rb