polar_accesslink 1.0.2 → 1.0.3

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.
Files changed (141) hide show
  1. checksums.yaml +4 -4
  2. data/Gemfile.lock +9 -5
  3. data/README.md +20 -65
  4. data/Rakefile +0 -2
  5. data/docs/DailyActivityApi.md +96 -123
  6. data/docs/ExercisesApi.md +35 -55
  7. data/docs/NightlyRechargeApi.md +96 -0
  8. data/docs/PhysicalInfoApi.md +60 -79
  9. data/docs/PullNotificationsApi.md +11 -20
  10. data/docs/SleepApi.md +137 -0
  11. data/docs/TrainingDataApi.md +175 -213
  12. data/docs/UsersApi.md +33 -56
  13. data/docs/WebhooksApi.md +43 -80
  14. data/git_push.sh +55 -0
  15. data/lib/polar_accesslink.rb +5 -36
  16. data/lib/polar_accesslink/api/daily_activity_api.rb +101 -201
  17. data/lib/polar_accesslink/api/exercises_api.rb +43 -81
  18. data/lib/polar_accesslink/api/nightly_recharge_api.rb +115 -0
  19. data/lib/polar_accesslink/api/physical_info_api.rb +65 -114
  20. data/lib/polar_accesslink/api/pull_notifications_api.rb +15 -27
  21. data/lib/polar_accesslink/api/sleep_api.rb +158 -0
  22. data/lib/polar_accesslink/api/training_data_api.rb +178 -332
  23. data/lib/polar_accesslink/api/users_api.rb +42 -96
  24. data/lib/polar_accesslink/api/webhooks_api.rb +59 -126
  25. data/lib/polar_accesslink/api_client.rb +45 -41
  26. data/lib/polar_accesslink/api_error.rb +3 -22
  27. data/lib/polar_accesslink/configuration.rb +9 -62
  28. data/lib/polar_accesslink/version.rb +3 -3
  29. data/polar_accesslink.gemspec +2 -1
  30. data/spec/api/daily_activity_api_spec.rb +11 -11
  31. data/spec/api/exercises_api_spec.rb +9 -9
  32. data/spec/api/nightly_recharge_api_spec.rb +58 -0
  33. data/spec/api/physical_info_api_spec.rb +9 -9
  34. data/spec/api/pull_notifications_api_spec.rb +7 -7
  35. data/spec/api/sleep_api_spec.rb +69 -0
  36. data/spec/api/training_data_api_spec.rb +16 -15
  37. data/spec/api/users_api_spec.rb +8 -9
  38. data/spec/api/webhooks_api_spec.rb +11 -13
  39. data/spec/api_client_spec.rb +21 -4
  40. data/spec/configuration_spec.rb +6 -6
  41. data/spec/spec_helper.rb +3 -3
  42. metadata +36 -145
  43. data/docs/Activity.md +0 -33
  44. data/docs/ActivityLog.md +0 -17
  45. data/docs/ActivityStepSample.md +0 -19
  46. data/docs/ActivityStepSamples.md +0 -19
  47. data/docs/ActivityZoneSample.md +0 -19
  48. data/docs/ActivityZoneSamples.md +0 -19
  49. data/docs/AvailableUserData.md +0 -21
  50. data/docs/AvailableUserDatas.md +0 -17
  51. data/docs/CreatedWebhook.md +0 -17
  52. data/docs/CreatedWebhookData.md +0 -23
  53. data/docs/DurationZone.md +0 -19
  54. data/docs/Error.md +0 -25
  55. data/docs/Exercise.md +0 -47
  56. data/docs/ExerciseHashId.md +0 -45
  57. data/docs/Exercises.md +0 -17
  58. data/docs/HeartRate.md +0 -19
  59. data/docs/PhysicalInformation.md +0 -39
  60. data/docs/PhysicalInformations.md +0 -17
  61. data/docs/Register.md +0 -17
  62. data/docs/Sample.md +0 -21
  63. data/docs/Samples.md +0 -17
  64. data/docs/TransactionLocation.md +0 -19
  65. data/docs/User.md +0 -35
  66. data/docs/UserExtraInfo.md +0 -21
  67. data/docs/WebhookInfo.md +0 -17
  68. data/docs/WebhookInfoData.md +0 -21
  69. data/docs/WebhookPatch.md +0 -19
  70. data/docs/WebhookPayload.md +0 -25
  71. data/docs/WebhookPing.md +0 -19
  72. data/docs/WebhookRequest.md +0 -19
  73. data/docs/WebhookType.md +0 -16
  74. data/docs/Zone.md +0 -23
  75. data/docs/Zones.md +0 -17
  76. data/lib/polar_accesslink/models/activity.rb +0 -288
  77. data/lib/polar_accesslink/models/activity_log.rb +0 -210
  78. data/lib/polar_accesslink/models/activity_step_sample.rb +0 -218
  79. data/lib/polar_accesslink/models/activity_step_samples.rb +0 -220
  80. data/lib/polar_accesslink/models/activity_zone_sample.rb +0 -220
  81. data/lib/polar_accesslink/models/activity_zone_samples.rb +0 -220
  82. data/lib/polar_accesslink/models/available_user_data.rb +0 -262
  83. data/lib/polar_accesslink/models/available_user_datas.rb +0 -210
  84. data/lib/polar_accesslink/models/created_webhook.rb +0 -206
  85. data/lib/polar_accesslink/models/created_webhook_data.rb +0 -236
  86. data/lib/polar_accesslink/models/duration_zone.rb +0 -218
  87. data/lib/polar_accesslink/models/error.rb +0 -248
  88. data/lib/polar_accesslink/models/exercise.rb +0 -357
  89. data/lib/polar_accesslink/models/exercise_hash_id.rb +0 -347
  90. data/lib/polar_accesslink/models/exercises.rb +0 -210
  91. data/lib/polar_accesslink/models/heart_rate.rb +0 -218
  92. data/lib/polar_accesslink/models/physical_information.rb +0 -352
  93. data/lib/polar_accesslink/models/physical_informations.rb +0 -210
  94. data/lib/polar_accesslink/models/register.rb +0 -213
  95. data/lib/polar_accesslink/models/sample.rb +0 -228
  96. data/lib/polar_accesslink/models/samples.rb +0 -210
  97. data/lib/polar_accesslink/models/transaction_location.rb +0 -218
  98. data/lib/polar_accesslink/models/user.rb +0 -334
  99. data/lib/polar_accesslink/models/user_extra_info.rb +0 -228
  100. data/lib/polar_accesslink/models/webhook_info.rb +0 -206
  101. data/lib/polar_accesslink/models/webhook_info_data.rb +0 -226
  102. data/lib/polar_accesslink/models/webhook_patch.rb +0 -219
  103. data/lib/polar_accesslink/models/webhook_payload.rb +0 -246
  104. data/lib/polar_accesslink/models/webhook_ping.rb +0 -252
  105. data/lib/polar_accesslink/models/webhook_request.rb +0 -229
  106. data/lib/polar_accesslink/models/webhook_type.rb +0 -37
  107. data/lib/polar_accesslink/models/zone.rb +0 -238
  108. data/lib/polar_accesslink/models/zones.rb +0 -210
  109. data/spec/models/activity_log_spec.rb +0 -41
  110. data/spec/models/activity_spec.rb +0 -89
  111. data/spec/models/activity_step_sample_spec.rb +0 -47
  112. data/spec/models/activity_step_samples_spec.rb +0 -47
  113. data/spec/models/activity_zone_sample_spec.rb +0 -47
  114. data/spec/models/activity_zone_samples_spec.rb +0 -47
  115. data/spec/models/available_user_data_spec.rb +0 -57
  116. data/spec/models/available_user_datas_spec.rb +0 -41
  117. data/spec/models/created_webhook_data_spec.rb +0 -59
  118. data/spec/models/created_webhook_spec.rb +0 -41
  119. data/spec/models/duration_zone_spec.rb +0 -47
  120. data/spec/models/error_spec.rb +0 -65
  121. data/spec/models/exercise_hash_id_spec.rb +0 -125
  122. data/spec/models/exercise_spec.rb +0 -131
  123. data/spec/models/exercises_spec.rb +0 -41
  124. data/spec/models/heart_rate_spec.rb +0 -47
  125. data/spec/models/physical_information_spec.rb +0 -111
  126. data/spec/models/physical_informations_spec.rb +0 -41
  127. data/spec/models/register_spec.rb +0 -41
  128. data/spec/models/sample_spec.rb +0 -53
  129. data/spec/models/samples_spec.rb +0 -41
  130. data/spec/models/transaction_location_spec.rb +0 -47
  131. data/spec/models/user_extra_info_spec.rb +0 -53
  132. data/spec/models/user_spec.rb +0 -99
  133. data/spec/models/webhook_info_data_spec.rb +0 -53
  134. data/spec/models/webhook_info_spec.rb +0 -41
  135. data/spec/models/webhook_patch_spec.rb +0 -47
  136. data/spec/models/webhook_payload_spec.rb +0 -65
  137. data/spec/models/webhook_ping_spec.rb +0 -51
  138. data/spec/models/webhook_request_spec.rb +0 -47
  139. data/spec/models/webhook_type_spec.rb +0 -35
  140. data/spec/models/zone_spec.rb +0 -59
  141. data/spec/models/zones_spec.rb +0 -41
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: e6d0001a2253f48457025742a39870462a86b311fcd5344c3aadd6b1a1d74eb5
4
- data.tar.gz: f3df20e4406c0ddf5cc4ef784b6ca605335373193b051ea692b118347858b46c
3
+ metadata.gz: aa00edecd99d5ee22b5c4b869903b9eff9b378c0a2f4aa47081ea15c5d0fb1c7
4
+ data.tar.gz: c3ce6a7fe85ee2dbb168f1bf2b53129c88a468aeda6d1994516d9d992fa099f6
5
5
  SHA512:
