requestsproxy-rest 0.0.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (147) hide show
  1. checksums.yaml +7 -0
  2. data/Gemfile +7 -0
  3. data/README.md +149 -0
  4. data/Rakefile +8 -0
  5. data/docs/ProtobufListValue.md +8 -0
  6. data/docs/ProtobufNullValue.md +7 -0
  7. data/docs/ProtobufStruct.md +8 -0
  8. data/docs/ProtobufValue.md +13 -0
  9. data/docs/RequestsproxyAccountStarRatingResponse.md +9 -0
  10. data/docs/RequestsproxyApi.md +1008 -0
  11. data/docs/RequestsproxyAuthInfoResponse.md +9 -0
  12. data/docs/RequestsproxyCategory.md +9 -0
  13. data/docs/RequestsproxyComment.md +11 -0
  14. data/docs/RequestsproxyCoupon.md +8 -0
  15. data/docs/RequestsproxyCreateDynamicCouponsCodesResponse.md +9 -0
  16. data/docs/RequestsproxyCreateWebhookParams.md +9 -0
  17. data/docs/RequestsproxyDynamicCouponError.md +9 -0
  18. data/docs/RequestsproxyDynamicCouponsResponse.md +8 -0
  19. data/docs/RequestsproxyDynamicCouponsStatisticsResponse.md +8 -0
  20. data/docs/RequestsproxyDynamicCouponsStats.md +9 -0
  21. data/docs/RequestsproxyFeature.md +12 -0
  22. data/docs/RequestsproxyFeaturesResponse.md +8 -0
  23. data/docs/RequestsproxyImageData.md +10 -0
  24. data/docs/RequestsproxyOrdersResponse.md +8 -0
  25. data/docs/RequestsproxyPagination.md +10 -0
  26. data/docs/RequestsproxyProductImage.md +11 -0
  27. data/docs/RequestsproxyProductResponse.md +19 -0
  28. data/docs/RequestsproxyProductSpecs.md +9 -0
  29. data/docs/RequestsproxyProductStarRatingResponse.md +10 -0
  30. data/docs/RequestsproxyProductsResponse.md +8 -0
  31. data/docs/RequestsproxyProductsStarRatingResponse.md +8 -0
  32. data/docs/RequestsproxyPromotedProduct.md +10 -0
  33. data/docs/RequestsproxyPromotedProductsResponse.md +8 -0
  34. data/docs/RequestsproxyPurchase.md +16 -0
  35. data/docs/RequestsproxyResponse.md +28 -0
  36. data/docs/RequestsproxyReview.md +24 -0
  37. data/docs/RequestsproxyReviewCustomField.md +11 -0
  38. data/docs/RequestsproxyReviewResponse.md +8 -0
  39. data/docs/RequestsproxyReviewsResponse.md +8 -0
  40. data/docs/RequestsproxyStatus.md +9 -0
  41. data/docs/RequestsproxyTopReview.md +13 -0
  42. data/docs/RequestsproxyTopReviewsResponse.md +8 -0
  43. data/docs/RequestsproxyUserResponse.md +11 -0
  44. data/docs/RequestsproxyWebhook.md +11 -0
  45. data/docs/RequestsproxyWebhookEvent.md +9 -0
  46. data/docs/RequestsproxyWebhookEventsResponse.md +8 -0
  47. data/docs/RequestsproxyWebhookResponse.md +8 -0
  48. data/docs/RequestsproxyWebhooksResponse.md +8 -0
  49. data/git_push.sh +55 -0
  50. data/lib/requestsproxy-rest.rb +83 -0
  51. data/lib/requestsproxy-rest/api/requestsproxy_api.rb +1161 -0
  52. data/lib/requestsproxy-rest/api_client.rb +388 -0
  53. data/lib/requestsproxy-rest/api_error.rb +38 -0
  54. data/lib/requestsproxy-rest/configuration.rb +202 -0
  55. data/lib/requestsproxy-rest/models/protobuf_list_value.rb +187 -0
  56. data/lib/requestsproxy-rest/models/protobuf_null_value.rb +29 -0
  57. data/lib/requestsproxy-rest/models/protobuf_struct.rb +187 -0
  58. data/lib/requestsproxy-rest/models/protobuf_value.rb +235 -0
  59. data/lib/requestsproxy-rest/models/requestsproxy_account_star_rating_response.rb +192 -0
  60. data/lib/requestsproxy-rest/models/requestsproxy_auth_info_response.rb +194 -0
  61. data/lib/requestsproxy-rest/models/requestsproxy_category.rb +192 -0
  62. data/lib/requestsproxy-rest/models/requestsproxy_comment.rb +210 -0
  63. data/lib/requestsproxy-rest/models/requestsproxy_coupon.rb +183 -0
  64. data/lib/requestsproxy-rest/models/requestsproxy_create_dynamic_coupons_codes_response.rb +194 -0
  65. data/lib/requestsproxy-rest/models/requestsproxy_create_webhook_params.rb +192 -0
  66. data/lib/requestsproxy-rest/models/requestsproxy_dynamic_coupon_error.rb +192 -0
  67. data/lib/requestsproxy-rest/models/requestsproxy_dynamic_coupons_response.rb +185 -0
  68. data/lib/requestsproxy-rest/models/requestsproxy_dynamic_coupons_statistics_response.rb +183 -0
  69. data/lib/requestsproxy-rest/models/requestsproxy_dynamic_coupons_stats.rb +192 -0
  70. data/lib/requestsproxy-rest/models/requestsproxy_feature.rb +219 -0
  71. data/lib/requestsproxy-rest/models/requestsproxy_features_response.rb +185 -0
  72. data/lib/requestsproxy-rest/models/requestsproxy_image_data.rb +201 -0
  73. data/lib/requestsproxy-rest/models/requestsproxy_orders_response.rb +185 -0
  74. data/lib/requestsproxy-rest/models/requestsproxy_pagination.rb +201 -0
  75. data/lib/requestsproxy-rest/models/requestsproxy_product_image.rb +210 -0
  76. data/lib/requestsproxy-rest/models/requestsproxy_product_response.rb +286 -0
  77. data/lib/requestsproxy-rest/models/requestsproxy_product_specs.rb +192 -0
  78. data/lib/requestsproxy-rest/models/requestsproxy_product_star_rating_response.rb +201 -0
  79. data/lib/requestsproxy-rest/models/requestsproxy_products_response.rb +185 -0
  80. data/lib/requestsproxy-rest/models/requestsproxy_products_star_rating_response.rb +185 -0
  81. data/lib/requestsproxy-rest/models/requestsproxy_promoted_product.rb +201 -0
  82. data/lib/requestsproxy-rest/models/requestsproxy_promoted_products_response.rb +185 -0
  83. data/lib/requestsproxy-rest/models/requestsproxy_purchase.rb +255 -0
  84. data/lib/requestsproxy-rest/models/requestsproxy_response.rb +363 -0
  85. data/lib/requestsproxy-rest/models/requestsproxy_review.rb +331 -0
  86. data/lib/requestsproxy-rest/models/requestsproxy_review_custom_field.rb +210 -0
  87. data/lib/requestsproxy-rest/models/requestsproxy_review_response.rb +183 -0
  88. data/lib/requestsproxy-rest/models/requestsproxy_reviews_response.rb +185 -0
  89. data/lib/requestsproxy-rest/models/requestsproxy_status.rb +192 -0
  90. data/lib/requestsproxy-rest/models/requestsproxy_top_review.rb +228 -0
  91. data/lib/requestsproxy-rest/models/requestsproxy_top_reviews_response.rb +185 -0
  92. data/lib/requestsproxy-rest/models/requestsproxy_user_response.rb +210 -0
  93. data/lib/requestsproxy-rest/models/requestsproxy_webhook.rb +210 -0
  94. data/lib/requestsproxy-rest/models/requestsproxy_webhook_event.rb +192 -0
  95. data/lib/requestsproxy-rest/models/requestsproxy_webhook_events_response.rb +185 -0
  96. data/lib/requestsproxy-rest/models/requestsproxy_webhook_response.rb +183 -0
  97. data/lib/requestsproxy-rest/models/requestsproxy_webhooks_response.rb +185 -0
  98. data/lib/requestsproxy-rest/version.rb +15 -0
  99. data/requestsproxy-rest.gemspec +45 -0
  100. data/spec/api/requestsproxy_api_spec.rb +271 -0
  101. data/spec/api_client_spec.rb +226 -0
  102. data/spec/configuration_spec.rb +42 -0
  103. data/spec/models/protobuf_list_value_spec.rb +41 -0
  104. data/spec/models/protobuf_null_value_spec.rb +35 -0
  105. data/spec/models/protobuf_struct_spec.rb +41 -0
  106. data/spec/models/protobuf_value_spec.rb +71 -0
  107. data/spec/models/requestsproxy_account_star_rating_response_spec.rb +47 -0
  108. data/spec/models/requestsproxy_auth_info_response_spec.rb +47 -0
  109. data/spec/models/requestsproxy_category_spec.rb +47 -0
  110. data/spec/models/requestsproxy_comment_spec.rb +59 -0
  111. data/spec/models/requestsproxy_coupon_spec.rb +41 -0
  112. data/spec/models/requestsproxy_create_dynamic_coupons_codes_response_spec.rb +47 -0
  113. data/spec/models/requestsproxy_create_webhook_params_spec.rb +47 -0
  114. data/spec/models/requestsproxy_dynamic_coupon_error_spec.rb +47 -0
  115. data/spec/models/requestsproxy_dynamic_coupons_response_spec.rb +41 -0
  116. data/spec/models/requestsproxy_dynamic_coupons_statistics_response_spec.rb +41 -0
  117. data/spec/models/requestsproxy_dynamic_coupons_stats_spec.rb +47 -0
  118. data/spec/models/requestsproxy_feature_spec.rb +65 -0
  119. data/spec/models/requestsproxy_features_response_spec.rb +41 -0
  120. data/spec/models/requestsproxy_image_data_spec.rb +53 -0
  121. data/spec/models/requestsproxy_orders_response_spec.rb +41 -0
  122. data/spec/models/requestsproxy_pagination_spec.rb +53 -0
  123. data/spec/models/requestsproxy_product_image_spec.rb +59 -0
  124. data/spec/models/requestsproxy_product_response_spec.rb +107 -0
  125. data/spec/models/requestsproxy_product_specs_spec.rb +47 -0
  126. data/spec/models/requestsproxy_product_star_rating_response_spec.rb +53 -0
  127. data/spec/models/requestsproxy_products_response_spec.rb +41 -0
  128. data/spec/models/requestsproxy_products_star_rating_response_spec.rb +41 -0
  129. data/spec/models/requestsproxy_promoted_product_spec.rb +53 -0
  130. data/spec/models/requestsproxy_promoted_products_response_spec.rb +41 -0
  131. data/spec/models/requestsproxy_purchase_spec.rb +89 -0
  132. data/spec/models/requestsproxy_response_spec.rb +161 -0
  133. data/spec/models/requestsproxy_review_custom_field_spec.rb +59 -0
  134. data/spec/models/requestsproxy_review_response_spec.rb +41 -0
  135. data/spec/models/requestsproxy_review_spec.rb +137 -0
  136. data/spec/models/requestsproxy_reviews_response_spec.rb +41 -0
  137. data/spec/models/requestsproxy_status_spec.rb +47 -0
  138. data/spec/models/requestsproxy_top_review_spec.rb +71 -0
  139. data/spec/models/requestsproxy_top_reviews_response_spec.rb +41 -0
  140. data/spec/models/requestsproxy_user_response_spec.rb +59 -0
  141. data/spec/models/requestsproxy_webhook_event_spec.rb +47 -0
  142. data/spec/models/requestsproxy_webhook_events_response_spec.rb +41 -0
  143. data/spec/models/requestsproxy_webhook_response_spec.rb +41 -0
  144. data/spec/models/requestsproxy_webhook_spec.rb +59 -0
  145. data/spec/models/requestsproxy_webhooks_response_spec.rb +41 -0
  146. data/spec/spec_helper.rb +111 -0
  147. metadata +416 -0
