polar_accesslink 1.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +7 -0
- data/Gemfile +9 -0
- data/Gemfile.lock +70 -0
- data/README.md +170 -0
- data/Rakefile +10 -0
- data/docs/Activity.md +33 -0
- data/docs/ActivityLog.md +17 -0
- data/docs/ActivityStepSample.md +19 -0
- data/docs/ActivityStepSamples.md +19 -0
- data/docs/ActivityZoneSample.md +19 -0
- data/docs/ActivityZoneSamples.md +19 -0
- data/docs/AvailableUserData.md +21 -0
- data/docs/AvailableUserDatas.md +17 -0
- data/docs/CreatedWebhook.md +17 -0
- data/docs/CreatedWebhookData.md +23 -0
- data/docs/DailyActivityApi.md +339 -0
- data/docs/DurationZone.md +19 -0
- data/docs/Error.md +25 -0
- data/docs/Exercise.md +47 -0
- data/docs/ExerciseHashId.md +45 -0
- data/docs/Exercises.md +17 -0
- data/docs/ExercisesApi.md +163 -0
- data/docs/HeartRate.md +19 -0
- data/docs/PhysicalInfoApi.md +227 -0
- data/docs/PhysicalInformation.md +39 -0
- data/docs/PhysicalInformations.md +17 -0
- data/docs/PullNotificationsApi.md +58 -0
- data/docs/Register.md +17 -0
- data/docs/Sample.md +21 -0
- data/docs/Samples.md +17 -0
- data/docs/TrainingDataApi.md +571 -0
- data/docs/TransactionLocation.md +19 -0
- data/docs/User.md +35 -0
- data/docs/UserExtraInfo.md +21 -0
- data/docs/UsersApi.md +166 -0
- data/docs/WebhookInfo.md +17 -0
- data/docs/WebhookInfoData.md +21 -0
- data/docs/WebhookPatch.md +19 -0
- data/docs/WebhookPayload.md +25 -0
- data/docs/WebhookPing.md +19 -0
- data/docs/WebhookRequest.md +19 -0
- data/docs/WebhookType.md +16 -0
- data/docs/WebhooksApi.md +221 -0
- data/docs/Zone.md +23 -0
- data/docs/Zones.md +17 -0
- data/lib/.DS_Store +0 -0
- data/lib/polar_accesslink/.DS_Store +0 -0
- data/lib/polar_accesslink/api/daily_activity_api.rb +463 -0
- data/lib/polar_accesslink/api/exercises_api.rb +202 -0
- data/lib/polar_accesslink/api/physical_info_api.rb +292 -0
- data/lib/polar_accesslink/api/pull_notifications_api.rb +78 -0
- data/lib/polar_accesslink/api/training_data_api.rb +772 -0
- data/lib/polar_accesslink/api/users_api.rb +218 -0
- data/lib/polar_accesslink/api/webhooks_api.rb +274 -0
- data/lib/polar_accesslink/api_client.rb +386 -0
- data/lib/polar_accesslink/api_error.rb +57 -0
- data/lib/polar_accesslink/configuration.rb +255 -0
- data/lib/polar_accesslink/models/activity.rb +288 -0
- data/lib/polar_accesslink/models/activity_log.rb +210 -0
- data/lib/polar_accesslink/models/activity_step_sample.rb +218 -0
- data/lib/polar_accesslink/models/activity_step_samples.rb +220 -0
- data/lib/polar_accesslink/models/activity_zone_sample.rb +220 -0
- data/lib/polar_accesslink/models/activity_zone_samples.rb +220 -0
- data/lib/polar_accesslink/models/available_user_data.rb +262 -0
- data/lib/polar_accesslink/models/available_user_datas.rb +210 -0
- data/lib/polar_accesslink/models/created_webhook.rb +206 -0
- data/lib/polar_accesslink/models/created_webhook_data.rb +236 -0
- data/lib/polar_accesslink/models/duration_zone.rb +218 -0
- data/lib/polar_accesslink/models/error.rb +248 -0
- data/lib/polar_accesslink/models/exercise.rb +357 -0
- data/lib/polar_accesslink/models/exercise_hash_id.rb +347 -0
- data/lib/polar_accesslink/models/exercises.rb +210 -0
- data/lib/polar_accesslink/models/heart_rate.rb +218 -0
- data/lib/polar_accesslink/models/physical_information.rb +352 -0
- data/lib/polar_accesslink/models/physical_informations.rb +210 -0
- data/lib/polar_accesslink/models/register.rb +213 -0
- data/lib/polar_accesslink/models/sample.rb +228 -0
- data/lib/polar_accesslink/models/samples.rb +210 -0
- data/lib/polar_accesslink/models/transaction_location.rb +218 -0
- data/lib/polar_accesslink/models/user.rb +334 -0
- data/lib/polar_accesslink/models/user_extra_info.rb +228 -0
- data/lib/polar_accesslink/models/webhook_info.rb +206 -0
- data/lib/polar_accesslink/models/webhook_info_data.rb +226 -0
- data/lib/polar_accesslink/models/webhook_patch.rb +219 -0
- data/lib/polar_accesslink/models/webhook_payload.rb +246 -0
- data/lib/polar_accesslink/models/webhook_ping.rb +252 -0
- data/lib/polar_accesslink/models/webhook_request.rb +229 -0
- data/lib/polar_accesslink/models/webhook_type.rb +37 -0
- data/lib/polar_accesslink/models/zone.rb +238 -0
- data/lib/polar_accesslink/models/zones.rb +210 -0
- data/lib/polar_accesslink/version.rb +15 -0
- data/lib/polar_accesslink.rb +79 -0
- data/polar_accesslink-1.0.0.gem +0 -0
- data/polar_accesslink.gemspec +38 -0
- data/spec/api/daily_activity_api_spec.rb +114 -0
- data/spec/api/exercises_api_spec.rb +70 -0
- data/spec/api/physical_info_api_spec.rb +87 -0
- data/spec/api/pull_notifications_api_spec.rb +46 -0
- data/spec/api/training_data_api_spec.rb +172 -0
- data/spec/api/users_api_spec.rb +71 -0
- data/spec/api/webhooks_api_spec.rb +83 -0
- data/spec/api_client_spec.rb +226 -0
- data/spec/configuration_spec.rb +42 -0
- data/spec/models/activity_log_spec.rb +41 -0
- data/spec/models/activity_spec.rb +89 -0
- data/spec/models/activity_step_sample_spec.rb +47 -0
- data/spec/models/activity_step_samples_spec.rb +47 -0
- data/spec/models/activity_zone_sample_spec.rb +47 -0
- data/spec/models/activity_zone_samples_spec.rb +47 -0
- data/spec/models/available_user_data_spec.rb +57 -0
- data/spec/models/available_user_datas_spec.rb +41 -0
- data/spec/models/created_webhook_data_spec.rb +59 -0
- data/spec/models/created_webhook_spec.rb +41 -0
- data/spec/models/duration_zone_spec.rb +47 -0
- data/spec/models/error_spec.rb +65 -0
- data/spec/models/exercise_hash_id_spec.rb +125 -0
- data/spec/models/exercise_spec.rb +131 -0
- data/spec/models/exercises_spec.rb +41 -0
- data/spec/models/heart_rate_spec.rb +47 -0
- data/spec/models/physical_information_spec.rb +111 -0
- data/spec/models/physical_informations_spec.rb +41 -0
- data/spec/models/register_spec.rb +41 -0
- data/spec/models/sample_spec.rb +53 -0
- data/spec/models/samples_spec.rb +41 -0
- data/spec/models/transaction_location_spec.rb +47 -0
- data/spec/models/user_extra_info_spec.rb +53 -0
- data/spec/models/user_spec.rb +99 -0
- data/spec/models/webhook_info_data_spec.rb +53 -0
- data/spec/models/webhook_info_spec.rb +41 -0
- data/spec/models/webhook_patch_spec.rb +47 -0
- data/spec/models/webhook_payload_spec.rb +65 -0
- data/spec/models/webhook_ping_spec.rb +51 -0
- data/spec/models/webhook_request_spec.rb +47 -0
- data/spec/models/webhook_type_spec.rb +35 -0
- data/spec/models/zone_spec.rb +59 -0
- data/spec/models/zones_spec.rb +41 -0
- data/spec/spec_helper.rb +111 -0
- metadata +282 -0
@@ -0,0 +1,15 @@
|
|
1
|
+
=begin
|
2
|
+
#Polar Accesslink API
|
3
|
+
|
4
|
+
#Polar Accesslink API documentation
|
5
|
+
|
6
|
+
The version of the OpenAPI document: 3.40.0
|
7
|
+
Contact: b2bhelpdesk@polar.com
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
OpenAPI Generator version: 4.3.0
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
module PolarAccesslink
|
14
|
+
VERSION = '1.0.0'
|
15
|
+
end
|
@@ -0,0 +1,79 @@
|
|
1
|
+
=begin
|
2
|
+
#Polar Accesslink API
|
3
|
+
|
4
|
+
#Polar Accesslink API documentation
|
5
|
+
|
6
|
+
The version of the OpenAPI document: 3.40.0
|
7
|
+
Contact: b2bhelpdesk@polar.com
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
OpenAPI Generator version: 4.3.0
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
# Common files
|
14
|
+
require 'polar_accesslink/api_client'
|
15
|
+
require 'polar_accesslink/api_error'
|
16
|
+
require 'polar_accesslink/version'
|
17
|
+
require 'polar_accesslink/configuration'
|
18
|
+
|
19
|
+
# Models
|
20
|
+
require 'polar_accesslink/models/activity'
|
21
|
+
require 'polar_accesslink/models/activity_log'
|
22
|
+
require 'polar_accesslink/models/activity_step_sample'
|
23
|
+
require 'polar_accesslink/models/activity_step_samples'
|
24
|
+
require 'polar_accesslink/models/activity_zone_sample'
|
25
|
+
require 'polar_accesslink/models/activity_zone_samples'
|
26
|
+
require 'polar_accesslink/models/available_user_data'
|
27
|
+
require 'polar_accesslink/models/available_user_datas'
|
28
|
+
require 'polar_accesslink/models/created_webhook'
|
29
|
+
require 'polar_accesslink/models/created_webhook_data'
|
30
|
+
require 'polar_accesslink/models/duration_zone'
|
31
|
+
require 'polar_accesslink/models/error'
|
32
|
+
require 'polar_accesslink/models/exercise'
|
33
|
+
require 'polar_accesslink/models/exercise_hash_id'
|
34
|
+
require 'polar_accesslink/models/exercises'
|
35
|
+
require 'polar_accesslink/models/heart_rate'
|
36
|
+
require 'polar_accesslink/models/physical_information'
|
37
|
+
require 'polar_accesslink/models/physical_informations'
|
38
|
+
require 'polar_accesslink/models/register'
|
39
|
+
require 'polar_accesslink/models/sample'
|
40
|
+
require 'polar_accesslink/models/samples'
|
41
|
+
require 'polar_accesslink/models/transaction_location'
|
42
|
+
require 'polar_accesslink/models/user'
|
43
|
+
require 'polar_accesslink/models/user_extra_info'
|
44
|
+
require 'polar_accesslink/models/webhook_info'
|
45
|
+
require 'polar_accesslink/models/webhook_info_data'
|
46
|
+
require 'polar_accesslink/models/webhook_patch'
|
47
|
+
require 'polar_accesslink/models/webhook_payload'
|
48
|
+
require 'polar_accesslink/models/webhook_ping'
|
49
|
+
require 'polar_accesslink/models/webhook_request'
|
50
|
+
require 'polar_accesslink/models/webhook_type'
|
51
|
+
require 'polar_accesslink/models/zone'
|
52
|
+
require 'polar_accesslink/models/zones'
|
53
|
+
|
54
|
+
# APIs
|
55
|
+
require 'polar_accesslink/api/daily_activity_api'
|
56
|
+
require 'polar_accesslink/api/exercises_api'
|
57
|
+
require 'polar_accesslink/api/physical_info_api'
|
58
|
+
require 'polar_accesslink/api/pull_notifications_api'
|
59
|
+
require 'polar_accesslink/api/training_data_api'
|
60
|
+
require 'polar_accesslink/api/users_api'
|
61
|
+
require 'polar_accesslink/api/webhooks_api'
|
62
|
+
|
63
|
+
module PolarAccesslink
|
64
|
+
class << self
|
65
|
+
# Customize default settings for the SDK using block.
|
66
|
+
# OpenapiClient.configure do |config|
|
67
|
+
# config.username = "xxx"
|
68
|
+
# config.password = "xxx"
|
69
|
+
# end
|
70
|
+
# If no block given, return the default Configuration object.
|
71
|
+
def configure
|
72
|
+
if block_given?
|
73
|
+
yield(Configuration.default)
|
74
|
+
else
|
75
|
+
Configuration.default
|
76
|
+
end
|
77
|
+
end
|
78
|
+
end
|
79
|
+
end
|
Binary file
|
@@ -0,0 +1,38 @@
|
|
1
|
+
# -*- encoding: utf-8 -*-
|
2
|
+
|
3
|
+
=begin
|
4
|
+
#Polar Accesslink API
|
5
|
+
|
6
|
+
#Polar Accesslink API documentation
|
7
|
+
|
8
|
+
The version of the OpenAPI document: 3.40.0
|
9
|
+
Contact: b2bhelpdesk@polar.com
|
10
|
+
Generated by: https://openapi-generator.tech
|
11
|
+
OpenAPI Generator version: 4.3.0
|
12
|
+
|
13
|
+
=end
|
14
|
+
|
15
|
+
$:.push File.expand_path("../lib", __FILE__)
|
16
|
+
|
17
|
+
Gem::Specification.new do |s|
|
18
|
+
s.name = "polar_accesslink"
|
19
|
+
s.version = "1.0.1"
|
20
|
+
s.platform = Gem::Platform::RUBY
|
21
|
+
s.authors = ["OpenAPI-Generator"]
|
22
|
+
s.email = ["b2bhelpdesk@polar.com"]
|
23
|
+
s.homepage = "https://openapi-generator.tech"
|
24
|
+
s.summary = "Polar Accesslink API Ruby Gem"
|
25
|
+
s.description = "Polar Accesslink API Ruby Gem"
|
26
|
+
s.license = "Unlicense"
|
27
|
+
s.required_ruby_version = ">= 1.9"
|
28
|
+
|
29
|
+
s.add_runtime_dependency 'typhoeus', '~> 1.0', '>= 1.0.1'
|
30
|
+
s.add_runtime_dependency 'json', '~> 2.1', '>= 2.1.0'
|
31
|
+
|
32
|
+
s.add_development_dependency 'rspec', '~> 3.6', '>= 3.6.0'
|
33
|
+
|
34
|
+
s.files = `find *`.split("\n").uniq.sort.select { |f| !f.empty? }
|
35
|
+
s.test_files = `find spec/*`.split("\n")
|
36
|
+
s.executables = []
|
37
|
+
s.require_paths = ["lib"]
|
38
|
+
end
|
@@ -0,0 +1,114 @@
|
|
1
|
+
=begin
|
2
|
+
#Polar Accesslink API
|
3
|
+
|
4
|
+
#Polar Accesslink API documentation
|
5
|
+
|
6
|
+
The version of the OpenAPI document: 3.40.0
|
7
|
+
Contact: b2bhelpdesk@polar.com
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
OpenAPI Generator version: 4.3.0
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'spec_helper'
|
14
|
+
require 'json'
|
15
|
+
|
16
|
+
# Unit tests for PolarAccesslink::DailyActivityApi
|
17
|
+
# Automatically generated by openapi-generator (https://openapi-generator.tech)
|
18
|
+
# Please update as you see appropriate
|
19
|
+
describe 'DailyActivityApi' do
|
20
|
+
before do
|
21
|
+
# run before each test
|
22
|
+
@api_instance = PolarAccesslink::DailyActivityApi.new
|
23
|
+
end
|
24
|
+
|
25
|
+
after do
|
26
|
+
# run after each test
|
27
|
+
end
|
28
|
+
|
29
|
+
describe 'test an instance of DailyActivityApi' do
|
30
|
+
it 'should create an instance of DailyActivityApi' do
|
31
|
+
expect(@api_instance).to be_instance_of(PolarAccesslink::DailyActivityApi)
|
32
|
+
end
|
33
|
+
end
|
34
|
+
|
35
|
+
# unit tests for commit_activity_transaction
|
36
|
+
# Commit transaction
|
37
|
+
# After successfully retrieving activity summary data within a transaction, partners are expected to commit the transaction.
|
38
|
+
# @param transaction_id Transaction identifier
|
39
|
+
# @param user_id User identifier
|
40
|
+
# @param [Hash] opts the optional parameters
|
41
|
+
# @return [nil]
|
42
|
+
describe 'commit_activity_transaction test' do
|
43
|
+
it 'should work' do
|
44
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
45
|
+
end
|
46
|
+
end
|
47
|
+
|
48
|
+
# unit tests for create_activity_transaction
|
49
|
+
# Create transaction
|
50
|
+
# Initiate activity transaction. Check for new activity summaries and create a new transaction if found.
|
51
|
+
# @param user_id User identifier
|
52
|
+
# @param [Hash] opts the optional parameters
|
53
|
+
# @return [TransactionLocation]
|
54
|
+
describe 'create_activity_transaction test' do
|
55
|
+
it 'should work' do
|
56
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
57
|
+
end
|
58
|
+
end
|
59
|
+
|
60
|
+
# unit tests for get_activity_summary
|
61
|
+
# Get activity summary
|
62
|
+
# @param user_id User identifier
|
63
|
+
# @param transaction_id Transaction identifier
|
64
|
+
# @param activity_id Activity summary identifier
|
65
|
+
# @param [Hash] opts the optional parameters
|
66
|
+
# @return [Activity]
|
67
|
+
describe 'get_activity_summary test' do
|
68
|
+
it 'should work' do
|
69
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
70
|
+
end
|
71
|
+
end
|
72
|
+
|
73
|
+
# unit tests for get_step_samples
|
74
|
+
# Get step samples
|
75
|
+
# Get activity step samples. Example data can be seen from [appendix](#activity-step-time-series).
|
76
|
+
# @param user_id User identifier
|
77
|
+
# @param transaction_id Transaction identifier
|
78
|
+
# @param activity_id Activity summary identifier
|
79
|
+
# @param [Hash] opts the optional parameters
|
80
|
+
# @return [ActivityStepSamples]
|
81
|
+
describe 'get_step_samples test' do
|
82
|
+
it 'should work' do
|
83
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
84
|
+
end
|
85
|
+
end
|
86
|
+
|
87
|
+
# unit tests for get_zone_samples
|
88
|
+
# Get zone samples
|
89
|
+
# Get activity zone samples. Example data can be seen from [appendix](#activity-zone-time-series).
|
90
|
+
# @param user_id User identifier
|
91
|
+
# @param transaction_id Transaction identifier
|
92
|
+
# @param activity_id Activity summary identifier
|
93
|
+
# @param [Hash] opts the optional parameters
|
94
|
+
# @return [ActivityZoneSamples]
|
95
|
+
describe 'get_zone_samples test' do
|
96
|
+
it 'should work' do
|
97
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
98
|
+
end
|
99
|
+
end
|
100
|
+
|
101
|
+
# unit tests for list_activities
|
102
|
+
# List activities
|
103
|
+
# List new activity data. After successfully initiating a transaction, activity summaries included within it can be retrieved with the provided transactionId.
|
104
|
+
# @param transaction_id Transaction identifier
|
105
|
+
# @param user_id User identifier
|
106
|
+
# @param [Hash] opts the optional parameters
|
107
|
+
# @return [ActivityLog]
|
108
|
+
describe 'list_activities test' do
|
109
|
+
it 'should work' do
|
110
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
111
|
+
end
|
112
|
+
end
|
113
|
+
|
114
|
+
end
|
@@ -0,0 +1,70 @@
|
|
1
|
+
=begin
|
2
|
+
#Polar Accesslink API
|
3
|
+
|
4
|
+
#Polar Accesslink API documentation
|
5
|
+
|
6
|
+
The version of the OpenAPI document: 3.40.0
|
7
|
+
Contact: b2bhelpdesk@polar.com
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
OpenAPI Generator version: 4.3.0
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'spec_helper'
|
14
|
+
require 'json'
|
15
|
+
|
16
|
+
# Unit tests for PolarAccesslink::ExercisesApi
|
17
|
+
# Automatically generated by openapi-generator (https://openapi-generator.tech)
|
18
|
+
# Please update as you see appropriate
|
19
|
+
describe 'ExercisesApi' do
|
20
|
+
before do
|
21
|
+
# run before each test
|
22
|
+
@api_instance = PolarAccesslink::ExercisesApi.new
|
23
|
+
end
|
24
|
+
|
25
|
+
after do
|
26
|
+
# run after each test
|
27
|
+
end
|
28
|
+
|
29
|
+
describe 'test an instance of ExercisesApi' do
|
30
|
+
it 'should create an instance of ExercisesApi' do
|
31
|
+
expect(@api_instance).to be_instance_of(PolarAccesslink::ExercisesApi)
|
32
|
+
end
|
33
|
+
end
|
34
|
+
|
35
|
+
# unit tests for get_exercise_fit_without_transaction
|
36
|
+
# Get exercise FIT
|
37
|
+
# FIT file for users exercise.
|
38
|
+
# @param exercise_id Hashed exercise id.
|
39
|
+
# @param [Hash] opts the optional parameters
|
40
|
+
# @return [String]
|
41
|
+
describe 'get_exercise_fit_without_transaction test' do
|
42
|
+
it 'should work' do
|
43
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
44
|
+
end
|
45
|
+
end
|
46
|
+
|
47
|
+
# unit tests for get_exercise_without_transaction
|
48
|
+
# Get exercise
|
49
|
+
# Get users exercise using hashed id.
|
50
|
+
# @param exercise_id Hashed exercise id.
|
51
|
+
# @param [Hash] opts the optional parameters
|
52
|
+
# @return [ExerciseHashId]
|
53
|
+
describe 'get_exercise_without_transaction test' do
|
54
|
+
it 'should work' do
|
55
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
56
|
+
end
|
57
|
+
end
|
58
|
+
|
59
|
+
# unit tests for list_exercises_without_transaction
|
60
|
+
# List exercises
|
61
|
+
# List users exercises available in Accesslink.
|
62
|
+
# @param [Hash] opts the optional parameters
|
63
|
+
# @return [Array<ExerciseHashId>]
|
64
|
+
describe 'list_exercises_without_transaction test' do
|
65
|
+
it 'should work' do
|
66
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
67
|
+
end
|
68
|
+
end
|
69
|
+
|
70
|
+
end
|
@@ -0,0 +1,87 @@
|
|
1
|
+
=begin
|
2
|
+
#Polar Accesslink API
|
3
|
+
|
4
|
+
#Polar Accesslink API documentation
|
5
|
+
|
6
|
+
The version of the OpenAPI document: 3.40.0
|
7
|
+
Contact: b2bhelpdesk@polar.com
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
OpenAPI Generator version: 4.3.0
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'spec_helper'
|
14
|
+
require 'json'
|
15
|
+
|
16
|
+
# Unit tests for PolarAccesslink::PhysicalInfoApi
|
17
|
+
# Automatically generated by openapi-generator (https://openapi-generator.tech)
|
18
|
+
# Please update as you see appropriate
|
19
|
+
describe 'PhysicalInfoApi' do
|
20
|
+
before do
|
21
|
+
# run before each test
|
22
|
+
@api_instance = PolarAccesslink::PhysicalInfoApi.new
|
23
|
+
end
|
24
|
+
|
25
|
+
after do
|
26
|
+
# run after each test
|
27
|
+
end
|
28
|
+
|
29
|
+
describe 'test an instance of PhysicalInfoApi' do
|
30
|
+
it 'should create an instance of PhysicalInfoApi' do
|
31
|
+
expect(@api_instance).to be_instance_of(PolarAccesslink::PhysicalInfoApi)
|
32
|
+
end
|
33
|
+
end
|
34
|
+
|
35
|
+
# unit tests for commit_physical_info_transaction
|
36
|
+
# Commit transaction
|
37
|
+
# After successfully retrieving physical information within a transaction, partners are expected to commit the transaction.
|
38
|
+
# @param transaction_id Transaction identifier
|
39
|
+
# @param user_id User identifier
|
40
|
+
# @param [Hash] opts the optional parameters
|
41
|
+
# @return [nil]
|
42
|
+
describe 'commit_physical_info_transaction test' do
|
43
|
+
it 'should work' do
|
44
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
45
|
+
end
|
46
|
+
end
|
47
|
+
|
48
|
+
# unit tests for create_physical_info_transaction
|
49
|
+
# Create transaction
|
50
|
+
# Initiate physical info transaction. Check for new physical info and create a new transaction if found.
|
51
|
+
# @param user_id User identifier
|
52
|
+
# @param [Hash] opts the optional parameters
|
53
|
+
# @return [TransactionLocation]
|
54
|
+
describe 'create_physical_info_transaction test' do
|
55
|
+
it 'should work' do
|
56
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
57
|
+
end
|
58
|
+
end
|
59
|
+
|
60
|
+
# unit tests for get_physical_info
|
61
|
+
# Get physical info
|
62
|
+
# Get physical info entity data
|
63
|
+
# @param user_id User identifier
|
64
|
+
# @param transaction_id Transaction identifier
|
65
|
+
# @param physical_info_id Physical information identifier
|
66
|
+
# @param [Hash] opts the optional parameters
|
67
|
+
# @return [PhysicalInformation]
|
68
|
+
describe 'get_physical_info test' do
|
69
|
+
it 'should work' do
|
70
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
71
|
+
end
|
72
|
+
end
|
73
|
+
|
74
|
+
# unit tests for list_physical_infos
|
75
|
+
# List physical infos
|
76
|
+
# List new physical info data. After successfully initiating a transaction, physical infos included within it can be retrieved with the provided transactionId.
|
77
|
+
# @param transaction_id Transaction identifier
|
78
|
+
# @param user_id User identifier
|
79
|
+
# @param [Hash] opts the optional parameters
|
80
|
+
# @return [PhysicalInformations]
|
81
|
+
describe 'list_physical_infos test' do
|
82
|
+
it 'should work' do
|
83
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
84
|
+
end
|
85
|
+
end
|
86
|
+
|
87
|
+
end
|
@@ -0,0 +1,46 @@
|
|
1
|
+
=begin
|
2
|
+
#Polar Accesslink API
|
3
|
+
|
4
|
+
#Polar Accesslink API documentation
|
5
|
+
|
6
|
+
The version of the OpenAPI document: 3.40.0
|
7
|
+
Contact: b2bhelpdesk@polar.com
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
OpenAPI Generator version: 4.3.0
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'spec_helper'
|
14
|
+
require 'json'
|
15
|
+
|
16
|
+
# Unit tests for PolarAccesslink::PullNotificationsApi
|
17
|
+
# Automatically generated by openapi-generator (https://openapi-generator.tech)
|
18
|
+
# Please update as you see appropriate
|
19
|
+
describe 'PullNotificationsApi' do
|
20
|
+
before do
|
21
|
+
# run before each test
|
22
|
+
@api_instance = PolarAccesslink::PullNotificationsApi.new
|
23
|
+
end
|
24
|
+
|
25
|
+
after do
|
26
|
+
# run after each test
|
27
|
+
end
|
28
|
+
|
29
|
+
describe 'test an instance of PullNotificationsApi' do
|
30
|
+
it 'should create an instance of PullNotificationsApi' do
|
31
|
+
expect(@api_instance).to be_instance_of(PolarAccesslink::PullNotificationsApi)
|
32
|
+
end
|
33
|
+
end
|
34
|
+
|
35
|
+
# unit tests for list
|
36
|
+
# List
|
37
|
+
# Get list of available exercises and activities for users
|
38
|
+
# @param [Hash] opts the optional parameters
|
39
|
+
# @return [AvailableUserDatas]
|
40
|
+
describe 'list test' do
|
41
|
+
it 'should work' do
|
42
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
43
|
+
end
|
44
|
+
end
|
45
|
+
|
46
|
+
end
|
@@ -0,0 +1,172 @@
|
|
1
|
+
=begin
|
2
|
+
#Polar Accesslink API
|
3
|
+
|
4
|
+
#Polar Accesslink API documentation
|
5
|
+
|
6
|
+
The version of the OpenAPI document: 3.40.0
|
7
|
+
Contact: b2bhelpdesk@polar.com
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
OpenAPI Generator version: 4.3.0
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'spec_helper'
|
14
|
+
require 'json'
|
15
|
+
|
16
|
+
# Unit tests for PolarAccesslink::TrainingDataApi
|
17
|
+
# Automatically generated by openapi-generator (https://openapi-generator.tech)
|
18
|
+
# Please update as you see appropriate
|
19
|
+
describe 'TrainingDataApi' do
|
20
|
+
before do
|
21
|
+
# run before each test
|
22
|
+
@api_instance = PolarAccesslink::TrainingDataApi.new
|
23
|
+
end
|
24
|
+
|
25
|
+
after do
|
26
|
+
# run after each test
|
27
|
+
end
|
28
|
+
|
29
|
+
describe 'test an instance of TrainingDataApi' do
|
30
|
+
it 'should create an instance of TrainingDataApi' do
|
31
|
+
expect(@api_instance).to be_instance_of(PolarAccesslink::TrainingDataApi)
|
32
|
+
end
|
33
|
+
end
|
34
|
+
|
35
|
+
# unit tests for commit_exercise_transaction
|
36
|
+
# Commit transaction
|
37
|
+
# After successfully retrieving training session data within a transaction, partners are expected to commit the transaction.
|
38
|
+
# @param transaction_id Transaction identifier
|
39
|
+
# @param user_id User identifier
|
40
|
+
# @param [Hash] opts the optional parameters
|
41
|
+
# @return [nil]
|
42
|
+
describe 'commit_exercise_transaction test' do
|
43
|
+
it 'should work' do
|
44
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
45
|
+
end
|
46
|
+
end
|
47
|
+
|
48
|
+
# unit tests for create_exercise_transaction
|
49
|
+
# Create transaction
|
50
|
+
# Check for new training data and create a new transaction if found.
|
51
|
+
# @param user_id User identifier
|
52
|
+
# @param [Hash] opts the optional parameters
|
53
|
+
# @return [TransactionLocation]
|
54
|
+
describe 'create_exercise_transaction test' do
|
55
|
+
it 'should work' do
|
56
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
57
|
+
end
|
58
|
+
end
|
59
|
+
|
60
|
+
# unit tests for get_available_samples
|
61
|
+
# Get available samples
|
62
|
+
# Retrieve list of links to available samples in training session
|
63
|
+
# @param user_id User identifier
|
64
|
+
# @param transaction_id Transaction identifier
|
65
|
+
# @param exercise_id Exercise identifier
|
66
|
+
# @param [Hash] opts the optional parameters
|
67
|
+
# @return [Samples]
|
68
|
+
describe 'get_available_samples test' do
|
69
|
+
it 'should work' do
|
70
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
71
|
+
end
|
72
|
+
end
|
73
|
+
|
74
|
+
# unit tests for get_exercise_summary
|
75
|
+
# Get exercise summary
|
76
|
+
# Retrieve training session summary data
|
77
|
+
# @param user_id User identifier
|
78
|
+
# @param transaction_id Transaction identifier
|
79
|
+
# @param exercise_id Exercise identifier
|
80
|
+
# @param [Hash] opts the optional parameters
|
81
|
+
# @return [Exercise]
|
82
|
+
describe 'get_exercise_summary test' do
|
83
|
+
it 'should work' do
|
84
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
85
|
+
end
|
86
|
+
end
|
87
|
+
|
88
|
+
# unit tests for get_fit
|
89
|
+
# Get FIT (beta)
|
90
|
+
# Retrieve exercise in FIT format. **Note!** This interface is in beta phase. If there is anything we can help you with or you want to give us feedback, please contact [Support](#support).
|
91
|
+
# @param user_id User identifier
|
92
|
+
# @param transaction_id Transaction identifier
|
93
|
+
# @param exercise_id Exercise identifier
|
94
|
+
# @param [Hash] opts the optional parameters
|
95
|
+
# @return [String]
|
96
|
+
describe 'get_fit test' do
|
97
|
+
it 'should work' do
|
98
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
99
|
+
end
|
100
|
+
end
|
101
|
+
|
102
|
+
# unit tests for get_gpx
|
103
|
+
# Get GPX
|
104
|
+
# Retrieve training session summary data in GPX format
|
105
|
+
# @param user_id User identifier
|
106
|
+
# @param transaction_id Transaction identifier
|
107
|
+
# @param exercise_id Exercise identifier
|
108
|
+
# @param [Hash] opts the optional parameters
|
109
|
+
# @return [String]
|
110
|
+
describe 'get_gpx test' do
|
111
|
+
it 'should work' do
|
112
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
113
|
+
end
|
114
|
+
end
|
115
|
+
|
116
|
+
# unit tests for get_heart_rate_zones
|
117
|
+
# Get heart rate zones
|
118
|
+
# Retrieve heart rate zones in training session
|
119
|
+
# @param user_id User identifier
|
120
|
+
# @param transaction_id Transaction identifier
|
121
|
+
# @param exercise_id Exercise identifier
|
122
|
+
# @param [Hash] opts the optional parameters
|
123
|
+
# @return [Zones]
|
124
|
+
describe 'get_heart_rate_zones test' do
|
125
|
+
it 'should work' do
|
126
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
127
|
+
end
|
128
|
+
end
|
129
|
+
|
130
|
+
# unit tests for get_samples
|
131
|
+
# Get samples
|
132
|
+
# Retrieve sample data of given type
|
133
|
+
# @param type_id Sample type id
|
134
|
+
# @param user_id User identifier
|
135
|
+
# @param transaction_id Transaction identifier
|
136
|
+
# @param exercise_id Exercise identifier
|
137
|
+
# @param [Hash] opts the optional parameters
|
138
|
+
# @return [Sample]
|
139
|
+
describe 'get_samples test' do
|
140
|
+
it 'should work' do
|
141
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
142
|
+
end
|
143
|
+
end
|
144
|
+
|
145
|
+
# unit tests for get_tcx
|
146
|
+
# Get TCX
|
147
|
+
# Retrieve exercise in TCX format
|
148
|
+
# @param user_id User identifier
|
149
|
+
# @param transaction_id Transaction identifier
|
150
|
+
# @param exercise_id Exercise identifier
|
151
|
+
# @param [Hash] opts the optional parameters
|
152
|
+
# @return [String]
|
153
|
+
describe 'get_tcx test' do
|
154
|
+
it 'should work' do
|
155
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
156
|
+
end
|
157
|
+
end
|
158
|
+
|
159
|
+
# unit tests for list_exercises
|
160
|
+
# List exercises
|
161
|
+
# After successfully initiating a transaction, training sessions included within it can be retrieved with the provided transactionId.
|
162
|
+
# @param transaction_id Transaction identifier
|
163
|
+
# @param user_id User identifier
|
164
|
+
# @param [Hash] opts the optional parameters
|
165
|
+
# @return [Exercises]
|
166
|
+
describe 'list_exercises test' do
|
167
|
+
it 'should work' do
|
168
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
169
|
+
end
|
170
|
+
end
|
171
|
+
|
172
|
+
end
|