6
- metadata.gz: 96784c2818143f572c2d35a5602e39d6c67b9c1ee36c67b0fd733d0142cd754f61970781f14f17bff9d6286f4d5dba89be890595509d94e50cac3a54b14a136c
7
- data.tar.gz: d00fa76ed45b8dd5ae0b27eb961723a8bc1903706a305106c9940ce2ef01f57fed0fcb7b987400786fc16b8a21121b7343e0cef656dacd868e1a15078f66c749
6
+ metadata.gz: 8a9ffe69beef8c9700a923788893ea44136a69baf0a98aaacec439976cae5eacdc92fce08816762f247e0980b46d650ae69674718c990da789d71e87ce0dc1b0
7
+ data.tar.gz: dd71623cb72bee1c61bf11d81413b8ef5684241ec73481b6497b11c4b4ba9d1a1b15ba1f51d711edb41e098cd0473d0df79e21946ed1a67ec2a552c7482e8aec
@@ -1,22 +1,25 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- polar_accesslink (1.0.2)
4
+ polar_accesslink (1.0.3)
5
+ addressable (~> 2.7)
5
6
  json (~> 2.1, >= 2.1.0)
6
7
  typhoeus (~> 1.0, >= 1.0.1)
7
8
 
8
9
  GEM
9
10
  remote: https://rubygems.org/