@@ -0,0 +1,8 @@
1
+ # Requestsproxy::RequestsproxyWebhookResponse
2
+
3
+ ## Properties
4
+ Name | Type | Description | Notes
5
+ ------------ | ------------- | ------------- | -------------
6
+ **webhook** | [**RequestsproxyWebhook**](RequestsproxyWebhook.md) | | [optional]
7
+
8
+
@@ -0,0 +1,8 @@
1
+ # Requestsproxy::RequestsproxyWebhooksResponse
2
+
3
+ ## Properties
4
+ Name | Type | Description | Notes
5
+ ------------ | ------------- | ------------- | -------------
6
+ **webhooks** | [**Array<RequestsproxyWebhook>**](RequestsproxyWebhook.md) | | [optional]
7
+
8
+
@@ -0,0 +1,55 @@
1
+ #!/bin/sh
2
+ #
3
+ # Generated by: https://github.com/swagger-api/swagger-codegen.git
4
+ #
5
+ # ref: https://help.github.com/articles/adding-an-existing-project-to-github-using-the-command-line/
6
+ #
7
+ # Usage example: /bin/sh ./git_push.sh wing328 swagger-petstore-perl "minor update"
8
+
9
+ git_user_id=$1
10
+ git_repo_id=$2
11
+ release_note=$3
12
+
13
+ if [ "$git_user_id" = "" ]; then
14
+ git_user_id="GIT_USER_ID"
15
+ echo "[INFO] No command line input provided. Set \$git_user_id to $git_user_id"
16
+ fi
17
+
18
+ if [ "$git_repo_id" = "" ]; then
19
+ git_repo_id="GIT_REPO_ID"
20
+ echo "[INFO] No command line input provided. Set \$git_repo_id to $git_repo_id"
21
+ fi
22
+
23
+ if [ "$release_note" = "" ]; then
24
+ release_note="Minor update"
25
+ echo "[INFO] No command line input provided. Set \$release_note to $release_note"
26
+ fi
27
+
28
+ # Initialize the local directory as a Git repository
29
+ git init
30
+
31
+ # Adds the files in the local repository and stages them for commit.
32
+ git add .
33
+
34
+ # Commits the tracked changes and prepares them to be pushed to a remote repository.
35
+ git commit -m "$release_note"
36
+
37
+ # Sets the new remote
38
+ git_remote=`git remote`
39
+ if [ "$git_remote" = "" ]; then # git remote not defined
40
+
41
+ if [ "$GIT_TOKEN" = "" ]; then
42
+ echo "[INFO] \$GIT_TOKEN (environment variable) is not set. Using the git credential in your environment."
43
+ git remote add origin https://github.com/${git_user_id}/${git_repo_id}.git
44
+ else
45
+ git remote add origin https://${git_user_id}:${GIT_TOKEN}@github.com/${git_user_id}/${git_repo_id}.git
46
+ fi
47
+
48
+ fi
49
+
50
+ git pull origin master
51
+
52
+ # Pushes (Forces) the changes in the local repository up to the remote repository
53
+ echo "Git pushing to https://github.com/${git_user_id}/${git_repo_id}.git"
54
+ git push origin master 2>&1 | grep -v 'To https'
55
+
@@ -0,0 +1,83 @@
1
+ =begin
2
+ #requestsproxy.proto
3
+
4
+ #No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen)
5
+
6
+ OpenAPI spec version: version not set
7
+
8
+ Generated by: https://github.com/swagger-api/swagger-codegen.git
9
+ Swagger Codegen version: 2.4.0-SNAPSHOT
10
+
11
+ =end
12
+
13
+ # Common files
14
+ require 'requestsproxy-rest/api_client'
15
+ require 'requestsproxy-rest/api_error'
16
+ require 'requestsproxy-rest/version'
17
+ require 'requestsproxy-rest/configuration'
18
+
19
+ # Models
20
+ require 'requestsproxy-rest/models/protobuf_list_value'
21
+ require 'requestsproxy-rest/models/protobuf_null_value'
22
+ require 'requestsproxy-rest/models/protobuf_struct'
23
+ require 'requestsproxy-rest/models/protobuf_value'
24
+ require 'requestsproxy-rest/models/requestsproxy_account_star_rating_response'
25
+ require 'requestsproxy-rest/models/requestsproxy_auth_info_response'
26
+ require 'requestsproxy-rest/models/requestsproxy_category'
27
+ require 'requestsproxy-rest/models/requestsproxy_comment'
28
+ require 'requestsproxy-rest/models/requestsproxy_coupon'
29
+ require 'requestsproxy-rest/models/requestsproxy_create_dynamic_coupons_codes_response'
30
+ require 'requestsproxy-rest/models/requestsproxy_create_webhook_params'
31
+ require 'requestsproxy-rest/models/requestsproxy_dynamic_coupon_error'
32
+ require 'requestsproxy-rest/models/requestsproxy_dynamic_coupons_response'
33
+ require 'requestsproxy-rest/models/requestsproxy_dynamic_coupons_statistics_response'
34
+ require 'requestsproxy-rest/models/requestsproxy_dynamic_coupons_stats'
35
+ require 'requestsproxy-rest/models/requestsproxy_feature'
36
+ require 'requestsproxy-rest/models/requestsproxy_features_response'
37
+ require 'requestsproxy-rest/models/requestsproxy_image_data'
38
+ require 'requestsproxy-rest/models/requestsproxy_orders_response'
39
+ require 'requestsproxy-rest/models/requestsproxy_pagination'
40
+ require 'requestsproxy-rest/models/requestsproxy_product_image'
41
+ require 'requestsproxy-rest/models/requestsproxy_product_response'
42
+ require 'requestsproxy-rest/models/requestsproxy_product_specs'
43
+ require 'requestsproxy-rest/models/requestsproxy_product_star_rating_response'
44
+ require 'requestsproxy-rest/models/requestsproxy_products_response'
45
+ require 'requestsproxy-rest/models/requestsproxy_products_star_rating_response'
46
+ require 'requestsproxy-rest/models/requestsproxy_promoted_product'
47
+ require 'requestsproxy-rest/models/requestsproxy_promoted_products_response'
48
+ require 'requestsproxy-rest/models/requestsproxy_purchase'
49
+ require 'requestsproxy-rest/models/requestsproxy_response'
50
+ require 'requestsproxy-rest/models/requestsproxy_review'
51
+ require 'requestsproxy-rest/models/requestsproxy_review_custom_field'
52
+ require 'requestsproxy-rest/models/requestsproxy_review_response'
53
+ require 'requestsproxy-rest/models/requestsproxy_reviews_response'
54
+ require 'requestsproxy-rest/models/requestsproxy_status'
55
+ require 'requestsproxy-rest/models/requestsproxy_top_review'
56
+ require 'requestsproxy-rest/models/requestsproxy_top_reviews_response'
57
+ require 'requestsproxy-rest/models/requestsproxy_user_response'
58
+ require 'requestsproxy-rest/models/requestsproxy_webhook'
59
+ require 'requestsproxy-rest/models/requestsproxy_webhook_event'
60
+ require 'requestsproxy-rest/models/requestsproxy_webhook_events_response'
61
+ require 'requestsproxy-rest/models/requestsproxy_webhook_response'
62
+ require 'requestsproxy-rest/models/requestsproxy_webhooks_response'
63
+
64
+ # APIs
65
+ require 'requestsproxy-rest/api/requestsproxy_api'
66
+
67
+ module Requestsproxy
68
+ class << self
69
+ # Customize default settings for the SDK using block.
70
+ # Requestsproxy.configure do |config|
71
+ # config.username = "xxx"
72
+ # config.password = "xxx"
73
+ # end
74
+ # If no block given, return the default Configuration object.
75
+ def configure
76
+ if block_given?
77
+ yield(Configuration.default)
78
+ else
79
+ Configuration.default
80
+ end
81
+ end
82
+ end
83
+ end
@@ -0,0 +1,1161 @@
1
+ =begin
2
+ #requestsproxy.proto
3
+
4
+ #No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen)
5
+
6
+ OpenAPI spec version: version not set
7
+
8
+ Generated by: https://github.com/swagger-api/swagger-codegen.git
9
+ Swagger Codegen version: 2.4.0-SNAPSHOT
10
+
11
+ =end
12
+
13
+ require 'uri'
14
+
15
+ module Requestsproxy
16
+ class RequestsproxyApi
17
+ attr_accessor :api_client
18
+
19
+ def initialize(api_client = ApiClient.default)
20
+ @api_client = api_client
21
+ end
22
+ # @param account_id
23
+ # @param [Hash] opts the optional parameters
24
+ # @return [RequestsproxyResponse]
25
+ def account_star_rating(account_id, opts = {})
26
+ data, _status_code, _headers = account_star_rating_with_http_info(account_id, opts)
27
+ data
28
+ end
29
+
30
+ # @param account_id
31
+ # @param [Hash] opts the optional parameters
32
+ # @return [Array<(RequestsproxyResponse, Fixnum, Hash)>] RequestsproxyResponse data, response status code and response headers
33
+ def account_star_rating_with_http_info(account_id, opts = {})
34
+ if @api_client.config.debugging
35
+ @api_client.config.logger.debug 'Calling API: RequestsproxyApi.account_star_rating ...'
36
+ end
37
+ # verify the required parameter 'account_id' is set
38
+ if @api_client.config.client_side_validation && account_id.nil?
39
+ fail ArgumentError, "Missing the required parameter 'account_id' when calling RequestsproxyApi.account_star_rating"
40
+ end
41
+ # resource path
42
+ local_var_path = '/v2/{account_id}/star_rating/account'.sub('{' + 'account_id' + '}', account_id.to_s)
43
+
44
+ # query parameters
45
+ query_params = {}
46
+
47
+ # header parameters
48
+ header_params = {}
49
+ # HTTP header 'Accept' (if needed)
50
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
51
+ # HTTP header 'Content-Type'
52
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
53
+
54
+ # form parameters
55
+ form_params = {}
56
+
57
+ # http body (model)
58
+ post_body = nil
59
+ auth_names = []
60
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
61
+ :header_params => header_params,
62
+ :query_params => query_params,
63
+ :form_params => form_params,
64
+ :body => post_body,
65
+ :auth_names => auth_names,
66
+ :return_type => 'RequestsproxyResponse')
67
+ if @api_client.config.debugging
68
+ @api_client.config.logger.debug "API called: RequestsproxyApi#account_star_rating\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
69
+ end
70
+ return data, status_code, headers
71
+ end
72
+ # @param account_id
73
+ # @param [Hash] opts the optional parameters
74
+ # @return [RequestsproxyResponse]
75
+ def auth_info(account_id, opts = {})
76
+ data, _status_code, _headers = auth_info_with_http_info(account_id, opts)
77
+ data
78
+ end
79
+
80
+ # @param account_id
81
+ # @param [Hash] opts the optional parameters
82
+ # @return [Array<(RequestsproxyResponse, Fixnum, Hash)>] RequestsproxyResponse data, response status code and response headers
83
+ def auth_info_with_http_info(account_id, opts = {})
84
+ if @api_client.config.debugging
85
+ @api_client.config.logger.debug 'Calling API: RequestsproxyApi.auth_info ...'
86
+ end
87
+ # verify the required parameter 'account_id' is set
88
+ if @api_client.config.client_side_validation && account_id.nil?
89
+ fail ArgumentError, "Missing the required parameter 'account_id' when calling RequestsproxyApi.auth_info"
90
+ end
91
+ # resource path
92
+ local_var_path = '/v2/{account_id}/info'.sub('{' + 'account_id' + '}', account_id.to_s)
93
+
94
+ # query parameters
95
+ query_params = {}
96
+
97
+ # header parameters
98
+ header_params = {}
99
+ # HTTP header 'Accept' (if needed)
100
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
101
+ # HTTP header 'Content-Type'
102
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
103
+
104
+ # form parameters
105
+ form_params = {}
106
+
107
+ # http body (model)
108
+ post_body = nil
109
+ auth_names = []
110
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
111
+ :header_params => header_params,
112
+ :query_params => query_params,
113
+ :form_params => form_params,
114
+ :body => post_body,
115
+ :auth_names => auth_names,
116
+ :return_type => 'RequestsproxyResponse')
117
+ if @api_client.config.debugging
118
+ @api_client.config.logger.debug "API called: RequestsproxyApi#auth_info\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
119
+ end
120
+ return data, status_code, headers
121
+ end
122
+ # @param account_id
123
+ # @param body
124
+ # @param [Hash] opts the optional parameters
125
+ # @return [RequestsproxyResponse]
126
+ def create_webhook(account_id, body, opts = {})
127
+ data, _status_code, _headers = create_webhook_with_http_info(account_id, body, opts)
128
+ data
129
+ end
130
+
131
+ # @param account_id
132
+ # @param body
133
+ # @param [Hash] opts the optional parameters
134
+ # @return [Array<(RequestsproxyResponse, Fixnum, Hash)>] RequestsproxyResponse data, response status code and response headers
135
+ def create_webhook_with_http_info(account_id, body, opts = {})
136
+ if @api_client.config.debugging
137
+ @api_client.config.logger.debug 'Calling API: RequestsproxyApi.create_webhook ...'
138
+ end
139
+ # verify the required parameter 'account_id' is set
140
+ if @api_client.config.client_side_validation && account_id.nil?
141
+ fail ArgumentError, "Missing the required parameter 'account_id' when calling RequestsproxyApi.create_webhook"
142
+ end
143
+ # verify the required parameter 'body' is set
144
+ if @api_client.config.client_side_validation && body.nil?
145
+ fail ArgumentError, "Missing the required parameter 'body' when calling RequestsproxyApi.create_webhook"
146
+ end
147
+ # resource path
148
+ local_var_path = '/v2/{account_id}/webhooks'.sub('{' + 'account_id' + '}', account_id.to_s)
149
+
150
+ # query parameters
151
+ query_params = {}
152
+
153
+ # header parameters
154
+ header_params = {}
155
+ # HTTP header 'Accept' (if needed)
156
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
157
+ # HTTP header 'Content-Type'
158
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
159
+
160
+ # form parameters
161
+ form_params = {}
162
+
163
+ # http body (model)
164
+ post_body = @api_client.object_to_http_body(body)
165
+ auth_names = []
166
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path,
167
+ :header_params => header_params,
168
+ :query_params => query_params,
169
+ :form_params => form_params,
170
+ :body => post_body,
171
+ :auth_names => auth_names,
172
+ :return_type => 'RequestsproxyResponse')
173
+ if @api_client.config.debugging
174
+ @api_client.config.logger.debug "API called: RequestsproxyApi#create_webhook\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
175
+ end
176
+ return data, status_code, headers
177
+ end
178
+ # @param account_id
179
+ # @param id
180
+ # @param [Hash] opts the optional parameters
181
+ # @option opts [String] :access_token
182
+ # @return [RequestsproxyResponse]
183
+ def delete_webhook(account_id, id, opts = {})
184
+ data, _status_code, _headers = delete_webhook_with_http_info(account_id, id, opts)
185
+ data
186
+ end
187
+
188
+ # @param account_id
189
+ # @param id
190
+ # @param [Hash] opts the optional parameters
191
+ # @option opts [String] :access_token
192
+ # @return [Array<(RequestsproxyResponse, Fixnum, Hash)>] RequestsproxyResponse data, response status code and response headers
193
+ def delete_webhook_with_http_info(account_id, id, opts = {})
194
+ if @api_client.config.debugging
195
+ @api_client.config.logger.debug 'Calling API: RequestsproxyApi.delete_webhook ...'
196
+ end
197
+ # verify the required parameter 'account_id' is set
198
+ if @api_client.config.client_side_validation && account_id.nil?
199
+ fail ArgumentError, "Missing the required parameter 'account_id' when calling RequestsproxyApi.delete_webhook"
200
+ end
201
+ # verify the required parameter 'id' is set
202
+ if @api_client.config.client_side_validation && id.nil?
203
+ fail ArgumentError, "Missing the required parameter 'id' when calling RequestsproxyApi.delete_webhook"
204
+ end
205
+ # resource path
206
+ local_var_path = '/v2/{account_id}/webhooks/{id}'.sub('{' + 'account_id' + '}', account_id.to_s).sub('{' + 'id' + '}', id.to_s)
207
+
208
+ # query parameters
209
+ query_params = {}
210
+ query_params[:'access_token'] = opts[:'access_token'] if !opts[:'access_token'].nil?
211
+
212
+ # header parameters
213
+ header_params = {}
214
+ # HTTP header 'Accept' (if needed)
215
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
216
+ # HTTP header 'Content-Type'
217
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
218
+
219
+ # form parameters
220
+ form_params = {}
221
+
222
+ # http body (model)
223
+ post_body = nil
224
+ auth_names = []
225
+ data, status_code, headers = @api_client.call_api(:DELETE, local_var_path,
226
+ :header_params => header_params,
227
+ :query_params => query_params,
228
+ :form_params => form_params,
229
+ :body => post_body,
230
+ :auth_names => auth_names,
231
+ :return_type => 'RequestsproxyResponse')
232
+ if @api_client.config.debugging
233
+ @api_client.config.logger.debug "API called: RequestsproxyApi#delete_webhook\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
234
+ end
235
+ return data, status_code, headers
236
+ end
237
+ # @param account_id
238
+ # @param [Hash] opts the optional parameters
239
+ # @return [RequestsproxyResponse]
240
+ def features(account_id, opts = {})
241
+ data, _status_code, _headers = features_with_http_info(account_id, opts)
242
+ data
243
+ end
244
+
245
+ # @param account_id
246
+ # @param [Hash] opts the optional parameters
247
+ # @return [Array<(RequestsproxyResponse, Fixnum, Hash)>] RequestsproxyResponse data, response status code and response headers
248
+ def features_with_http_info(account_id, opts = {})
249
+ if @api_client.config.debugging
250
+ @api_client.config.logger.debug 'Calling API: RequestsproxyApi.features ...'
251
+ end
252
+ # verify the required parameter 'account_id' is set
253
+ if @api_client.config.client_side_validation && account_id.nil?
254
+ fail ArgumentError, "Missing the required parameter 'account_id' when calling RequestsproxyApi.features"
255
+ end
256
+ # resource path
257
+ local_var_path = '/v2/{account_id}/features'.sub('{' + 'account_id' + '}', account_id.to_s)
258
+
259
+ # query parameters
260
+ query_params = {}
261
+
262
+ # header parameters
263
+ header_params = {}
264
+ # HTTP header 'Accept' (if needed)
265
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
266
+ # HTTP header 'Content-Type'
267
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
268
+
269
+ # form parameters
270
+ form_params = {}
271
+
272
+ # http body (model)
273
+ post_body = nil
274
+ auth_names = []
275
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
276
+ :header_params => header_params,
277
+ :query_params => query_params,
278
+ :form_params => form_params,
279
+ :body => post_body,
280
+ :auth_names => auth_names,
281
+ :return_type => 'RequestsproxyResponse')
282
+ if @api_client.config.debugging
283
+ @api_client.config.logger.debug "API called: RequestsproxyApi#features\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
284
+ end
285
+ return data, status_code, headers
286
+ end
287
+ # @param account_id
288
+ # @param [Hash] opts the optional parameters
289
+ # @option opts [String] :first_id
290
+ # @option opts [String] :count
291
+ # @option opts [String] :page
292
+ # @return [RequestsproxyResponse]
293
+ def orders(account_id, opts = {})
294
+ data, _status_code, _headers = orders_with_http_info(account_id, opts)
295
+ data
296
+ end
297
+
298
+ # @param account_id
299
+ # @param [Hash] opts the optional parameters
300
+ # @option opts [String] :first_id
301
+ # @option opts [String] :count
302
+ # @option opts [String] :page
303
+ # @return [Array<(RequestsproxyResponse, Fixnum, Hash)>] RequestsproxyResponse data, response status code and response headers
304
+ def orders_with_http_info(account_id, opts = {})
305
+ if @api_client.config.debugging
306
+ @api_client.config.logger.debug 'Calling API: RequestsproxyApi.orders ...'
307
+ end
308
+ # verify the required parameter 'account_id' is set
309
+ if @api_client.config.client_side_validation && account_id.nil?
310
+ fail ArgumentError, "Missing the required parameter 'account_id' when calling RequestsproxyApi.orders"
311
+ end
312
+ # resource path
313
+ local_var_path = '/v2/{account_id}/orders'.sub('{' + 'account_id' + '}', account_id.to_s)
314
+
315
+ # query parameters
316
+ query_params = {}
317
+ query_params[:'first_id'] = opts[:'first_id'] if !opts[:'first_id'].nil?
318
+ query_params[:'count'] = opts[:'count'] if !opts[:'count'].nil?
319
+ query_params[:'page'] = opts[:'page'] if !opts[:'page'].nil?
320
+
321
+ # header parameters
322
+ header_params = {}
323
+ # HTTP header 'Accept' (if needed)
324
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
325
+ # HTTP header 'Content-Type'
326
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
327
+
328
+ # form parameters
329
+ form_params = {}
330
+
331
+ # http body (model)
332
+ post_body = nil
333
+ auth_names = []
334
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
335
+ :header_params => header_params,
336
+ :query_params => query_params,
337
+ :form_params => form_params,
338
+ :body => post_body,
339
+ :auth_names => auth_names,
340
+ :return_type => 'RequestsproxyResponse')
341
+ if @api_client.config.debugging
342
+ @api_client.config.logger.debug "API called: RequestsproxyApi#orders\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
343
+ end
344
+ return data, status_code, headers
345
+ end
346
+ # @param account_id
347
+ # @param external_product_id
348
+ # @param [Hash] opts the optional parameters
349
+ # @return [RequestsproxyResponse]
350
+ def product(account_id, external_product_id, opts = {})
351
+ data, _status_code, _headers = product_with_http_info(account_id, external_product_id, opts)
352
+ data
353
+ end
354
+
355
+ # @param account_id
356
+ # @param external_product_id
357
+ # @param [Hash] opts the optional parameters
358
+ # @return [Array<(RequestsproxyResponse, Fixnum, Hash)>] RequestsproxyResponse data, response status code and response headers
359
+ def product_with_http_info(account_id, external_product_id, opts = {})
360
+ if @api_client.config.debugging
361
+ @api_client.config.logger.debug 'Calling API: RequestsproxyApi.product ...'
362
+ end
363
+ # verify the required parameter 'account_id' is set
364
+ if @api_client.config.client_side_validation && account_id.nil?
365
+ fail ArgumentError, "Missing the required parameter 'account_id' when calling RequestsproxyApi.product"
366
+ end
367
+ # verify the required parameter 'external_product_id' is set
368
+ if @api_client.config.client_side_validation && external_product_id.nil?
369
+ fail ArgumentError, "Missing the required parameter 'external_product_id' when calling RequestsproxyApi.product"
370
+ end
371
+ # resource path
372
+ local_var_path = '/v2/{account_id}/products/{external_product_id}'.sub('{' + 'account_id' + '}', account_id.to_s).sub('{' + 'external_product_id' + '}', external_product_id.to_s)
373
+
374
+ # query parameters
375
+ query_params = {}
376
+
377
+ # header parameters
378
+ header_params = {}
379
+ # HTTP header 'Accept' (if needed)
380
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
381
+ # HTTP header 'Content-Type'
382
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
383
+
384
+ # form parameters
385
+ form_params = {}
386
+
387
+ # http body (model)
388
+ post_body = nil
389
+ auth_names = []
390
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
391
+ :header_params => header_params,
392
+ :query_params => query_params,
393
+ :form_params => form_params,
394
+ :body => post_body,
395
+ :auth_names => auth_names,
396
+ :return_type => 'RequestsproxyResponse')
397
+ if @api_client.config.debugging
398
+ @api_client.config.logger.debug "API called: RequestsproxyApi#product\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
399
+ end
400
+ return data, status_code, headers
401
+ end
402
+ # @param account_id
403
+ # @param external_product_id
404
+ # @param [Hash] opts the optional parameters
405
+ # @return [RequestsproxyResponse]
406
+ def product_star_rating(account_id, external_product_id, opts = {})
407
+ data, _status_code, _headers = product_star_rating_with_http_info(account_id, external_product_id, opts)
408
+ data
409
+ end
410
+
411
+ # @param account_id
412
+ # @param external_product_id
413
+ # @param [Hash] opts the optional parameters
414
+ # @return [Array<(RequestsproxyResponse, Fixnum, Hash)>] RequestsproxyResponse data, response status code and response headers
415
+ def product_star_rating_with_http_info(account_id, external_product_id, opts = {})
416
+ if @api_client.config.debugging
417
+ @api_client.config.logger.debug 'Calling API: RequestsproxyApi.product_star_rating ...'
418
+ end
419
+ # verify the required parameter 'account_id' is set
420
+ if @api_client.config.client_side_validation && account_id.nil?
421
+ fail ArgumentError, "Missing the required parameter 'account_id' when calling RequestsproxyApi.product_star_rating"
422
+ end
423
+ # verify the required parameter 'external_product_id' is set
424
+ if @api_client.config.client_side_validation && external_product_id.nil?
425
+ fail ArgumentError, "Missing the required parameter 'external_product_id' when calling RequestsproxyApi.product_star_rating"
426
+ end
427
+ # resource path
428
+ local_var_path = '/v2/{account_id}/star_rating/products/{external_product_id}'.sub('{' + 'account_id' + '}', account_id.to_s).sub('{' + 'external_product_id' + '}', external_product_id.to_s)
429
+
430
+ # query parameters
431
+ query_params = {}
432
+
433
+ # header parameters
434
+ header_params = {}
435
+ # HTTP header 'Accept' (if needed)
436
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
437
+ # HTTP header 'Content-Type'
438
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
439
+
440
+ # form parameters
441
+ form_params = {}
442
+
443
+ # http body (model)
444
+ post_body = nil
445
+ auth_names = []
446
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
447
+ :header_params => header_params,
448
+ :query_params => query_params,
449
+ :form_params => form_params,
450
+ :body => post_body,
451
+ :auth_names => auth_names,
452
+ :return_type => 'RequestsproxyResponse')
453
+ if @api_client.config.debugging
454
+ @api_client.config.logger.debug "API called: RequestsproxyApi#product_star_rating\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
455
+ end
456
+ return data, status_code, headers
457
+ end
458
+ # @param account_id
459
+ # @param [Hash] opts the optional parameters
460
+ # @option opts [String] :page
461
+ # @option opts [String] :count
462
+ # @return [RequestsproxyResponse]
463
+ def products(account_id, opts = {})
464
+ data, _status_code, _headers = products_with_http_info(account_id, opts)
465
+ data
466
+ end
467
+
468
+ # @param account_id
469
+ # @param [Hash] opts the optional parameters
470
+ # @option opts [String] :page
471
+ # @option opts [String] :count
472
+ # @return [Array<(RequestsproxyResponse, Fixnum, Hash)>] RequestsproxyResponse data, response status code and response headers
473
+ def products_with_http_info(account_id, opts = {})
474
+ if @api_client.config.debugging
475
+ @api_client.config.logger.debug 'Calling API: RequestsproxyApi.products ...'
476
+ end
477
+ # verify the required parameter 'account_id' is set
478
+ if @api_client.config.client_side_validation && account_id.nil?
479
+ fail ArgumentError, "Missing the required parameter 'account_id' when calling RequestsproxyApi.products"
480
+ end
481
+ # resource path
482
+ local_var_path = '/v2/{account_id}/products'.sub('{' + 'account_id' + '}', account_id.to_s)
483
+
484
+ # query parameters
485
+ query_params = {}
486
+ query_params[:'page'] = opts[:'page'] if !opts[:'page'].nil?
487
+ query_params[:'count'] = opts[:'count'] if !opts[:'count'].nil?
488
+
489
+ # header parameters
490
+ header_params = {}
491
+ # HTTP header 'Accept' (if needed)
492
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
493
+ # HTTP header 'Content-Type'
494
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
495
+
496
+ # form parameters
497
+ form_params = {}
498
+
499
+ # http body (model)
500
+ post_body = nil
501
+ auth_names = []
502
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
503
+ :header_params => header_params,
504
+ :query_params => query_params,
505
+ :form_params => form_params,
506
+ :body => post_body,
507
+ :auth_names => auth_names,
508
+ :return_type => 'RequestsproxyResponse')
509
+ if @api_client.config.debugging
510
+ @api_client.config.logger.debug "API called: RequestsproxyApi#products\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
511
+ end
512
+ return data, status_code, headers
513
+ end
514
+ # @param account_id
515
+ # @param [Hash] opts the optional parameters
516
+ # @return [RequestsproxyResponse]
517
+ def products_star_rating(account_id, opts = {})
518
+ data, _status_code, _headers = products_star_rating_with_http_info(account_id, opts)
519
+ data
520
+ end
521
+
522
+ # @param account_id
523
+ # @param [Hash] opts the optional parameters
524
+ # @return [Array<(RequestsproxyResponse, Fixnum, Hash)>] RequestsproxyResponse data, response status code and response headers
525
+ def products_star_rating_with_http_info(account_id, opts = {})
526
+ if @api_client.config.debugging
527
+ @api_client.config.logger.debug 'Calling API: RequestsproxyApi.products_star_rating ...'
528
+ end
529
+ # verify the required parameter 'account_id' is set
530
+ if @api_client.config.client_side_validation && account_id.nil?
531
+ fail ArgumentError, "Missing the required parameter 'account_id' when calling RequestsproxyApi.products_star_rating"
532
+ end
533
+ # resource path
534
+ local_var_path = '/v2/{account_id}/star_rating/products'.sub('{' + 'account_id' + '}', account_id.to_s)
535
+
536
+ # query parameters
537
+ query_params = {}
538
+
539
+ # header parameters
540
+ header_params = {}
541
+ # HTTP header 'Accept' (if needed)
542
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
543
+ # HTTP header 'Content-Type'
544
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
545
+
546
+ # form parameters
547
+ form_params = {}
548
+
549
+ # http body (model)
550
+ post_body = nil
551
+ auth_names = []
552
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
553
+ :header_params => header_params,
554
+ :query_params => query_params,
555
+ :form_params => form_params,
556
+ :body => post_body,
557
+ :auth_names => auth_names,
558
+ :return_type => 'RequestsproxyResponse')
559
+ if @api_client.config.debugging
560
+ @api_client.config.logger.debug "API called: RequestsproxyApi#products_star_rating\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
561
+ end
562
+ return data, status_code, headers
563
+ end
564
+ # @param account_id
565
+ # @param [Hash] opts the optional parameters
566
+ # @return [RequestsproxyResponse]
567
+ def promoted_products(account_id, opts = {})
568
+ data, _status_code, _headers = promoted_products_with_http_info(account_id, opts)
569
+ data
570
+ end
571
+
572
+ # @param account_id
573
+ # @param [Hash] opts the optional parameters
574
+ # @return [Array<(RequestsproxyResponse, Fixnum, Hash)>] RequestsproxyResponse data, response status code and response headers
575
+ def promoted_products_with_http_info(account_id, opts = {})
576
+ if @api_client.config.debugging
577
+ @api_client.config.logger.debug 'Calling API: RequestsproxyApi.promoted_products ...'
578
+ end
579
+ # verify the required parameter 'account_id' is set
580
+ if @api_client.config.client_side_validation && account_id.nil?
581
+ fail ArgumentError, "Missing the required parameter 'account_id' when calling RequestsproxyApi.promoted_products"
582
+ end
583
+ # resource path
584
+ local_var_path = '/v2/{account_id}/promoted_products'.sub('{' + 'account_id' + '}', account_id.to_s)
585
+
586
+ # query parameters
587
+ query_params = {}
588
+
589
+ # header parameters
590
+ header_params = {}
591
+ # HTTP header 'Accept' (if needed)
592
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
593
+ # HTTP header 'Content-Type'
594
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
595
+
596
+ # form parameters
597
+ form_params = {}
598
+
599
+ # http body (model)
600
+ post_body = nil
601
+ auth_names = []
602
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
603
+ :header_params => header_params,
604
+ :query_params => query_params,
605
+ :form_params => form_params,
606
+ :body => post_body,
607
+ :auth_names => auth_names,
608
+ :return_type => 'RequestsproxyResponse')
609
+ if @api_client.config.debugging
610
+ @api_client.config.logger.debug "API called: RequestsproxyApi#promoted_products\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
611
+ end
612
+ return data, status_code, headers
613
+ end
614
+ # @param account_id
615
+ # @param review_id
616
+ # @param [Hash] opts the optional parameters
617
+ # @option opts [BOOLEAN] :include_nested
618
+ # @return [RequestsproxyResponse]
619
+ def review(account_id, review_id, opts = {})
620
+ data, _status_code, _headers = review_with_http_info(account_id, review_id, opts)
621
+ data
622
+ end
623
+
624
+ # @param account_id
625
+ # @param review_id
626
+ # @param [Hash] opts the optional parameters
627
+ # @option opts [BOOLEAN] :include_nested
628
+ # @return [Array<(RequestsproxyResponse, Fixnum, Hash)>] RequestsproxyResponse data, response status code and response headers
629
+ def review_with_http_info(account_id, review_id, opts = {})
630
+ if @api_client.config.debugging
631
+ @api_client.config.logger.debug 'Calling API: RequestsproxyApi.review ...'
632
+ end
633
+ # verify the required parameter 'account_id' is set
634
+ if @api_client.config.client_side_validation && account_id.nil?
635
+ fail ArgumentError, "Missing the required parameter 'account_id' when calling RequestsproxyApi.review"
636
+ end
637
+ # verify the required parameter 'review_id' is set
638
+ if @api_client.config.client_side_validation && review_id.nil?
639
+ fail ArgumentError, "Missing the required parameter 'review_id' when calling RequestsproxyApi.review"
640
+ end
641
+ # resource path
642
+ local_var_path = '/v2/{account_id}/reviews/{review_id}'.sub('{' + 'account_id' + '}', account_id.to_s).sub('{' + 'review_id' + '}', review_id.to_s)
643
+
644
+ # query parameters
645
+ query_params = {}
646
+ query_params[:'include_nested'] = opts[:'include_nested'] if !opts[:'include_nested'].nil?
647
+
648
+ # header parameters
649
+ header_params = {}
650
+ # HTTP header 'Accept' (if needed)
651
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
652
+ # HTTP header 'Content-Type'
653
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
654
+
655
+ # form parameters
656
+ form_params = {}
657
+
658
+ # http body (model)
659
+ post_body = nil
660
+ auth_names = []
661
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
662
+ :header_params => header_params,
663
+ :query_params => query_params,
664
+ :form_params => form_params,
665
+ :body => post_body,
666
+ :auth_names => auth_names,
667
+ :return_type => 'RequestsproxyResponse')
668
+ if @api_client.config.debugging
669
+ @api_client.config.logger.debug "API called: RequestsproxyApi#review\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
670
+ end
671
+ return data, status_code, headers
672
+ end
673
+ # @param account_id
674
+ # @param [Hash] opts the optional parameters
675
+ # @option opts [String] :first_id
676
+ # @option opts [String] :count
677
+ # @option opts [String] :page
678
+ # @option opts [String] :include_site_reviews
679
+ # @option opts [String] :sort
680
+ # @option opts [String] :direction
681
+ # @option opts [String] :star
682
+ # @option opts [BOOLEAN] :include_nested
683
+ # @return [RequestsproxyResponse]
684
+ def reviews(account_id, opts = {})
685
+ data, _status_code, _headers = reviews_with_http_info(account_id, opts)
686
+ data
687
+ end
688
+
689
+ # @param account_id
690
+ # @param [Hash] opts the optional parameters
691
+ # @option opts [String] :first_id
692
+ # @option opts [String] :count
693
+ # @option opts [String] :page
694
+ # @option opts [String] :include_site_reviews
695
+ # @option opts [String] :sort
696
+ # @option opts [String] :direction
697
+ # @option opts [String] :star
698
+ # @option opts [BOOLEAN] :include_nested
699
+ # @return [Array<(RequestsproxyResponse, Fixnum, Hash)>] RequestsproxyResponse data, response status code and response headers
700
+ def reviews_with_http_info(account_id, opts = {})
701
+ if @api_client.config.debugging
702
+ @api_client.config.logger.debug 'Calling API: RequestsproxyApi.reviews ...'
703
+ end
704
+ # verify the required parameter 'account_id' is set
705
+ if @api_client.config.client_side_validation && account_id.nil?
706
+ fail ArgumentError, "Missing the required parameter 'account_id' when calling RequestsproxyApi.reviews"
707
+ end
708
+ # resource path
709
+ local_var_path = '/v2/{account_id}/reviews'.sub('{' + 'account_id' + '}', account_id.to_s)
710
+
711
+ # query parameters
712
+ query_params = {}
713
+ query_params[:'first_id'] = opts[:'first_id'] if !opts[:'first_id'].nil?
714
+ query_params[:'count'] = opts[:'count'] if !opts[:'count'].nil?
715
+ query_params[:'page'] = opts[:'page'] if !opts[:'page'].nil?
716
+ query_params[:'include_site_reviews'] = opts[:'include_site_reviews'] if !opts[:'include_site_reviews'].nil?
717
+ query_params[:'sort'] = opts[:'sort'] if !opts[:'sort'].nil?
718
+ query_params[:'direction'] = opts[:'direction'] if !opts[:'direction'].nil?
719
+ query_params[:'star'] = opts[:'star'] if !opts[:'star'].nil?
720
+ query_params[:'include_nested'] = opts[:'include_nested'] if !opts[:'include_nested'].nil?
721
+
722
+ # header parameters
723
+ header_params = {}
724
+ # HTTP header 'Accept' (if needed)
725
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
726
+ # HTTP header 'Content-Type'
727
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
728
+
729
+ # form parameters
730
+ form_params = {}
731
+
732
+ # http body (model)
733
+ post_body = nil
734
+ auth_names = []
735
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
736
+ :header_params => header_params,
737
+ :query_params => query_params,
738
+ :form_params => form_params,
739
+ :body => post_body,
740
+ :auth_names => auth_names,
741
+ :return_type => 'RequestsproxyResponse')
742
+ if @api_client.config.debugging
743
+ @api_client.config.logger.debug "API called: RequestsproxyApi#reviews\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
744
+ end
745
+ return data, status_code, headers
746
+ end
747
+ # @param account_id
748
+ # @param external_product_id
749
+ # @param [Hash] opts the optional parameters
750
+ # @option opts [String] :first_id
751
+ # @option opts [String] :count
752
+ # @option opts [String] :page
753
+ # @option opts [String] :include_site_reviews
754
+ # @option opts [String] :sort
755
+ # @option opts [String] :direction
756
+ # @option opts [String] :star
757
+ # @option opts [BOOLEAN] :include_nested
758
+ # @return [RequestsproxyResponse]
759
+ def reviews_by_product(account_id, external_product_id, opts = {})
760
+ data, _status_code, _headers = reviews_by_product_with_http_info(account_id, external_product_id, opts)
761
+ data
762
+ end
763
+
764
+ # @param account_id
765
+ # @param external_product_id
766
+ # @param [Hash] opts the optional parameters
767
+ # @option opts [String] :first_id
768
+ # @option opts [String] :count
769
+ # @option opts [String] :page
770
+ # @option opts [String] :include_site_reviews
771
+ # @option opts [String] :sort
772
+ # @option opts [String] :direction
773
+ # @option opts [String] :star
774
+ # @option opts [BOOLEAN] :include_nested
775
+ # @return [Array<(RequestsproxyResponse, Fixnum, Hash)>] RequestsproxyResponse data, response status code and response headers
776
+ def reviews_by_product_with_http_info(account_id, external_product_id, opts = {})
777
+ if @api_client.config.debugging
778
+ @api_client.config.logger.debug 'Calling API: RequestsproxyApi.reviews_by_product ...'
779
+ end
780
+ # verify the required parameter 'account_id' is set
781
+ if @api_client.config.client_side_validation && account_id.nil?
782
+ fail ArgumentError, "Missing the required parameter 'account_id' when calling RequestsproxyApi.reviews_by_product"
783
+ end
784
+ # verify the required parameter 'external_product_id' is set
785
+ if @api_client.config.client_side_validation && external_product_id.nil?
786
+ fail ArgumentError, "Missing the required parameter 'external_product_id' when calling RequestsproxyApi.reviews_by_product"
787
+ end
788
+ # resource path
789
+ local_var_path = '/v2/{account_id}/products/{external_product_id}/reviews'.sub('{' + 'account_id' + '}', account_id.to_s).sub('{' + 'external_product_id' + '}', external_product_id.to_s)
790
+
791
+ # query parameters
792
+ query_params = {}
793
+ query_params[:'first_id'] = opts[:'first_id'] if !opts[:'first_id'].nil?
794
+ query_params[:'count'] = opts[:'count'] if !opts[:'count'].nil?
795
+ query_params[:'page'] = opts[:'page'] if !opts[:'page'].nil?
796
+ query_params[:'include_site_reviews'] = opts[:'include_site_reviews'] if !opts[:'include_site_reviews'].nil?
797
+ query_params[:'sort'] = opts[:'sort'] if !opts[:'sort'].nil?
798
+ query_params[:'direction'] = opts[:'direction'] if !opts[:'direction'].nil?
799
+ query_params[:'star'] = opts[:'star'] if !opts[:'star'].nil?
800
+ query_params[:'include_nested'] = opts[:'include_nested'] if !opts[:'include_nested'].nil?
801
+
802
+ # header parameters
803
+ header_params = {}
804
+ # HTTP header 'Accept' (if needed)
805
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
806
+ # HTTP header 'Content-Type'
807
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
808
+
809
+ # form parameters
810
+ form_params = {}
811
+
812
+ # http body (model)
813
+ post_body = nil
814
+ auth_names = []
815
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
816
+ :header_params => header_params,
817
+ :query_params => query_params,
818
+ :form_params => form_params,
819
+ :body => post_body,
820
+ :auth_names => auth_names,
821
+ :return_type => 'RequestsproxyResponse')
822
+ if @api_client.config.debugging
823
+ @api_client.config.logger.debug "API called: RequestsproxyApi#reviews_by_product\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
824
+ end
825
+ return data, status_code, headers
826
+ end
827
+ # @param account_id
828
+ # @param [Hash] opts the optional parameters
829
+ # @option opts [String] :external_product_id
830
+ # @return [RequestsproxyResponse]
831
+ def top_reviews(account_id, opts = {})
832
+ data, _status_code, _headers = top_reviews_with_http_info(account_id, opts)
833
+ data
834
+ end
835
+
836
+ # @param account_id
837
+ # @param [Hash] opts the optional parameters
838
+ # @option opts [String] :external_product_id
839
+ # @return [Array<(RequestsproxyResponse, Fixnum, Hash)>] RequestsproxyResponse data, response status code and response headers
840
+ def top_reviews_with_http_info(account_id, opts = {})
841
+ if @api_client.config.debugging
842
+ @api_client.config.logger.debug 'Calling API: RequestsproxyApi.top_reviews ...'
843
+ end
844
+ # verify the required parameter 'account_id' is set
845
+ if @api_client.config.client_side_validation && account_id.nil?
846
+ fail ArgumentError, "Missing the required parameter 'account_id' when calling RequestsproxyApi.top_reviews"
847
+ end
848
+ # resource path
849
+ local_var_path = '/v2/{account_id}/top_reviews'.sub('{' + 'account_id' + '}', account_id.to_s)
850
+
851
+ # query parameters
852
+ query_params = {}
853
+ query_params[:'external_product_id'] = opts[:'external_product_id'] if !opts[:'external_product_id'].nil?
854
+
855
+ # header parameters
856
+ header_params = {}
857
+ # HTTP header 'Accept' (if needed)
858
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
859
+ # HTTP header 'Content-Type'
860
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
861
+
862
+ # form parameters
863
+ form_params = {}
864
+
865
+ # http body (model)
866
+ post_body = nil
867
+ auth_names = []
868
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
869
+ :header_params => header_params,
870
+ :query_params => query_params,
871
+ :form_params => form_params,
872
+ :body => post_body,
873
+ :auth_names => auth_names,
874
+ :return_type => 'RequestsproxyResponse')
875
+ if @api_client.config.debugging
876
+ @api_client.config.logger.debug "API called: RequestsproxyApi#top_reviews\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
877
+ end
878
+ return data, status_code, headers
879
+ end
880
+ # @param account_id
881
+ # @param id
882
+ # @param body
883
+ # @param [Hash] opts the optional parameters
884
+ # @return [RequestsproxyResponse]
885
+ def update_webhook(account_id, id, body, opts = {})
886
+ data, _status_code, _headers = update_webhook_with_http_info(account_id, id, body, opts)
887
+ data
888
+ end
889
+
890
+ # @param account_id
891
+ # @param id
892
+ # @param body
893
+ # @param [Hash] opts the optional parameters
894
+ # @return [Array<(RequestsproxyResponse, Fixnum, Hash)>] RequestsproxyResponse data, response status code and response headers
895
+ def update_webhook_with_http_info(account_id, id, body, opts = {})
896
+ if @api_client.config.debugging
897
+ @api_client.config.logger.debug 'Calling API: RequestsproxyApi.update_webhook ...'
898
+ end
899
+ # verify the required parameter 'account_id' is set
900
+ if @api_client.config.client_side_validation && account_id.nil?
901
+ fail ArgumentError, "Missing the required parameter 'account_id' when calling RequestsproxyApi.update_webhook"
902
+ end
903
+ # verify the required parameter 'id' is set
904
+ if @api_client.config.client_side_validation && id.nil?
905
+ fail ArgumentError, "Missing the required parameter 'id' when calling RequestsproxyApi.update_webhook"
906
+ end
907
+ # verify the required parameter 'body' is set
908
+ if @api_client.config.client_side_validation && body.nil?
909
+ fail ArgumentError, "Missing the required parameter 'body' when calling RequestsproxyApi.update_webhook"
910
+ end
911
+ # resource path
912
+ local_var_path = '/v2/{account_id}/webhooks/{id}'.sub('{' + 'account_id' + '}', account_id.to_s).sub('{' + 'id' + '}', id.to_s)
913
+
914
+ # query parameters
915
+ query_params = {}
916
+
917
+ # header parameters
918
+ header_params = {}
919
+ # HTTP header 'Accept' (if needed)
920
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
921
+ # HTTP header 'Content-Type'
922
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
923
+
924
+ # form parameters
925
+ form_params = {}
926
+
927
+ # http body (model)
928
+ post_body = @api_client.object_to_http_body(body)
929
+ auth_names = []
930
+ data, status_code, headers = @api_client.call_api(:PUT, local_var_path,
931
+ :header_params => header_params,
932
+ :query_params => query_params,
933
+ :form_params => form_params,
934
+ :body => post_body,
935
+ :auth_names => auth_names,
936
+ :return_type => 'RequestsproxyResponse')
937
+ if @api_client.config.debugging
938
+ @api_client.config.logger.debug "API called: RequestsproxyApi#update_webhook\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
939
+ end
940
+ return data, status_code, headers
941
+ end
942
+ # @param account_id
943
+ # @param user_id
944
+ # @param [Hash] opts the optional parameters
945
+ # @return [RequestsproxyResponse]
946
+ def user(account_id, user_id, opts = {})
947
+ data, _status_code, _headers = user_with_http_info(account_id, user_id, opts)
948
+ data
949
+ end
950
+
951
+ # @param account_id
952
+ # @param user_id
953
+ # @param [Hash] opts the optional parameters
954
+ # @return [Array<(RequestsproxyResponse, Fixnum, Hash)>] RequestsproxyResponse data, response status code and response headers
955
+ def user_with_http_info(account_id, user_id, opts = {})
956
+ if @api_client.config.debugging
957
+ @api_client.config.logger.debug 'Calling API: RequestsproxyApi.user ...'
958
+ end
959
+ # verify the required parameter 'account_id' is set
960
+ if @api_client.config.client_side_validation && account_id.nil?
961
+ fail ArgumentError, "Missing the required parameter 'account_id' when calling RequestsproxyApi.user"
962
+ end
963
+ # verify the required parameter 'user_id' is set
964
+ if @api_client.config.client_side_validation && user_id.nil?
965
+ fail ArgumentError, "Missing the required parameter 'user_id' when calling RequestsproxyApi.user"
966
+ end
967
+ # resource path
968
+ local_var_path = '/v2/{account_id}/users/{user_id}'.sub('{' + 'account_id' + '}', account_id.to_s).sub('{' + 'user_id' + '}', user_id.to_s)
969
+
970
+ # query parameters
971
+ query_params = {}
972
+
973
+ # header parameters
974
+ header_params = {}
975
+ # HTTP header 'Accept' (if needed)
976
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
977
+ # HTTP header 'Content-Type'
978
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
979
+
980
+ # form parameters
981
+ form_params = {}
982
+
983
+ # http body (model)
984
+ post_body = nil
985
+ auth_names = []
986
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
987
+ :header_params => header_params,
988
+ :query_params => query_params,
989
+ :form_params => form_params,
990
+ :body => post_body,
991
+ :auth_names => auth_names,
992
+ :return_type => 'RequestsproxyResponse')
993
+ if @api_client.config.debugging
994
+ @api_client.config.logger.debug "API called: RequestsproxyApi#user\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
995
+ end
996
+ return data, status_code, headers
997
+ end
998
+ # @param account_id
999
+ # @param id
1000
+ # @param [Hash] opts the optional parameters
1001
+ # @option opts [String] :access_token
1002
+ # @return [RequestsproxyResponse]
1003
+ def webhook(account_id, id, opts = {})
1004
+ data, _status_code, _headers = webhook_with_http_info(account_id, id, opts)
1005
+ data
1006
+ end
1007
+
1008
+ # @param account_id
1009
+ # @param id
1010
+ # @param [Hash] opts the optional parameters
1011
+ # @option opts [String] :access_token
1012
+ # @return [Array<(RequestsproxyResponse, Fixnum, Hash)>] RequestsproxyResponse data, response status code and response headers
1013
+ def webhook_with_http_info(account_id, id, opts = {})
1014
+ if @api_client.config.debugging
1015
+ @api_client.config.logger.debug 'Calling API: RequestsproxyApi.webhook ...'
1016
+ end
1017
+ # verify the required parameter 'account_id' is set
1018
+ if @api_client.config.client_side_validation && account_id.nil?
1019
+ fail ArgumentError, "Missing the required parameter 'account_id' when calling RequestsproxyApi.webhook"
1020
+ end
1021
+ # verify the required parameter 'id' is set
1022
+ if @api_client.config.client_side_validation && id.nil?
1023
+ fail ArgumentError, "Missing the required parameter 'id' when calling RequestsproxyApi.webhook"
1024
+ end
1025
+ # resource path
1026
+ local_var_path = '/v2/{account_id}/webhooks/{id}'.sub('{' + 'account_id' + '}', account_id.to_s).sub('{' + 'id' + '}', id.to_s)
1027
+
1028
+ # query parameters
1029
+ query_params = {}
1030
+ query_params[:'access_token'] = opts[:'access_token'] if !opts[:'access_token'].nil?
1031
+
1032
+ # header parameters
1033
+ header_params = {}
1034
+ # HTTP header 'Accept' (if needed)
1035
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
1036
+ # HTTP header 'Content-Type'
1037
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
1038
+
1039
+ # form parameters
1040
+ form_params = {}
1041
+
1042
+ # http body (model)
1043
+ post_body = nil
1044
+ auth_names = []
1045
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
1046
+ :header_params => header_params,
1047
+ :query_params => query_params,
1048
+ :form_params => form_params,
1049
+ :body => post_body,
1050
+ :auth_names => auth_names,
1051
+ :return_type => 'RequestsproxyResponse')
1052
+ if @api_client.config.debugging
1053
+ @api_client.config.logger.debug "API called: RequestsproxyApi#webhook\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1054
+ end
1055
+ return data, status_code, headers
1056
+ end
1057
+ # @param account_id
1058
+ # @param [Hash] opts the optional parameters
1059
+ # @return [RequestsproxyResponse]
1060
+ def webhook_events(account_id, opts = {})
1061
+ data, _status_code, _headers = webhook_events_with_http_info(account_id, opts)
1062
+ data
1063
+ end
1064
+
1065
+ # @param account_id
1066
+ # @param [Hash] opts the optional parameters
1067
+ # @return [Array<(RequestsproxyResponse, Fixnum, Hash)>] RequestsproxyResponse data, response status code and response headers
1068
+ def webhook_events_with_http_info(account_id, opts = {})
1069
+ if @api_client.config.debugging
1070
+ @api_client.config.logger.debug 'Calling API: RequestsproxyApi.webhook_events ...'
1071
+ end
1072
+ # verify the required parameter 'account_id' is set
1073
+ if @api_client.config.client_side_validation && account_id.nil?
1074
+ fail ArgumentError, "Missing the required parameter 'account_id' when calling RequestsproxyApi.webhook_events"
1075
+ end
1076
+ # resource path
1077
+ local_var_path = '/v2/{account_id}/webhook_events'.sub('{' + 'account_id' + '}', account_id.to_s)
1078
+
1079
+ # query parameters
1080
+ query_params = {}
1081
+
1082
+ # header parameters
1083
+ header_params = {}
1084
+ # HTTP header 'Accept' (if needed)
1085
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
1086
+ # HTTP header 'Content-Type'
1087
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
1088
+
1089
+ # form parameters
1090
+ form_params = {}
1091
+
1092
+ # http body (model)
1093
+ post_body = nil
1094
+ auth_names = []
1095
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
1096
+ :header_params => header_params,
1097
+ :query_params => query_params,
1098
+ :form_params => form_params,
1099
+ :body => post_body,
1100
+ :auth_names => auth_names,
1101
+ :return_type => 'RequestsproxyResponse')
1102
+ if @api_client.config.debugging
1103
+ @api_client.config.logger.debug "API called: RequestsproxyApi#webhook_events\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1104
+ end
1105
+ return data, status_code, headers
1106
+ end
1107
+ # @param account_id
1108
+ # @param [Hash] opts the optional parameters
1109
+ # @option opts [String] :access_token
1110
+ # @return [RequestsproxyResponse]
1111
+ def webhooks(account_id, opts = {})
1112
+ data, _status_code, _headers = webhooks_with_http_info(account_id, opts)
1113
+ data
1114
+ end
1115
+
1116
+ # @param account_id
1117
+ # @param [Hash] opts the optional parameters
1118
+ # @option opts [String] :access_token
1119
+ # @return [Array<(RequestsproxyResponse, Fixnum, Hash)>] RequestsproxyResponse data, response status code and response headers
1120
+ def webhooks_with_http_info(account_id, opts = {})
1121
+ if @api_client.config.debugging
1122
+ @api_client.config.logger.debug 'Calling API: RequestsproxyApi.webhooks ...'
1123
+ end
1124
+ # verify the required parameter 'account_id' is set
1125
+ if @api_client.config.client_side_validation && account_id.nil?
1126
+ fail ArgumentError, "Missing the required parameter 'account_id' when calling RequestsproxyApi.webhooks"
1127
+ end
1128
+ # resource path
1129
+ local_var_path = '/v2/{account_id}/webhooks'.sub('{' + 'account_id' + '}', account_id.to_s)
1130
+
1131
+ # query parameters
1132
+ query_params = {}
1133
+ query_params[:'access_token'] = opts[:'access_token'] if !opts[:'access_token'].nil?
1134
+
1135
+ # header parameters
1136
+ header_params = {}
1137
+ # HTTP header 'Accept' (if needed)
1138
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
1139
+ # HTTP header 'Content-Type'
1140
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
1141
+
1142
+ # form parameters
1143
+ form_params = {}
1144
+
1145
+ # http body (model)
1146
+ post_body = nil
1147
+ auth_names = []
1148
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
1149
+ :header_params => header_params,
1150
+ :query_params => query_params,
1151
+ :form_params => form_params,
1152
+ :body => post_body,
1153
+ :auth_names => auth_names,
1154
+ :return_type => 'RequestsproxyResponse')
1155
+ if @api_client.config.debugging
1156
+ @api_client.config.logger.debug "API called: RequestsproxyApi#webhooks\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1157
+ end
1158
+ return data, status_code, headers
1159
+ end
1160
+ end
1161
+ end