10
11
  specs:
12
+ addressable (2.7.0)
13
+ public_suffix (>= 2.0.2, < 5.0)
11
14
  ast (2.4.0)
12
15
  byebug (11.1.1)
13
16
  coderay (1.1.2)
14
17
  diff-lcs (1.3)
15
18
  ethon (0.12.0)
16
19
  ffi (>= 1.3.0)
17
- ffi (1.12.2)
20
+ ffi (1.13.1)
18
21
  jaro_winkler (1.5.4)
19
- json (2.3.0)
22
+ json (2.3.1)
20
23
  method_source (1.0.0)
21
24
  parallel (1.19.1)
22
25
  parser (2.7.0.5)
@@ -28,6 +31,7 @@ GEM
28
31
  byebug (~> 11.0)
29
32
  pry (~> 0.13.0)
30
33
  psych (3.1.0)
34
+ public_suffix (4.0.6)
31
35
  rainbow (3.0.0)
32
36
  rake (13.0.1)
33
37
  rspec (3.9.0)
@@ -52,7 +56,7 @@ GEM
52
56
  ruby-progressbar (~> 1.7)
53
57
  unicode-display_width (>= 1.4.0, < 1.6)
54
58
  ruby-progressbar (1.10.1)
55
- typhoeus (1.3.1)
59
+ typhoeus (1.4.0)
56
60
  ethon (>= 0.9.0)
57
61
  unicode-display_width (1.5.0)
58
62
 
@@ -67,4 +71,4 @@ DEPENDENCIES
67
71
  rubocop (~> 0.66.0)
68
72
 
69
73
  BUNDLED WITH
70
- 2.0.2
74
+ 2.1.4
data/README.md CHANGED
@@ -1,15 +1,15 @@
1
- # polar_accesslink
1
+ # PolarAccesslink
2
+
2
3
  PolarAccesslink - the Ruby gem for the Polar Accesslink API
3
4
 
4
- ## Polar Accesslink API documentation
5
+ Polar Accesslink API documentation
5
6
 
6
- This SDK is automatically generated by the [OpenAPI Generator](https://openapi-generator.tech) project:
7
+ This SDK is automatically generated by the [Swagger Codegen](https://github.com/swagger-api/swagger-codegen) project:
7
8
 
8
- - API version: 3.40.0
9
+ - API version: 3.59.0
9
10
  - Package version: 1.0.0
10
- - Build package: org.openapitools.codegen.languages.RubyClientCodegen
11
+ - Build package: io.swagger.codegen.languages.RubyClientCodegen
11
12
  For more information, please visit [https://www.polar.com/accesslink](https://www.polar.com/accesslink)
12
- - License: [Polar Electro AccessLink Limited License Agreement](https://www.polar.com/sites/default/files/static/ACL_Ltd_License_Agreement.pdf)
13
13
 
14
14
  ## Installation
15
15
 
@@ -26,7 +26,6 @@ Then either install the gem locally:
26
26
  ```shell
27
27
  gem install ./polar_accesslink-1.0.0.gem
28
28
  ```
29
-
30
29
  (for development, run `gem install --dev ./polar_accesslink-1.0.0.gem` to install the development dependencies)
31
30
 
32
31
  or publish the gem to a gem hosting service, e.g. [RubyGems](https://rubygems.org/).
@@ -37,9 +36,9 @@ Finally add this to the Gemfile:
37
36
 
38
37
  ### Install from Git
39
38
 
40
- 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 Gemfile:
39
+ If the Ruby gem is hosted at a git repository: https://github.com/YOUR_GIT_USERNAME/PolarAccesslink, then add the following in the Gemfile:
41
40
 
42
- gem 'polar_accesslink', :git => 'https://github.com/GIT_USER_ID/GIT_REPO_ID.git'
41
+ gem 'polar_accesslink', :git => 'https://github.com/udiudi/PolarAccesslink.git'
43
42
 
44
43
  ### Include the Ruby code directly
45
44
 
@@ -52,20 +51,16 @@ ruby -Ilib script.rb
52
51
  ## Getting Started
53
52
 
54
53
  Please follow the [installation](#installation) procedure and then run the following code:
55
-
56
54
  ```ruby
57
55
  # Load the gem
58
56
  require 'polar_accesslink'
59
57
 
60
- # Setup authorization
61
- PolarAccesslink.configure do |config|
62
- # Configure OAuth2 access token for authorization: OAuth2
63
- config.access_token = 'YOUR ACCESS TOKEN'
64
- end
65
-
66
58
  api_instance = PolarAccesslink::DailyActivityApi.new
67
- transaction_id = 56 # Integer | Transaction identifier
68
- user_id = 56 # Integer | User identifier
59
+
60
+ transaction_id = nil # Object | Transaction identifier
61
+
62
+ user_id = nil # Object | User identifier
63
+
69
64
 
70
65
  begin
71
66
  #Commit transaction
@@ -78,7 +73,7 @@ end
78
73
 
79
74
  ## Documentation for API Endpoints
80
75
 
81
- All URIs are relative to *https://www.polaraccesslink.com*
76
+ All URIs are relative to *https://localhost*
82
77
 
83
78
  Class | Method | HTTP request | Description
84
79
  ------------ | ------------- | ------------- | -------------
@@ -91,11 +86,16 @@ Class | Method | HTTP request | Description
91
86
  *PolarAccesslink::ExercisesApi* | [**get_exercise_fit_without_transaction**](docs/ExercisesApi.md#get_exercise_fit_without_transaction) | **GET** /v3/exercises/{exerciseId}/fit | Get exercise FIT
92
87
  *PolarAccesslink::ExercisesApi* | [**get_exercise_without_transaction**](docs/ExercisesApi.md#get_exercise_without_transaction) | **GET** /v3/exercises/{exerciseId} | Get exercise
93
88
  *PolarAccesslink::ExercisesApi* | [**list_exercises_without_transaction**](docs/ExercisesApi.md#list_exercises_without_transaction) | **GET** /v3/exercises | List exercises
89
+ *PolarAccesslink::NightlyRechargeApi* | [**list_nightly_recharge**](docs/NightlyRechargeApi.md#list_nightly_recharge) | **GET** /v3/users/nightly-recharge | List Nightly Recharges
90
+ *PolarAccesslink::NightlyRechargeApi* | [**v3_users_nightly_recharge_date_get**](docs/NightlyRechargeApi.md#v3_users_nightly_recharge_date_get) | **GET** /v3/users/nightly-recharge/{date} | Get Nightly Recharge
94
91
  *PolarAccesslink::PhysicalInfoApi* | [**commit_physical_info_transaction**](docs/PhysicalInfoApi.md#commit_physical_info_transaction) | **PUT** /v3/users/{user-id}/physical-information-transactions/{transaction-id} | Commit transaction
95
92
  *PolarAccesslink::PhysicalInfoApi* | [**create_physical_info_transaction**](docs/PhysicalInfoApi.md#create_physical_info_transaction) | **POST** /v3/users/{user-id}/physical-information-transactions | Create transaction
96
93
  *PolarAccesslink::PhysicalInfoApi* | [**get_physical_info**](docs/PhysicalInfoApi.md#get_physical_info) | **GET** /v3/users/{user-id}/physical-information-transactions/{transaction-id}/physical-informations/{physical-info-id} | Get physical info
97
94
  *PolarAccesslink::PhysicalInfoApi* | [**list_physical_infos**](docs/PhysicalInfoApi.md#list_physical_infos) | **GET** /v3/users/{user-id}/physical-information-transactions/{transaction-id} | List physical infos
98
95
  *PolarAccesslink::PullNotificationsApi* | [**list**](docs/PullNotificationsApi.md#list) | **GET** /v3/notifications | List
96
+ *PolarAccesslink::SleepApi* | [**list_nights**](docs/SleepApi.md#list_nights) | **GET** /v3/users/sleep | List nights
97
+ *PolarAccesslink::SleepApi* | [**v3_users_sleep_available_get**](docs/SleepApi.md#v3_users_sleep_available_get) | **GET** /v3/users/sleep/available | Get available sleep times
98
+ *PolarAccesslink::SleepApi* | [**v3_users_sleep_date_get**](docs/SleepApi.md#v3_users_sleep_date_get) | **GET** /v3/users/sleep/{date} | Get Sleep
99
99
  *PolarAccesslink::TrainingDataApi* | [**commit_exercise_transaction**](docs/TrainingDataApi.md#commit_exercise_transaction) | **PUT** /v3/users/{user-id}/exercise-transactions/{transaction-id} | Commit transaction
100
100
  *PolarAccesslink::TrainingDataApi* | [**create_exercise_transaction**](docs/TrainingDataApi.md#create_exercise_transaction) | **POST** /v3/users/{user-id}/exercise-transactions | Create transaction
101
101
  *PolarAccesslink::TrainingDataApi* | [**get_available_samples**](docs/TrainingDataApi.md#get_available_samples) | **GET** /v3/users/{user-id}/exercise-transactions/{transaction-id}/exercises/{exercise-id}/samples | Get available samples
@@ -117,54 +117,9 @@ Class | Method | HTTP request | Description
117
117
 
118
118
  ## Documentation for Models
119
119
 
120
- - [PolarAccesslink::Activity](docs/Activity.md)
121
- - [PolarAccesslink::ActivityLog](docs/ActivityLog.md)
122
- - [PolarAccesslink::ActivityStepSample](docs/ActivityStepSample.md)
123
- - [PolarAccesslink::ActivityStepSamples](docs/ActivityStepSamples.md)
124
- - [PolarAccesslink::ActivityZoneSample](docs/ActivityZoneSample.md)
125
- - [PolarAccesslink::ActivityZoneSamples](docs/ActivityZoneSamples.md)
126
- - [PolarAccesslink::AvailableUserData](docs/AvailableUserData.md)
127
- - [PolarAccesslink::AvailableUserDatas](docs/AvailableUserDatas.md)
128
- - [PolarAccesslink::CreatedWebhook](docs/CreatedWebhook.md)
129
- - [PolarAccesslink::CreatedWebhookData](docs/CreatedWebhookData.md)
130
- - [PolarAccesslink::DurationZone](docs/DurationZone.md)
131
- - [PolarAccesslink::Error](docs/Error.md)
132
- - [PolarAccesslink::Exercise](docs/Exercise.md)
133
- - [PolarAccesslink::ExerciseHashId](docs/ExerciseHashId.md)
134
- - [PolarAccesslink::Exercises](docs/Exercises.md)
135
- - [PolarAccesslink::HeartRate](docs/HeartRate.md)
136
- - [PolarAccesslink::PhysicalInformation](docs/PhysicalInformation.md)
137
- - [PolarAccesslink::PhysicalInformations](docs/PhysicalInformations.md)
138
- - [PolarAccesslink::Register](docs/Register.md)
139
- - [PolarAccesslink::Sample](docs/Sample.md)
140
- - [PolarAccesslink::Samples](docs/Samples.md)
141
- - [PolarAccesslink::TransactionLocation](docs/TransactionLocation.md)
142
- - [PolarAccesslink::User](docs/User.md)
143
- - [PolarAccesslink::UserExtraInfo](docs/UserExtraInfo.md)
144
- - [PolarAccesslink::WebhookInfo](docs/WebhookInfo.md)
145
- - [PolarAccesslink::WebhookInfoData](docs/WebhookInfoData.md)
146
- - [PolarAccesslink::WebhookPatch](docs/WebhookPatch.md)
147
- - [PolarAccesslink::WebhookPayload](docs/WebhookPayload.md)
148
- - [PolarAccesslink::WebhookPing](docs/WebhookPing.md)
149
- - [PolarAccesslink::WebhookRequest](docs/WebhookRequest.md)
150
- - [PolarAccesslink::WebhookType](docs/WebhookType.md)
151
- - [PolarAccesslink::Zone](docs/Zone.md)
152
- - [PolarAccesslink::Zones](docs/Zones.md)
153
120
 
154
121
 
155
122
  ## Documentation for Authorization
156
123
 
157
-
158
- ### Basic
159
-
160
- - **Type**: HTTP basic authentication
161
-
162
- ### OAuth2
163
-
164
-
165
- - **Type**: OAuth
166
- - **Flow**: accessCode
167
- - **Authorization URL**: https://flow.polar.com/oauth2/authorization
168
- - **Scopes**:
169
- - accesslink.read_all: Allows read access to user&#39;s data
124
+ All endpoints do not require authorization.
170
125
 
data/Rakefile CHANGED
@@ -1,5 +1,3 @@
1
- require "bundler/gem_tasks"
2
-
3
1
  begin
4
2
  require 'rspec/core/rake_task'
5
3
 
@@ -1,6 +1,6 @@
1
1
  # PolarAccesslink::DailyActivityApi
2
2
 
3
- All URIs are relative to *https://www.polaraccesslink.com*
3
+ All URIs are relative to *https://localhost*
4
4
 
5
5
  Method | HTTP request | Description
6
6
  ------------- | ------------- | -------------
@@ -12,9 +12,7 @@ Method | HTTP request | Description
12
12
  [**list_activities**](DailyActivityApi.md#list_activities) | **GET** /v3/users/{user-id}/activity-transactions/{transaction-id} | List activities
13
13
 
14
14
 
15
-
16
- ## commit_activity_transaction
17
-
15
+ # **commit_activity_transaction**
18
16
  > commit_activity_transaction(transaction_id, user_id)
19
17
 
20
18
  Commit transaction
@@ -22,19 +20,16 @@ Commit transaction
22
20
  After successfully retrieving activity summary data within a transaction, partners are expected to commit the transaction.
23
21
 
24
22
  ### Example
25
-
26
23
  ```ruby
27
24
  # load the gem
28
- require 'openapi_client'
29
- # setup authorization
30
- PolarAccesslink.configure do |config|
31
- # Configure OAuth2 access token for authorization: OAuth2
32
- config.access_token = 'YOUR ACCESS TOKEN'
33
- end
25
+ require 'polar_accesslink'
34
26
 
35
27
  api_instance = PolarAccesslink::DailyActivityApi.new
36
- transaction_id = 56 # Integer | Transaction identifier
37
- user_id = 56 # Integer | User identifier
28
+
29
+ transaction_id = nil # Object | Transaction identifier
30
+
31
+ user_id = nil # Object | User identifier
32
+
38
33
 
39
34
  begin
40
35
  #Commit transaction
@@ -46,11 +41,10 @@ end
46
41
 
47
42
  ### Parameters
48
43
 
49
-
50
44
  Name | Type | Description | Notes
51
45
  ------------- | ------------- | ------------- | -------------
52
- **transaction_id** | **Integer**| Transaction identifier |
53
- **user_id** | **Integer**| User identifier |
46
+ **transaction_id** | [**Object**](.md)| Transaction identifier |
47
+ **user_id** | [**Object**](.md)| User identifier |
54
48
 
55
49
  ### Return type
56
50
 
@@ -58,40 +52,35 @@ nil (empty response body)
58
52
 
59
53
  ### Authorization
60
54
 
61
- [OAuth2](../README.md#OAuth2)
55
+ No authorization required
62
56
 
63
57
  ### HTTP request headers
64
58
 
65
- - **Content-Type**: Not defined
66
- - **Accept**: Not defined
59
+ - **Content-Type**: Not defined
60
+ - **Accept**: Not defined
67
61
 
68
62
 
69
- ## create_activity_transaction
70
63
 
71
- > TransactionLocation create_activity_transaction(user_id)
64
+ # **create_activity_transaction**
65
+ > create_activity_transaction(user_id)
72
66
 
73
67
  Create transaction
74
68
 
75
69
  Initiate activity transaction. Check for new activity summaries and create a new transaction if found.
76
70
 
77
71
  ### Example
78
-
79
72
  ```ruby
80
73
  # load the gem
81
- require 'openapi_client'
82
- # setup authorization
83
- PolarAccesslink.configure do |config|
84
- # Configure OAuth2 access token for authorization: OAuth2
85
- config.access_token = 'YOUR ACCESS TOKEN'
86
- end
74
+ require 'polar_accesslink'
87
75
 
88
76
  api_instance = PolarAccesslink::DailyActivityApi.new
89
- user_id = 56 # Integer | User identifier
77
+
78
+ user_id = nil # Object | User identifier
79
+
90
80
 
91
81
  begin
92
82
  #Create transaction
93
- result = api_instance.create_activity_transaction(user_id)
94
- p result
83
+ api_instance.create_activity_transaction(user_id)
95
84
  rescue PolarAccesslink::ApiError => e
96
85
  puts "Exception when calling DailyActivityApi->create_activity_transaction: #{e}"
97
86
  end
@@ -99,51 +88,47 @@ end
99
88
 
100
89
  ### Parameters
101
90
 
102
-
103
91
  Name | Type | Description | Notes
104
92
  ------------- | ------------- | ------------- | -------------
105
- **user_id** | **Integer**| User identifier |
93
+ **user_id** | [**Object**](.md)| User identifier |
106
94
 
107
95
  ### Return type
108
96
 
109
- [**TransactionLocation**](TransactionLocation.md)
97
+ nil (empty response body)
110
98
 
111
99
  ### Authorization
112
100
 
113
- [OAuth2](../README.md#OAuth2)
101
+ No authorization required
114
102
 
115
103
  ### HTTP request headers
116
104
 
117
- - **Content-Type**: Not defined
118
- - **Accept**: application/json, application/xml
105
+ - **Content-Type**: Not defined
106
+ - **Accept**: Not defined
119
107
 
120
108
 
121
- ## get_activity_summary
122
109
 
123
- > Activity get_activity_summary(user_id, transaction_id, activity_id)
110
+ # **get_activity_summary**
111
+ > get_activity_summary(user_id, transaction_id, activity_id)
124
112
 
125
113
  Get activity summary
126
114
 
127
115
  ### Example
128
-
129
116
  ```ruby
130
117
  # load the gem
131
- require 'openapi_client'
132
- # setup authorization
133
- PolarAccesslink.configure do |config|
134
- # Configure OAuth2 access token for authorization: OAuth2
135
- config.access_token = 'YOUR ACCESS TOKEN'
136
- end
118
+ require 'polar_accesslink'
137
119
 
138
120
  api_instance = PolarAccesslink::DailyActivityApi.new
139
- user_id = 56 # Integer | User identifier
140
- transaction_id = 56 # Integer | Transaction identifier
141
- activity_id = 56 # Integer | Activity summary identifier
121
+
122
+ user_id = nil # Object | User identifier
123
+
124
+ transaction_id = nil # Object | Transaction identifier
125
+
126
+ activity_id = nil # Object | Activity summary identifier
127
+
142
128
 
143
129
  begin
144
130
  #Get activity summary
145
- result = api_instance.get_activity_summary(user_id, transaction_id, activity_id)
146
- p result
131
+ api_instance.get_activity_summary(user_id, transaction_id, activity_id)
147
132
  rescue PolarAccesslink::ApiError => e
148
133
  puts "Exception when calling DailyActivityApi->get_activity_summary: #{e}"
149
134
  end
@@ -151,55 +136,51 @@ end
151
136
 
152
137
  ### Parameters
153
138
 
154
-
155
139
  Name | Type | Description | Notes
156
140
  ------------- | ------------- | ------------- | -------------
157
- **user_id** | **Integer**| User identifier |
158
- **transaction_id** | **Integer**| Transaction identifier |
159
- **activity_id** | **Integer**| Activity summary identifier |
141
+ **user_id** | [**Object**](.md)| User identifier |
142
+ **transaction_id** | [**Object**](.md)| Transaction identifier |
143
+ **activity_id** | [**Object**](.md)| Activity summary identifier |
160
144
 
161
145
  ### Return type
162
146
 
163
- [**Activity**](Activity.md)
147
+ nil (empty response body)
164
148
 
165
149
  ### Authorization
166
150
 
167
- [OAuth2](../README.md#OAuth2)
151
+ No authorization required
168
152
 
169
153
  ### HTTP request headers
170
154
 
171
- - **Content-Type**: Not defined
172
- - **Accept**: application/json, application/xml
155
+ - **Content-Type**: Not defined
156
+ - **Accept**: Not defined
173
157
 
174
158
 
175
- ## get_step_samples
176
159
 
177
- > ActivityStepSamples get_step_samples(user_id, transaction_id, activity_id)
160
+ # **get_step_samples**
161
+ > get_step_samples(user_id, transaction_id, activity_id)
178
162
 
179
163
  Get step samples
180
164
 
181
165
  Get activity step samples. Example data can be seen from [appendix](#activity-step-time-series).
182
166
 
183
167
  ### Example
184
-
185
168
  ```ruby
186
169
  # load the gem
187
- require 'openapi_client'
188
- # setup authorization
189
- PolarAccesslink.configure do |config|
190
- # Configure OAuth2 access token for authorization: OAuth2
191
- config.access_token = 'YOUR ACCESS TOKEN'
192
- end
170
+ require 'polar_accesslink'
193
171
 
194
172
  api_instance = PolarAccesslink::DailyActivityApi.new
195
- user_id = 56 # Integer | User identifier
196
- transaction_id = 56 # Integer | Transaction identifier
197
- activity_id = 56 # Integer | Activity summary identifier
173
+
174
+ user_id = nil # Object | User identifier
175
+
176
+ transaction_id = nil # Object | Transaction identifier
177
+
178
+ activity_id = nil # Object | Activity summary identifier
179
+
198
180
 
199
181
  begin
200
182
  #Get step samples
201
- result = api_instance.get_step_samples(user_id, transaction_id, activity_id)
202
- p result
183
+ api_instance.get_step_samples(user_id, transaction_id, activity_id)
203
184
  rescue PolarAccesslink::ApiError => e
204
185
  puts "Exception when calling DailyActivityApi->get_step_samples: #{e}"
205
186
  end
@@ -207,55 +188,51 @@ end
207
188
 
208
189
  ### Parameters
209
190
 
210
-
211
191
  Name | Type | Description | Notes
212
192
  ------------- | ------------- | ------------- | -------------
213
- **user_id** | **Integer**| User identifier |
214
- **transaction_id** | **Integer**| Transaction identifier |
215
- **activity_id** | **Integer**| Activity summary identifier |
193
+ **user_id** | [**Object**](.md)| User identifier |
194
+ **transaction_id** | [**Object**](.md)| Transaction identifier |
195
+ **activity_id** | [**Object**](.md)| Activity summary identifier |
216
196
 
217
197
  ### Return type
218
198
 
219
- [**ActivityStepSamples**](ActivityStepSamples.md)
199
+ nil (empty response body)
220
200
 
221
201
  ### Authorization
222
202
 
223
- [OAuth2](../README.md#OAuth2)
203
+ No authorization required
224
204
 
225
205
  ### HTTP request headers
226
206
 
227
- - **Content-Type**: Not defined
228
- - **Accept**: application/json, application/xml
207
+ - **Content-Type**: Not defined
208
+ - **Accept**: Not defined
229
209
 
230
210
 
231
- ## get_zone_samples
232
211
 
233
- > ActivityZoneSamples get_zone_samples(user_id, transaction_id, activity_id)
212
+ # **get_zone_samples**
213
+ > get_zone_samples(user_id, transaction_id, activity_id)
234
214
 
235
215
  Get zone samples
236
216
 
237
217
  Get activity zone samples. Example data can be seen from [appendix](#activity-zone-time-series).
238
218
 
239
219
  ### Example
240
-
241
220
  ```ruby
242
221
  # load the gem
243
- require 'openapi_client'
244
- # setup authorization
245
- PolarAccesslink.configure do |config|
246
- # Configure OAuth2 access token for authorization: OAuth2
247
- config.access_token = 'YOUR ACCESS TOKEN'
248
- end
222
+ require 'polar_accesslink'
249
223
 
250
224
  api_instance = PolarAccesslink::DailyActivityApi.new
251
- user_id = 56 # Integer | User identifier
252
- transaction_id = 56 # Integer | Transaction identifier
253
- activity_id = 56 # Integer | Activity summary identifier
225
+
226
+ user_id = nil # Object | User identifier
227
+
228
+ transaction_id = nil # Object | Transaction identifier
229
+
230
+ activity_id = nil # Object | Activity summary identifier
231
+
254
232
 
255
233
  begin
256
234
  #Get zone samples
257
- result = api_instance.get_zone_samples(user_id, transaction_id, activity_id)
258
- p result
235
+ api_instance.get_zone_samples(user_id, transaction_id, activity_id)
259
236
  rescue PolarAccesslink::ApiError => e
260
237
  puts "Exception when calling DailyActivityApi->get_zone_samples: #{e}"
261
238
  end
@@ -263,54 +240,49 @@ end
263
240
 
264
241
  ### Parameters
265
242
 
266
-
267
243
  Name | Type | Description | Notes
268
244
  ------------- | ------------- | ------------- | -------------
269
- **user_id** | **Integer**| User identifier |
270
- **transaction_id** | **Integer**| Transaction identifier |
271
- **activity_id** | **Integer**| Activity summary identifier |
245
+ **user_id** | [**Object**](.md)| User identifier |
246
+ **transaction_id** | [**Object**](.md)| Transaction identifier |
247
+ **activity_id** | [**Object**](.md)| Activity summary identifier |
272
248
 
273
249
  ### Return type
274
250
 
275
- [**ActivityZoneSamples**](ActivityZoneSamples.md)
251
+ nil (empty response body)
276
252
 
277
253
  ### Authorization
278
254
 
279
- [OAuth2](../README.md#OAuth2)
255
+ No authorization required
280
256
 
281
257
  ### HTTP request headers
282
258
 
283
- - **Content-Type**: Not defined
284
- - **Accept**: application/json, application/xml
259
+ - **Content-Type**: Not defined
260
+ - **Accept**: Not defined
285
261
 
286
262
 
287
- ## list_activities
288
263
 
289
- > ActivityLog list_activities(transaction_id, user_id)
264
+ # **list_activities**
265
+ > list_activities(transaction_id, user_id)
290
266
 
291
267
  List activities
292
268
 
293
269
  List new activity data. After successfully initiating a transaction, activity summaries included within it can be retrieved with the provided transactionId.
294
270
 
295
271
  ### Example
296
-
297
272
  ```ruby
298
273
  # load the gem
299
- require 'openapi_client'
300
- # setup authorization
301
- PolarAccesslink.configure do |config|
302
- # Configure OAuth2 access token for authorization: OAuth2
303
- config.access_token = 'YOUR ACCESS TOKEN'
304
- end
274
+ require 'polar_accesslink'
305
275
 
306
276
  api_instance = PolarAccesslink::DailyActivityApi.new
307
- transaction_id = 56 # Integer | Transaction identifier
308
- user_id = 56 # Integer | User identifier
277
+
278
+ transaction_id = nil # Object | Transaction identifier
279
+
280
+ user_id = nil # Object | User identifier
281
+
309
282
 
310
283
  begin
311
284
  #List activities
312
- result = api_instance.list_activities(transaction_id, user_id)
313
- p result
285
+ api_instance.list_activities(transaction_id, user_id)
314
286
  rescue PolarAccesslink::ApiError => e
315
287
  puts "Exception when calling DailyActivityApi->list_activities: #{e}"
316
288
  end
@@ -318,22 +290,23 @@ end
318
290
 
319
291
  ### Parameters
320
292
 
321
-
322
293
  Name | Type | Description | Notes
323
294
  ------------- | ------------- | ------------- | -------------
324
- **transaction_id** | **Integer**| Transaction identifier |
325
- **user_id** | **Integer**| User identifier |
295
+ **transaction_id** | [**Object**](.md)| Transaction identifier |
296
+ **user_id** | [**Object**](.md)| User identifier |
326
297
 
327
298
  ### Return type
328
299
 
329
- [**ActivityLog**](ActivityLog.md)
300
+ nil (empty response body)
330
301
 
331
302
  ### Authorization
332
303
 
333
- [OAuth2](../README.md#OAuth2)
304
+ No authorization required
334
305
 
335
306
  ### HTTP request headers
336
307
 
337
- - **Content-Type**: Not defined
338
- - **Accept**: application/json, application/xml
308
+ - **Content-Type**: Not defined
309
+ - **Accept**: Not defined
310
+
311
+
339
312