qwil_api 0.1.0

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 (230) hide show
  1. checksums.yaml +7 -0
  2. data/README.md +91 -0
  3. data/docs/AccountSerializer.md +18 -0
  4. data/docs/AccountsApi.md +243 -0
  5. data/docs/ApitokenauthApi.md +57 -0
  6. data/docs/CashoutCalculationSerializer.md +10 -0
  7. data/docs/CashoutSerializer.md +20 -0
  8. data/docs/CashoutSliceSerializer.md +11 -0
  9. data/docs/CashoutsApi.md +56 -0
  10. data/docs/CompanyInformationSerializer.md +18 -0
  11. data/docs/ContactInfoSerializer.md +10 -0
  12. data/docs/ContactInformationSerializer.md +16 -0
  13. data/docs/ContractorSerializer.md +20 -0
  14. data/docs/IncomeApi.md +98 -0
  15. data/docs/IncomeNestedSerializer.md +18 -0
  16. data/docs/IncomeSerializer.md +18 -0
  17. data/docs/IncomeSerializerFixedSource.md +18 -0
  18. data/docs/InvoiceSerializer.md +17 -0
  19. data/docs/InvoiceSerializerFixedSourceCreate.md +17 -0
  20. data/docs/InvoicesApi.md +98 -0
  21. data/docs/JSONWebTokenSerializer.md +7 -0
  22. data/docs/ManagerPlatformSerializer.md +22 -0
  23. data/docs/ManagerSerializer.md +10 -0
  24. data/docs/ManagersApi.md +172 -0
  25. data/docs/MembershipSerializer.md +9 -0
  26. data/docs/MembershipsApi.md +56 -0
  27. data/docs/PersonalInformationSerializer.md +16 -0
  28. data/docs/PlaidPublicTokenSerializer.md +8 -0
  29. data/docs/PlatformIncomeRequestSerializer.md +15 -0
  30. data/docs/PlatformMembershipRequestSerializer.md +11 -0
  31. data/docs/PlatformSerializer.md +30 -0
  32. data/docs/PlatformSummarySerializer.md +10 -0
  33. data/docs/PlatformsApi.md +1369 -0
  34. data/docs/RebateSerializer.md +15 -0
  35. data/docs/RebatesApi.md +98 -0
  36. data/docs/ReceivablesSerializer.md +9 -0
  37. data/docs/TaxSavingsSerializer.md +10 -0
  38. data/docs/UserAccountSerializer.md +17 -0
  39. data/docs/UserCashoutSerializer.md +20 -0
  40. data/docs/UserIncomeRequestSerializer.md +15 -0
  41. data/docs/UserPlatformMembershipRequestSerializer.md +13 -0
  42. data/docs/UserSerializer.md +40 -0
  43. data/docs/UsersApi.md +2173 -0
  44. data/docs/WriteAccountSerializer.md +16 -0
  45. data/docs/WriteCashoutCalculationSerializer.md +8 -0
  46. data/docs/WriteCashoutSerializer.md +16 -0
  47. data/docs/WriteCashoutSliceSerializer.md +11 -0
  48. data/docs/WriteCompanyInformationSerializer.md +17 -0
  49. data/docs/WriteContactInfoSerializer.md +10 -0
  50. data/docs/WriteContactInformationSerializer.md +15 -0
  51. data/docs/WriteContractorSerializer.md +14 -0
  52. data/docs/WriteIncomeNestedSerializer.md +12 -0
  53. data/docs/WriteIncomeSerializer.md +13 -0
  54. data/docs/WriteIncomeSerializerFixedSource.md +12 -0
  55. data/docs/WriteInvoiceSerializer.md +13 -0
  56. data/docs/WriteInvoiceSerializerFixedSourceCreate.md +9 -0
  57. data/docs/WriteJSONWebTokenSerializer.md +7 -0
  58. data/docs/WriteManagerPlatformSerializer.md +15 -0
  59. data/docs/WriteManagerSerializer.md +8 -0
  60. data/docs/WriteMembershipSerializer.md +8 -0
  61. data/docs/WritePersonalInformationSerializer.md +16 -0
  62. data/docs/WritePlaidPublicTokenSerializer.md +8 -0
  63. data/docs/WritePlatformIncomeRequestSerializer.md +10 -0
  64. data/docs/WritePlatformMembershipRequestSerializer.md +7 -0
  65. data/docs/WritePlatformSerializer.md +19 -0
  66. data/docs/WritePlatformSummarySerializer.md +8 -0
  67. data/docs/WriteRebateSerializer.md +9 -0
  68. data/docs/WriteReceivablesSerializer.md +8 -0
  69. data/docs/WriteTaxSavingsSerializer.md +8 -0
  70. data/docs/WriteUserAccountSerializer.md +14 -0
  71. data/docs/WriteUserCashoutSerializer.md +15 -0
  72. data/docs/WriteUserIncomeRequestSerializer.md +10 -0
  73. data/docs/WriteUserPlatformMembershipRequestSerializer.md +9 -0
  74. data/docs/WriteUserSerializer.md +21 -0
  75. data/generate-client.sh +6 -0
  76. data/lib/qwil_api/api/accounts_api.rb +320 -0
  77. data/lib/qwil_api/api/apitokenauth_api.rb +87 -0
  78. data/lib/qwil_api/api/cashouts_api.rb +89 -0
  79. data/lib/qwil_api/api/income_api.rb +142 -0
  80. data/lib/qwil_api/api/invoices_api.rb +142 -0
  81. data/lib/qwil_api/api/managers_api.rb +237 -0
  82. data/lib/qwil_api/api/memberships_api.rb +89 -0
  83. data/lib/qwil_api/api/platforms_api.rb +1674 -0
  84. data/lib/qwil_api/api/rebates_api.rb +142 -0
  85. data/lib/qwil_api/api/users_api.rb +2672 -0
  86. data/lib/qwil_api/api_client.rb +376 -0
  87. data/lib/qwil_api/api_error.rb +45 -0
  88. data/lib/qwil_api/configuration.rb +205 -0
  89. data/lib/qwil_api/models/account_serializer.rb +370 -0
  90. data/lib/qwil_api/models/cashout_calculation_serializer.rb +221 -0
  91. data/lib/qwil_api/models/cashout_serializer.rb +379 -0
  92. data/lib/qwil_api/models/cashout_slice_serializer.rb +232 -0
  93. data/lib/qwil_api/models/company_information_serializer.rb +299 -0
  94. data/lib/qwil_api/models/contact_info_serializer.rb +218 -0
  95. data/lib/qwil_api/models/contact_information_serializer.rb +280 -0
  96. data/lib/qwil_api/models/contractor_serializer.rb +361 -0
  97. data/lib/qwil_api/models/income_nested_serializer.rb +302 -0
  98. data/lib/qwil_api/models/income_serializer.rb +302 -0
  99. data/lib/qwil_api/models/income_serializer_fixed_source.rb +302 -0
  100. data/lib/qwil_api/models/invoice_serializer.rb +299 -0
  101. data/lib/qwil_api/models/invoice_serializer_fixed_source_create.rb +299 -0
  102. data/lib/qwil_api/models/json_web_token_serializer.rb +188 -0
  103. data/lib/qwil_api/models/manager_platform_serializer.rb +391 -0
  104. data/lib/qwil_api/models/manager_serializer.rb +218 -0
  105. data/lib/qwil_api/models/membership_serializer.rb +208 -0
  106. data/lib/qwil_api/models/personal_information_serializer.rb +279 -0
  107. data/lib/qwil_api/models/plaid_public_token_serializer.rb +199 -0
  108. data/lib/qwil_api/models/platform_income_request_serializer.rb +307 -0
  109. data/lib/qwil_api/models/platform_membership_request_serializer.rb +262 -0
  110. data/lib/qwil_api/models/platform_serializer.rb +480 -0
  111. data/lib/qwil_api/models/platform_summary_serializer.rb +218 -0
  112. data/lib/qwil_api/models/rebate_serializer.rb +276 -0
  113. data/lib/qwil_api/models/receivables_serializer.rb +208 -0
  114. data/lib/qwil_api/models/tax_savings_serializer.rb +219 -0
  115. data/lib/qwil_api/models/user_account_serializer.rb +359 -0
  116. data/lib/qwil_api/models/user_cashout_serializer.rb +379 -0
  117. data/lib/qwil_api/models/user_income_request_serializer.rb +307 -0
  118. data/lib/qwil_api/models/user_platform_membership_request_serializer.rb +283 -0
  119. data/lib/qwil_api/models/user_serializer.rb +592 -0
  120. data/lib/qwil_api/models/write_account_serializer.rb +331 -0
  121. data/lib/qwil_api/models/write_cashout_calculation_serializer.rb +198 -0
  122. data/lib/qwil_api/models/write_cashout_serializer.rb +316 -0
  123. data/lib/qwil_api/models/write_cashout_slice_serializer.rb +232 -0
  124. data/lib/qwil_api/models/write_company_information_serializer.rb +280 -0
  125. data/lib/qwil_api/models/write_contact_info_serializer.rb +218 -0
  126. data/lib/qwil_api/models/write_contact_information_serializer.rb +262 -0
  127. data/lib/qwil_api/models/write_contractor_serializer.rb +289 -0
  128. data/lib/qwil_api/models/write_income_nested_serializer.rb +236 -0
  129. data/lib/qwil_api/models/write_income_serializer.rb +247 -0
  130. data/lib/qwil_api/models/write_income_serializer_fixed_source.rb +236 -0
  131. data/lib/qwil_api/models/write_invoice_serializer.rb +252 -0
  132. data/lib/qwil_api/models/write_invoice_serializer_fixed_source_create.rb +210 -0
  133. data/lib/qwil_api/models/write_json_web_token_serializer.rb +188 -0
  134. data/lib/qwil_api/models/write_manager_platform_serializer.rb +314 -0
  135. data/lib/qwil_api/models/write_manager_serializer.rb +198 -0
  136. data/lib/qwil_api/models/write_membership_serializer.rb +198 -0
  137. data/lib/qwil_api/models/write_personal_information_serializer.rb +270 -0
  138. data/lib/qwil_api/models/write_plaid_public_token_serializer.rb +199 -0
  139. data/lib/qwil_api/models/write_platform_income_request_serializer.rb +220 -0
  140. data/lib/qwil_api/models/write_platform_membership_request_serializer.rb +188 -0
  141. data/lib/qwil_api/models/write_platform_serializer.rb +309 -0
  142. data/lib/qwil_api/models/write_platform_summary_serializer.rb +198 -0
  143. data/lib/qwil_api/models/write_rebate_serializer.rb +209 -0
  144. data/lib/qwil_api/models/write_receivables_serializer.rb +198 -0
  145. data/lib/qwil_api/models/write_tax_savings_serializer.rb +198 -0
  146. data/lib/qwil_api/models/write_user_account_serializer.rb +312 -0
  147. data/lib/qwil_api/models/write_user_cashout_serializer.rb +307 -0
  148. data/lib/qwil_api/models/write_user_income_request_serializer.rb +220 -0
  149. data/lib/qwil_api/models/write_user_platform_membership_request_serializer.rb +208 -0
  150. data/lib/qwil_api/models/write_user_serializer.rb +358 -0
  151. data/lib/qwil_api/version.rb +24 -0
  152. data/lib/qwil_api.rb +51 -0
  153. data/qwil_api.gemspec +53 -0
  154. data/spec/api/accounts_api_spec.rb +110 -0
  155. data/spec/api/apitokenauth_api_spec.rb +56 -0
  156. data/spec/api/cashouts_api_spec.rb +56 -0
  157. data/spec/api/income_api_spec.rb +67 -0
  158. data/spec/api/invoices_api_spec.rb +67 -0
  159. data/spec/api/managers_api_spec.rb +88 -0
  160. data/spec/api/memberships_api_spec.rb +56 -0
  161. data/spec/api/platforms_api_spec.rb +398 -0
  162. data/spec/api/rebates_api_spec.rb +67 -0
  163. data/spec/api/users_api_spec.rb +625 -0
  164. data/spec/api_client_spec.rb +235 -0
  165. data/spec/configuration_spec.rb +51 -0
  166. data/spec/models/account_serializer_spec.rb +111 -0
  167. data/spec/models/cashout_calculation_serializer_spec.rb +63 -0
  168. data/spec/models/cashout_serializer_spec.rb +135 -0
  169. data/spec/models/cashout_slice_serializer_spec.rb +69 -0
  170. data/spec/models/company_information_serializer_spec.rb +111 -0
  171. data/spec/models/contact_info_serializer_spec.rb +63 -0
  172. data/spec/models/contact_information_serializer_spec.rb +99 -0
  173. data/spec/models/contractor_serializer_spec.rb +127 -0
  174. data/spec/models/income_nested_serializer_spec.rb +111 -0
  175. data/spec/models/income_serializer_fixed_source_spec.rb +111 -0
  176. data/spec/models/income_serializer_spec.rb +111 -0
  177. data/spec/models/invoice_serializer_fixed_source_create_spec.rb +105 -0
  178. data/spec/models/invoice_serializer_spec.rb +105 -0
  179. data/spec/models/json_web_token_serializer_spec.rb +45 -0
  180. data/spec/models/manager_platform_serializer_spec.rb +143 -0
  181. data/spec/models/manager_serializer_spec.rb +63 -0
  182. data/spec/models/membership_serializer_spec.rb +57 -0
  183. data/spec/models/personal_information_serializer_spec.rb +99 -0
  184. data/spec/models/plaid_public_token_serializer_spec.rb +51 -0
  185. data/spec/models/platform_income_request_serializer_spec.rb +97 -0
  186. data/spec/models/platform_membership_request_serializer_spec.rb +73 -0
  187. data/spec/models/platform_serializer_spec.rb +191 -0
  188. data/spec/models/platform_summary_serializer_spec.rb +63 -0
  189. data/spec/models/rebate_serializer_spec.rb +93 -0
  190. data/spec/models/receivables_serializer_spec.rb +57 -0
  191. data/spec/models/tax_savings_serializer_spec.rb +63 -0
  192. data/spec/models/user_account_serializer_spec.rb +105 -0
  193. data/spec/models/user_cashout_serializer_spec.rb +135 -0
  194. data/spec/models/user_income_request_serializer_spec.rb +97 -0
  195. data/spec/models/user_platform_membership_request_serializer_spec.rb +85 -0
  196. data/spec/models/user_serializer_spec.rb +251 -0
  197. data/spec/models/write_account_serializer_spec.rb +99 -0
  198. data/spec/models/write_cashout_calculation_serializer_spec.rb +51 -0
  199. data/spec/models/write_cashout_serializer_spec.rb +107 -0
  200. data/spec/models/write_cashout_slice_serializer_spec.rb +69 -0
  201. data/spec/models/write_company_information_serializer_spec.rb +105 -0
  202. data/spec/models/write_contact_info_serializer_spec.rb +63 -0
  203. data/spec/models/write_contact_information_serializer_spec.rb +93 -0
  204. data/spec/models/write_contractor_serializer_spec.rb +91 -0
  205. data/spec/models/write_income_nested_serializer_spec.rb +75 -0
  206. data/spec/models/write_income_serializer_fixed_source_spec.rb +75 -0
  207. data/spec/models/write_income_serializer_spec.rb +81 -0
  208. data/spec/models/write_invoice_serializer_fixed_source_create_spec.rb +57 -0
  209. data/spec/models/write_invoice_serializer_spec.rb +81 -0
  210. data/spec/models/write_json_web_token_serializer_spec.rb +45 -0
  211. data/spec/models/write_manager_platform_serializer_spec.rb +101 -0
  212. data/spec/models/write_manager_serializer_spec.rb +51 -0
  213. data/spec/models/write_membership_serializer_spec.rb +51 -0
  214. data/spec/models/write_personal_information_serializer_spec.rb +99 -0
  215. data/spec/models/write_plaid_public_token_serializer_spec.rb +51 -0
  216. data/spec/models/write_platform_income_request_serializer_spec.rb +63 -0
  217. data/spec/models/write_platform_membership_request_serializer_spec.rb +45 -0
  218. data/spec/models/write_platform_serializer_spec.rb +117 -0
  219. data/spec/models/write_platform_summary_serializer_spec.rb +51 -0
  220. data/spec/models/write_rebate_serializer_spec.rb +57 -0
  221. data/spec/models/write_receivables_serializer_spec.rb +51 -0
  222. data/spec/models/write_tax_savings_serializer_spec.rb +51 -0
  223. data/spec/models/write_user_account_serializer_spec.rb +87 -0
  224. data/spec/models/write_user_cashout_serializer_spec.rb +101 -0
  225. data/spec/models/write_user_income_request_serializer_spec.rb +63 -0
  226. data/spec/models/write_user_platform_membership_request_serializer_spec.rb +57 -0
  227. data/spec/models/write_user_serializer_spec.rb +133 -0
  228. data/spec/spec_helper.rb +120 -0
  229. data/swagger-codegen-config.json +9 -0
  230. metadata +527 -0
@@ -0,0 +1,1674 @@
1
+ =begin
2
+ #No descripton provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen)
3
+
4
+ OpenAPI spec version:
5
+
6
+ Generated by: https://github.com/swagger-api/swagger-codegen.git
7
+
8
+ Licensed under the Apache License, Version 2.0 (the "License");
9
+ you may not use this file except in compliance with the License.
10
+ You may obtain a copy of the License at
11
+
12
+ http://www.apache.org/licenses/LICENSE-2.0
13
+
14
+ Unless required by applicable law or agreed to in writing, software
15
+ distributed under the License is distributed on an "AS IS" BASIS,
16
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
17
+ See the License for the specific language governing permissions and
18
+ limitations under the License.
19
+
20
+ =end
21
+
22
+ require "uri"
23
+
24
+ module QwilAPI
25
+ class PlatformsApi
26
+ attr_accessor :api_client
27
+
28
+ def initialize(api_client = ApiClient.default)
29
+ @api_client = api_client
30
+ end
31
+
32
+ # View to offer a
33
+ # View to offer a ./accept endpoint for accepting a IncomeRequest.
34
+ # @param platform_pk
35
+ # @param pk
36
+ # @param [Hash] opts the optional parameters
37
+ # @return [Object]
38
+ def accept_income_request_get(platform_pk, pk, opts = {})
39
+ data, _status_code, _headers = accept_income_request_get_with_http_info(platform_pk, pk, opts)
40
+ return data
41
+ end
42
+
43
+ # View to offer a
44
+ # View to offer a ./accept endpoint for accepting a IncomeRequest.
45
+ # @param platform_pk
46
+ # @param pk
47
+ # @param [Hash] opts the optional parameters
48
+ # @return [Array<(Object, Fixnum, Hash)>] Object data, response status code and response headers
49
+ def accept_income_request_get_with_http_info(platform_pk, pk, opts = {})
50
+ if @api_client.config.debugging
51
+ @api_client.config.logger.debug "Calling API: PlatformsApi.accept_income_request_get ..."
52
+ end
53
+ # verify the required parameter 'platform_pk' is set
54
+ fail ArgumentError, "Missing the required parameter 'platform_pk' when calling PlatformsApi.accept_income_request_get" if platform_pk.nil?
55
+ # verify the required parameter 'pk' is set
56
+ fail ArgumentError, "Missing the required parameter 'pk' when calling PlatformsApi.accept_income_request_get" if pk.nil?
57
+ # resource path
58
+ local_var_path = "/platforms/{platform_pk}/income_requests/{pk}/accept/".sub('{format}','json').sub('{' + 'platform_pk' + '}', platform_pk.to_s).sub('{' + 'pk' + '}', pk.to_s)
59
+
60
+ # query parameters
61
+ query_params = {}
62
+
63
+ # header parameters
64
+ header_params = {}
65
+
66
+ # HTTP header 'Accept' (if needed)
67
+ local_header_accept = []
68
+ local_header_accept_result = @api_client.select_header_accept(local_header_accept) and header_params['Accept'] = local_header_accept_result
69
+
70
+ # HTTP header 'Content-Type'
71
+ local_header_content_type = []
72
+ header_params['Content-Type'] = @api_client.select_header_content_type(local_header_content_type)
73
+
74
+ # form parameters
75
+ form_params = {}
76
+
77
+ # http body (model)
78
+ post_body = nil
79
+ auth_names = []
80
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
81
+ :header_params => header_params,
82
+ :query_params => query_params,
83
+ :form_params => form_params,
84
+ :body => post_body,
85
+ :auth_names => auth_names,
86
+ :return_type => 'Object')
87
+ if @api_client.config.debugging
88
+ @api_client.config.logger.debug "API called: PlatformsApi#accept_income_request_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
89
+ end
90
+ return data, status_code, headers
91
+ end
92
+
93
+ # View to offer a
94
+ # View to offer a ./accept endpoint for accepting a IncomeRequest.
95
+ # @param platform_pk
96
+ # @param pk
97
+ # @param [Hash] opts the optional parameters
98
+ # @return [Object]
99
+ def accept_income_request_post(platform_pk, pk, opts = {})
100
+ data, _status_code, _headers = accept_income_request_post_with_http_info(platform_pk, pk, opts)
101
+ return data
102
+ end
103
+
104
+ # View to offer a
105
+ # View to offer a ./accept endpoint for accepting a IncomeRequest.
106
+ # @param platform_pk
107
+ # @param pk
108
+ # @param [Hash] opts the optional parameters
109
+ # @return [Array<(Object, Fixnum, Hash)>] Object data, response status code and response headers
110
+ def accept_income_request_post_with_http_info(platform_pk, pk, opts = {})
111
+ if @api_client.config.debugging
112
+ @api_client.config.logger.debug "Calling API: PlatformsApi.accept_income_request_post ..."
113
+ end
114
+ # verify the required parameter 'platform_pk' is set
115
+ fail ArgumentError, "Missing the required parameter 'platform_pk' when calling PlatformsApi.accept_income_request_post" if platform_pk.nil?
116
+ # verify the required parameter 'pk' is set
117
+ fail ArgumentError, "Missing the required parameter 'pk' when calling PlatformsApi.accept_income_request_post" if pk.nil?
118
+ # resource path
119
+ local_var_path = "/platforms/{platform_pk}/income_requests/{pk}/accept/".sub('{format}','json').sub('{' + 'platform_pk' + '}', platform_pk.to_s).sub('{' + 'pk' + '}', pk.to_s)
120
+
121
+ # query parameters
122
+ query_params = {}
123
+
124
+ # header parameters
125
+ header_params = {}
126
+
127
+ # HTTP header 'Accept' (if needed)
128
+ local_header_accept = []
129
+ local_header_accept_result = @api_client.select_header_accept(local_header_accept) and header_params['Accept'] = local_header_accept_result
130
+
131
+ # HTTP header 'Content-Type'
132
+ local_header_content_type = []
133
+ header_params['Content-Type'] = @api_client.select_header_content_type(local_header_content_type)
134
+
135
+ # form parameters
136
+ form_params = {}
137
+
138
+ # http body (model)
139
+ post_body = nil
140
+ auth_names = []
141
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path,
142
+ :header_params => header_params,
143
+ :query_params => query_params,
144
+ :form_params => form_params,
145
+ :body => post_body,
146
+ :auth_names => auth_names,
147
+ :return_type => 'Object')
148
+ if @api_client.config.debugging
149
+ @api_client.config.logger.debug "API called: PlatformsApi#accept_income_request_post\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
150
+ end
151
+ return data, status_code, headers
152
+ end
153
+
154
+ # View to offer a
155
+ # View to offer a ./accept endpoint for accepting a PlatformMembershipRequest.
156
+ # @param platform_pk
157
+ # @param pk
158
+ # @param [Hash] opts the optional parameters
159
+ # @return [Object]
160
+ def accept_platform_membership_request_get(platform_pk, pk, opts = {})
161
+ data, _status_code, _headers = accept_platform_membership_request_get_with_http_info(platform_pk, pk, opts)
162
+ return data
163
+ end
164
+
165
+ # View to offer a
166
+ # View to offer a ./accept endpoint for accepting a PlatformMembershipRequest.
167
+ # @param platform_pk
168
+ # @param pk
169
+ # @param [Hash] opts the optional parameters
170
+ # @return [Array<(Object, Fixnum, Hash)>] Object data, response status code and response headers
171
+ def accept_platform_membership_request_get_with_http_info(platform_pk, pk, opts = {})
172
+ if @api_client.config.debugging
173
+ @api_client.config.logger.debug "Calling API: PlatformsApi.accept_platform_membership_request_get ..."
174
+ end
175
+ # verify the required parameter 'platform_pk' is set
176
+ fail ArgumentError, "Missing the required parameter 'platform_pk' when calling PlatformsApi.accept_platform_membership_request_get" if platform_pk.nil?
177
+ # verify the required parameter 'pk' is set
178
+ fail ArgumentError, "Missing the required parameter 'pk' when calling PlatformsApi.accept_platform_membership_request_get" if pk.nil?
179
+ # resource path
180
+ local_var_path = "/platforms/{platform_pk}/membership_requests/{pk}/accept/".sub('{format}','json').sub('{' + 'platform_pk' + '}', platform_pk.to_s).sub('{' + 'pk' + '}', pk.to_s)
181
+
182
+ # query parameters
183
+ query_params = {}
184
+
185
+ # header parameters
186
+ header_params = {}
187
+
188
+ # HTTP header 'Accept' (if needed)
189
+ local_header_accept = []
190
+ local_header_accept_result = @api_client.select_header_accept(local_header_accept) and header_params['Accept'] = local_header_accept_result
191
+
192
+ # HTTP header 'Content-Type'
193
+ local_header_content_type = []
194
+ header_params['Content-Type'] = @api_client.select_header_content_type(local_header_content_type)
195
+
196
+ # form parameters
197
+ form_params = {}
198
+
199
+ # http body (model)
200
+ post_body = nil
201
+ auth_names = []
202
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
203
+ :header_params => header_params,
204
+ :query_params => query_params,
205
+ :form_params => form_params,
206
+ :body => post_body,
207
+ :auth_names => auth_names,
208
+ :return_type => 'Object')
209
+ if @api_client.config.debugging
210
+ @api_client.config.logger.debug "API called: PlatformsApi#accept_platform_membership_request_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
211
+ end
212
+ return data, status_code, headers
213
+ end
214
+
215
+ # View to offer a
216
+ # View to offer a ./accept endpoint for accepting a PlatformMembershipRequest.
217
+ # @param platform_pk
218
+ # @param pk
219
+ # @param [Hash] opts the optional parameters
220
+ # @return [Object]
221
+ def accept_platform_membership_request_post(platform_pk, pk, opts = {})
222
+ data, _status_code, _headers = accept_platform_membership_request_post_with_http_info(platform_pk, pk, opts)
223
+ return data
224
+ end
225
+
226
+ # View to offer a
227
+ # View to offer a ./accept endpoint for accepting a PlatformMembershipRequest.
228
+ # @param platform_pk
229
+ # @param pk
230
+ # @param [Hash] opts the optional parameters
231
+ # @return [Array<(Object, Fixnum, Hash)>] Object data, response status code and response headers
232
+ def accept_platform_membership_request_post_with_http_info(platform_pk, pk, opts = {})
233
+ if @api_client.config.debugging
234
+ @api_client.config.logger.debug "Calling API: PlatformsApi.accept_platform_membership_request_post ..."
235
+ end
236
+ # verify the required parameter 'platform_pk' is set
237
+ fail ArgumentError, "Missing the required parameter 'platform_pk' when calling PlatformsApi.accept_platform_membership_request_post" if platform_pk.nil?
238
+ # verify the required parameter 'pk' is set
239
+ fail ArgumentError, "Missing the required parameter 'pk' when calling PlatformsApi.accept_platform_membership_request_post" if pk.nil?
240
+ # resource path
241
+ local_var_path = "/platforms/{platform_pk}/membership_requests/{pk}/accept/".sub('{format}','json').sub('{' + 'platform_pk' + '}', platform_pk.to_s).sub('{' + 'pk' + '}', pk.to_s)
242
+
243
+ # query parameters
244
+ query_params = {}
245
+
246
+ # header parameters
247
+ header_params = {}
248
+
249
+ # HTTP header 'Accept' (if needed)
250
+ local_header_accept = []
251
+ local_header_accept_result = @api_client.select_header_accept(local_header_accept) and header_params['Accept'] = local_header_accept_result
252
+
253
+ # HTTP header 'Content-Type'
254
+ local_header_content_type = []
255
+ header_params['Content-Type'] = @api_client.select_header_content_type(local_header_content_type)
256
+
257
+ # form parameters
258
+ form_params = {}
259
+
260
+ # http body (model)
261
+ post_body = nil
262
+ auth_names = []
263
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path,
264
+ :header_params => header_params,
265
+ :query_params => query_params,
266
+ :form_params => form_params,
267
+ :body => post_body,
268
+ :auth_names => auth_names,
269
+ :return_type => 'Object')
270
+ if @api_client.config.debugging
271
+ @api_client.config.logger.debug "API called: PlatformsApi#accept_platform_membership_request_post\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
272
+ end
273
+ return data, status_code, headers
274
+ end
275
+
276
+ # View to offer a
277
+ # View to offer a ./deny endpoint for denying a IncomeRequest.
278
+ # @param platform_pk
279
+ # @param pk
280
+ # @param [Hash] opts the optional parameters
281
+ # @return [Object]
282
+ def deny_income_request_get(platform_pk, pk, opts = {})
283
+ data, _status_code, _headers = deny_income_request_get_with_http_info(platform_pk, pk, opts)
284
+ return data
285
+ end
286
+
287
+ # View to offer a
288
+ # View to offer a ./deny endpoint for denying a IncomeRequest.
289
+ # @param platform_pk
290
+ # @param pk
291
+ # @param [Hash] opts the optional parameters
292
+ # @return [Array<(Object, Fixnum, Hash)>] Object data, response status code and response headers
293
+ def deny_income_request_get_with_http_info(platform_pk, pk, opts = {})
294
+ if @api_client.config.debugging
295
+ @api_client.config.logger.debug "Calling API: PlatformsApi.deny_income_request_get ..."
296
+ end
297
+ # verify the required parameter 'platform_pk' is set
298
+ fail ArgumentError, "Missing the required parameter 'platform_pk' when calling PlatformsApi.deny_income_request_get" if platform_pk.nil?
299
+ # verify the required parameter 'pk' is set
300
+ fail ArgumentError, "Missing the required parameter 'pk' when calling PlatformsApi.deny_income_request_get" if pk.nil?
301
+ # resource path
302
+ local_var_path = "/platforms/{platform_pk}/income_requests/{pk}/deny/".sub('{format}','json').sub('{' + 'platform_pk' + '}', platform_pk.to_s).sub('{' + 'pk' + '}', pk.to_s)
303
+
304
+ # query parameters
305
+ query_params = {}
306
+
307
+ # header parameters
308
+ header_params = {}
309
+
310
+ # HTTP header 'Accept' (if needed)
311
+ local_header_accept = []
312
+ local_header_accept_result = @api_client.select_header_accept(local_header_accept) and header_params['Accept'] = local_header_accept_result
313
+
314
+ # HTTP header 'Content-Type'
315
+ local_header_content_type = []
316
+ header_params['Content-Type'] = @api_client.select_header_content_type(local_header_content_type)
317
+
318
+ # form parameters
319
+ form_params = {}
320
+
321
+ # http body (model)
322
+ post_body = nil
323
+ auth_names = []
324
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
325
+ :header_params => header_params,
326
+ :query_params => query_params,
327
+ :form_params => form_params,
328
+ :body => post_body,
329
+ :auth_names => auth_names,
330
+ :return_type => 'Object')
331
+ if @api_client.config.debugging
332
+ @api_client.config.logger.debug "API called: PlatformsApi#deny_income_request_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
333
+ end
334
+ return data, status_code, headers
335
+ end
336
+
337
+ # View to offer a
338
+ # View to offer a ./deny endpoint for denying a IncomeRequest.
339
+ # @param platform_pk
340
+ # @param pk
341
+ # @param [Hash] opts the optional parameters
342
+ # @return [Object]
343
+ def deny_income_request_post(platform_pk, pk, opts = {})
344
+ data, _status_code, _headers = deny_income_request_post_with_http_info(platform_pk, pk, opts)
345
+ return data
346
+ end
347
+
348
+ # View to offer a
349
+ # View to offer a ./deny endpoint for denying a IncomeRequest.
350
+ # @param platform_pk
351
+ # @param pk
352
+ # @param [Hash] opts the optional parameters
353
+ # @return [Array<(Object, Fixnum, Hash)>] Object data, response status code and response headers
354
+ def deny_income_request_post_with_http_info(platform_pk, pk, opts = {})
355
+ if @api_client.config.debugging
356
+ @api_client.config.logger.debug "Calling API: PlatformsApi.deny_income_request_post ..."
357
+ end
358
+ # verify the required parameter 'platform_pk' is set
359
+ fail ArgumentError, "Missing the required parameter 'platform_pk' when calling PlatformsApi.deny_income_request_post" if platform_pk.nil?
360
+ # verify the required parameter 'pk' is set
361
+ fail ArgumentError, "Missing the required parameter 'pk' when calling PlatformsApi.deny_income_request_post" if pk.nil?
362
+ # resource path
363
+ local_var_path = "/platforms/{platform_pk}/income_requests/{pk}/deny/".sub('{format}','json').sub('{' + 'platform_pk' + '}', platform_pk.to_s).sub('{' + 'pk' + '}', pk.to_s)
364
+
365
+ # query parameters
366
+ query_params = {}
367
+
368
+ # header parameters
369
+ header_params = {}
370
+
371
+ # HTTP header 'Accept' (if needed)
372
+ local_header_accept = []
373
+ local_header_accept_result = @api_client.select_header_accept(local_header_accept) and header_params['Accept'] = local_header_accept_result
374
+
375
+ # HTTP header 'Content-Type'
376
+ local_header_content_type = []
377
+ header_params['Content-Type'] = @api_client.select_header_content_type(local_header_content_type)
378
+
379
+ # form parameters
380
+ form_params = {}
381
+
382
+ # http body (model)
383
+ post_body = nil
384
+ auth_names = []
385
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path,
386
+ :header_params => header_params,
387
+ :query_params => query_params,
388
+ :form_params => form_params,
389
+ :body => post_body,
390
+ :auth_names => auth_names,
391
+ :return_type => 'Object')
392
+ if @api_client.config.debugging
393
+ @api_client.config.logger.debug "API called: PlatformsApi#deny_income_request_post\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
394
+ end
395
+ return data, status_code, headers
396
+ end
397
+
398
+ # View to offer a
399
+ # View to offer a ./accept endpoint for accepting a PlatformMembershipRequest.
400
+ # @param platform_pk
401
+ # @param pk
402
+ # @param [Hash] opts the optional parameters
403
+ # @return [Object]
404
+ def deny_platform_membership_request_get(platform_pk, pk, opts = {})
405
+ data, _status_code, _headers = deny_platform_membership_request_get_with_http_info(platform_pk, pk, opts)
406
+ return data
407
+ end
408
+
409
+ # View to offer a
410
+ # View to offer a ./accept endpoint for accepting a PlatformMembershipRequest.
411
+ # @param platform_pk
412
+ # @param pk
413
+ # @param [Hash] opts the optional parameters
414
+ # @return [Array<(Object, Fixnum, Hash)>] Object data, response status code and response headers
415
+ def deny_platform_membership_request_get_with_http_info(platform_pk, pk, opts = {})
416
+ if @api_client.config.debugging
417
+ @api_client.config.logger.debug "Calling API: PlatformsApi.deny_platform_membership_request_get ..."
418
+ end
419
+ # verify the required parameter 'platform_pk' is set
420
+ fail ArgumentError, "Missing the required parameter 'platform_pk' when calling PlatformsApi.deny_platform_membership_request_get" if platform_pk.nil?
421
+ # verify the required parameter 'pk' is set
422
+ fail ArgumentError, "Missing the required parameter 'pk' when calling PlatformsApi.deny_platform_membership_request_get" if pk.nil?
423
+ # resource path
424
+ local_var_path = "/platforms/{platform_pk}/membership_requests/{pk}/deny/".sub('{format}','json').sub('{' + 'platform_pk' + '}', platform_pk.to_s).sub('{' + 'pk' + '}', pk.to_s)
425
+
426
+ # query parameters
427
+ query_params = {}
428
+
429
+ # header parameters
430
+ header_params = {}
431
+
432
+ # HTTP header 'Accept' (if needed)
433
+ local_header_accept = []
434
+ local_header_accept_result = @api_client.select_header_accept(local_header_accept) and header_params['Accept'] = local_header_accept_result
435
+
436
+ # HTTP header 'Content-Type'
437
+ local_header_content_type = []
438
+ header_params['Content-Type'] = @api_client.select_header_content_type(local_header_content_type)
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 => 'Object')
453
+ if @api_client.config.debugging
454
+ @api_client.config.logger.debug "API called: PlatformsApi#deny_platform_membership_request_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
455
+ end
456
+ return data, status_code, headers
457
+ end
458
+
459
+ # View to offer a
460
+ # View to offer a ./accept endpoint for accepting a PlatformMembershipRequest.
461
+ # @param platform_pk
462
+ # @param pk
463
+ # @param [Hash] opts the optional parameters
464
+ # @return [Object]
465
+ def deny_platform_membership_request_post(platform_pk, pk, opts = {})
466
+ data, _status_code, _headers = deny_platform_membership_request_post_with_http_info(platform_pk, pk, opts)
467
+ return data
468
+ end
469
+
470
+ # View to offer a
471
+ # View to offer a ./accept endpoint for accepting a PlatformMembershipRequest.
472
+ # @param platform_pk
473
+ # @param pk
474
+ # @param [Hash] opts the optional parameters
475
+ # @return [Array<(Object, Fixnum, Hash)>] Object data, response status code and response headers
476
+ def deny_platform_membership_request_post_with_http_info(platform_pk, pk, opts = {})
477
+ if @api_client.config.debugging
478
+ @api_client.config.logger.debug "Calling API: PlatformsApi.deny_platform_membership_request_post ..."
479
+ end
480
+ # verify the required parameter 'platform_pk' is set
481
+ fail ArgumentError, "Missing the required parameter 'platform_pk' when calling PlatformsApi.deny_platform_membership_request_post" if platform_pk.nil?
482
+ # verify the required parameter 'pk' is set
483
+ fail ArgumentError, "Missing the required parameter 'pk' when calling PlatformsApi.deny_platform_membership_request_post" if pk.nil?
484
+ # resource path
485
+ local_var_path = "/platforms/{platform_pk}/membership_requests/{pk}/deny/".sub('{format}','json').sub('{' + 'platform_pk' + '}', platform_pk.to_s).sub('{' + 'pk' + '}', pk.to_s)
486
+
487
+ # query parameters
488
+ query_params = {}
489
+
490
+ # header parameters
491
+ header_params = {}
492
+
493
+ # HTTP header 'Accept' (if needed)
494
+ local_header_accept = []
495
+ local_header_accept_result = @api_client.select_header_accept(local_header_accept) and header_params['Accept'] = local_header_accept_result
496
+
497
+ # HTTP header 'Content-Type'
498
+ local_header_content_type = []
499
+ header_params['Content-Type'] = @api_client.select_header_content_type(local_header_content_type)
500
+
501
+ # form parameters
502
+ form_params = {}
503
+
504
+ # http body (model)
505
+ post_body = nil
506
+ auth_names = []
507
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path,
508
+ :header_params => header_params,
509
+ :query_params => query_params,
510
+ :form_params => form_params,
511
+ :body => post_body,
512
+ :auth_names => auth_names,
513
+ :return_type => 'Object')
514
+ if @api_client.config.debugging
515
+ @api_client.config.logger.debug "API called: PlatformsApi#deny_platform_membership_request_post\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
516
+ end
517
+ return data, status_code, headers
518
+ end
519
+
520
+ # The list of Income items for a specific User
521
+ # The list of Income items for a specific User.<br/>This can be filtered by date using the start_date and end_date query parameters.
522
+ # @param platform_pk
523
+ # @param user
524
+ # @param amount
525
+ # @param [Hash] opts the optional parameters
526
+ # @option opts [String] :external_id Optional unique ID to correlate this Income to a record in another system. If specified, this will prevent duplicate Incomes being created with the same external_id. This field is unique per Platform. If this field is omitted, no uniqueness check is performed.
527
+ # @option opts [DateTime] :payment_time
528
+ # @option opts [String] :notes
529
+ # @return [IncomeSerializerFixedSource]
530
+ def income_platform_create(platform_pk, user, amount, opts = {})
531
+ data, _status_code, _headers = income_platform_create_with_http_info(platform_pk, user, amount, opts)
532
+ return data
533
+ end
534
+
535
+ # The list of Income items for a specific User
536
+ # The list of Income items for a specific User.&lt;br/&gt;This can be filtered by date using the start_date and end_date query parameters.
537
+ # @param platform_pk
538
+ # @param user
539
+ # @param amount
540
+ # @param [Hash] opts the optional parameters
541
+ # @option opts [String] :external_id Optional unique ID to correlate this Income to a record in another system. If specified, this will prevent duplicate Incomes being created with the same external_id. This field is unique per Platform. If this field is omitted, no uniqueness check is performed.
542
+ # @option opts [DateTime] :payment_time
543
+ # @option opts [String] :notes
544
+ # @return [Array<(IncomeSerializerFixedSource, Fixnum, Hash)>] IncomeSerializerFixedSource data, response status code and response headers
545
+ def income_platform_create_with_http_info(platform_pk, user, amount, opts = {})
546
+ if @api_client.config.debugging
547
+ @api_client.config.logger.debug "Calling API: PlatformsApi.income_platform_create ..."
548
+ end
549
+ # verify the required parameter 'platform_pk' is set
550
+ fail ArgumentError, "Missing the required parameter 'platform_pk' when calling PlatformsApi.income_platform_create" if platform_pk.nil?
551
+ # verify the required parameter 'user' is set
552
+ fail ArgumentError, "Missing the required parameter 'user' when calling PlatformsApi.income_platform_create" if user.nil?
553
+ # verify the required parameter 'amount' is set
554
+ fail ArgumentError, "Missing the required parameter 'amount' when calling PlatformsApi.income_platform_create" if amount.nil?
555
+ # resource path
556
+ local_var_path = "/platforms/{platform_pk}/income/".sub('{format}','json').sub('{' + 'platform_pk' + '}', platform_pk.to_s)
557
+
558
+ # query parameters
559
+ query_params = {}
560
+
561
+ # header parameters
562
+ header_params = {}
563
+
564
+ # HTTP header 'Accept' (if needed)
565
+ local_header_accept = []
566
+ local_header_accept_result = @api_client.select_header_accept(local_header_accept) and header_params['Accept'] = local_header_accept_result
567
+
568
+ # HTTP header 'Content-Type'
569
+ local_header_content_type = []
570
+ header_params['Content-Type'] = @api_client.select_header_content_type(local_header_content_type)
571
+
572
+ # form parameters
573
+ form_params = {}
574
+ form_params["user"] = user
575
+ form_params["amount"] = amount
576
+ form_params["external_id"] = opts[:'external_id'] if !opts[:'external_id'].nil?
577
+ form_params["payment_time"] = opts[:'payment_time'] if !opts[:'payment_time'].nil?
578
+ form_params["notes"] = opts[:'notes'] if !opts[:'notes'].nil?
579
+
580
+ # http body (model)
581
+ post_body = nil
582
+ auth_names = []
583
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path,
584
+ :header_params => header_params,
585
+ :query_params => query_params,
586
+ :form_params => form_params,
587
+ :body => post_body,
588
+ :auth_names => auth_names,
589
+ :return_type => 'IncomeSerializerFixedSource')
590
+ if @api_client.config.debugging
591
+ @api_client.config.logger.debug "API called: PlatformsApi#income_platform_create\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
592
+ end
593
+ return data, status_code, headers
594
+ end
595
+
596
+ # The list of Income items for a specific User
597
+ # The list of Income items for a specific User.<br/>This can be filtered by date using the start_date and end_date query parameters.
598
+ # @param platform_pk
599
+ # @param [Hash] opts the optional parameters
600
+ # @return [Array<IncomeSerializerFixedSource>]
601
+ def income_platform_list(platform_pk, opts = {})
602
+ data, _status_code, _headers = income_platform_list_with_http_info(platform_pk, opts)
603
+ return data
604
+ end
605
+
606
+ # The list of Income items for a specific User
607
+ # The list of Income items for a specific User.&lt;br/&gt;This can be filtered by date using the start_date and end_date query parameters.
608
+ # @param platform_pk
609
+ # @param [Hash] opts the optional parameters
610
+ # @return [Array<(Array<IncomeSerializerFixedSource>, Fixnum, Hash)>] Array<IncomeSerializerFixedSource> data, response status code and response headers
611
+ def income_platform_list_with_http_info(platform_pk, opts = {})
612
+ if @api_client.config.debugging
613
+ @api_client.config.logger.debug "Calling API: PlatformsApi.income_platform_list ..."
614
+ end
615
+ # verify the required parameter 'platform_pk' is set
616
+ fail ArgumentError, "Missing the required parameter 'platform_pk' when calling PlatformsApi.income_platform_list" if platform_pk.nil?
617
+ # resource path
618
+ local_var_path = "/platforms/{platform_pk}/income/".sub('{format}','json').sub('{' + 'platform_pk' + '}', platform_pk.to_s)
619
+
620
+ # query parameters
621
+ query_params = {}
622
+
623
+ # header parameters
624
+ header_params = {}
625
+
626
+ # HTTP header 'Accept' (if needed)
627
+ local_header_accept = []
628
+ local_header_accept_result = @api_client.select_header_accept(local_header_accept) and header_params['Accept'] = local_header_accept_result
629
+
630
+ # HTTP header 'Content-Type'
631
+ local_header_content_type = []
632
+ header_params['Content-Type'] = @api_client.select_header_content_type(local_header_content_type)
633
+
634
+ # form parameters
635
+ form_params = {}
636
+
637
+ # http body (model)
638
+ post_body = nil
639
+ auth_names = []
640
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
641
+ :header_params => header_params,
642
+ :query_params => query_params,
643
+ :form_params => form_params,
644
+ :body => post_body,
645
+ :auth_names => auth_names,
646
+ :return_type => 'Array<IncomeSerializerFixedSource>')
647
+ if @api_client.config.debugging
648
+ @api_client.config.logger.debug "API called: PlatformsApi#income_platform_list\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
649
+ end
650
+ return data, status_code, headers
651
+ end
652
+
653
+ # The set of users on a specific Platform
654
+ # The set of users on a specific Platform.<br/>Any users created through this ViewSet will have a profile created with the Platform set to the resource specified in the URL, e.g. POST /platforms/3/contractors/ will create a user with User.Profile.platform = '/platforms/3/'.
655
+ # @param platform_pk
656
+ # @param email
657
+ # @param [Hash] opts the optional parameters
658
+ # @option opts [String] :first_name First name, if the user is an individual. Leave blank if this user is a company.
659
+ # @option opts [String] :last_name Last name, if the user is an individual. Leave blank if this user is a company.
660
+ # @option opts [String] :business_name Business name. Only use this field if this user is a business entity.
661
+ # @option opts [String] :contractor_type (default to INDIVIDUAL)
662
+ # @option opts [String] :personal_information
663
+ # @option opts [String] :default_account Default account to use for payment of unpaid income.
664
+ # @return [ContractorSerializer]
665
+ def platform_contractor_create(platform_pk, email, opts = {})
666
+ data, _status_code, _headers = platform_contractor_create_with_http_info(platform_pk, email, opts)
667
+ return data
668
+ end
669
+
670
+ # The set of users on a specific Platform
671
+ # The set of users on a specific Platform.&lt;br/&gt;Any users created through this ViewSet will have a profile created with the Platform set to the resource specified in the URL, e.g. POST /platforms/3/contractors/ will create a user with User.Profile.platform &#x3D; &#39;/platforms/3/&#39;.
672
+ # @param platform_pk
673
+ # @param email
674
+ # @param [Hash] opts the optional parameters
675
+ # @option opts [String] :first_name First name, if the user is an individual. Leave blank if this user is a company.
676
+ # @option opts [String] :last_name Last name, if the user is an individual. Leave blank if this user is a company.
677
+ # @option opts [String] :business_name Business name. Only use this field if this user is a business entity.
678
+ # @option opts [String] :contractor_type
679
+ # @option opts [String] :personal_information
680
+ # @option opts [String] :default_account Default account to use for payment of unpaid income.
681
+ # @return [Array<(ContractorSerializer, Fixnum, Hash)>] ContractorSerializer data, response status code and response headers
682
+ def platform_contractor_create_with_http_info(platform_pk, email, opts = {})
683
+ if @api_client.config.debugging
684
+ @api_client.config.logger.debug "Calling API: PlatformsApi.platform_contractor_create ..."
685
+ end
686
+ # verify the required parameter 'platform_pk' is set
687
+ fail ArgumentError, "Missing the required parameter 'platform_pk' when calling PlatformsApi.platform_contractor_create" if platform_pk.nil?
688
+ # verify the required parameter 'email' is set
689
+ fail ArgumentError, "Missing the required parameter 'email' when calling PlatformsApi.platform_contractor_create" if email.nil?
690
+ if opts[:'contractor_type'] && !['INDIVIDUAL', 'BUSINESS'].include?(opts[:'contractor_type'])
691
+ fail ArgumentError, 'invalid value for "contractor_type", must be one of INDIVIDUAL, BUSINESS'
692
+ end
693
+ # resource path
694
+ local_var_path = "/platforms/{platform_pk}/contractors/".sub('{format}','json').sub('{' + 'platform_pk' + '}', platform_pk.to_s)
695
+
696
+ # query parameters
697
+ query_params = {}
698
+
699
+ # header parameters
700
+ header_params = {}
701
+
702
+ # HTTP header 'Accept' (if needed)
703
+ local_header_accept = []
704
+ local_header_accept_result = @api_client.select_header_accept(local_header_accept) and header_params['Accept'] = local_header_accept_result
705
+
706
+ # HTTP header 'Content-Type'
707
+ local_header_content_type = []
708
+ header_params['Content-Type'] = @api_client.select_header_content_type(local_header_content_type)
709
+
710
+ # form parameters
711
+ form_params = {}
712
+ form_params["email"] = email
713
+ form_params["first_name"] = opts[:'first_name'] if !opts[:'first_name'].nil?
714
+ form_params["last_name"] = opts[:'last_name'] if !opts[:'last_name'].nil?
715
+ form_params["business_name"] = opts[:'business_name'] if !opts[:'business_name'].nil?
716
+ form_params["contractor_type"] = opts[:'contractor_type'] if !opts[:'contractor_type'].nil?
717
+ form_params["personal_information"] = opts[:'personal_information'] if !opts[:'personal_information'].nil?
718
+ form_params["default_account"] = opts[:'default_account'] if !opts[:'default_account'].nil?
719
+
720
+ # http body (model)
721
+ post_body = nil
722
+ auth_names = []
723
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path,
724
+ :header_params => header_params,
725
+ :query_params => query_params,
726
+ :form_params => form_params,
727
+ :body => post_body,
728
+ :auth_names => auth_names,
729
+ :return_type => 'ContractorSerializer')
730
+ if @api_client.config.debugging
731
+ @api_client.config.logger.debug "API called: PlatformsApi#platform_contractor_create\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
732
+ end
733
+ return data, status_code, headers
734
+ end
735
+
736
+ # The set of users on a specific Platform
737
+ # The set of users on a specific Platform.<br/>Any users created through this ViewSet will have a profile created with the Platform set to the resource specified in the URL, e.g. POST /platforms/3/contractors/ will create a user with User.Profile.platform = '/platforms/3/'.
738
+ # @param platform_pk
739
+ # @param [Hash] opts the optional parameters
740
+ # @return [Array<ContractorSerializer>]
741
+ def platform_contractor_list(platform_pk, opts = {})
742
+ data, _status_code, _headers = platform_contractor_list_with_http_info(platform_pk, opts)
743
+ return data
744
+ end
745
+
746
+ # The set of users on a specific Platform
747
+ # The set of users on a specific Platform.&lt;br/&gt;Any users created through this ViewSet will have a profile created with the Platform set to the resource specified in the URL, e.g. POST /platforms/3/contractors/ will create a user with User.Profile.platform &#x3D; &#39;/platforms/3/&#39;.
748
+ # @param platform_pk
749
+ # @param [Hash] opts the optional parameters
750
+ # @return [Array<(Array<ContractorSerializer>, Fixnum, Hash)>] Array<ContractorSerializer> data, response status code and response headers
751
+ def platform_contractor_list_with_http_info(platform_pk, opts = {})
752
+ if @api_client.config.debugging
753
+ @api_client.config.logger.debug "Calling API: PlatformsApi.platform_contractor_list ..."
754
+ end
755
+ # verify the required parameter 'platform_pk' is set
756
+ fail ArgumentError, "Missing the required parameter 'platform_pk' when calling PlatformsApi.platform_contractor_list" if platform_pk.nil?
757
+ # resource path
758
+ local_var_path = "/platforms/{platform_pk}/contractors/".sub('{format}','json').sub('{' + 'platform_pk' + '}', platform_pk.to_s)
759
+
760
+ # query parameters
761
+ query_params = {}
762
+
763
+ # header parameters
764
+ header_params = {}
765
+
766
+ # HTTP header 'Accept' (if needed)
767
+ local_header_accept = []
768
+ local_header_accept_result = @api_client.select_header_accept(local_header_accept) and header_params['Accept'] = local_header_accept_result
769
+
770
+ # HTTP header 'Content-Type'
771
+ local_header_content_type = []
772
+ header_params['Content-Type'] = @api_client.select_header_content_type(local_header_content_type)
773
+
774
+ # form parameters
775
+ form_params = {}
776
+
777
+ # http body (model)
778
+ post_body = nil
779
+ auth_names = []
780
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
781
+ :header_params => header_params,
782
+ :query_params => query_params,
783
+ :form_params => form_params,
784
+ :body => post_body,
785
+ :auth_names => auth_names,
786
+ :return_type => 'Array<ContractorSerializer>')
787
+ if @api_client.config.debugging
788
+ @api_client.config.logger.debug "API called: PlatformsApi#platform_contractor_list\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
789
+ end
790
+ return data, status_code, headers
791
+ end
792
+
793
+ # The set of users on a specific Platform
794
+ # The set of users on a specific Platform.<br/>Any users created through this ViewSet will have a profile created with the Platform set to the resource specified in the URL, e.g. POST /platforms/3/contractors/ will create a user with User.Profile.platform = '/platforms/3/'.
795
+ # @param platform_pk
796
+ # @param pk
797
+ # @param [Hash] opts the optional parameters
798
+ # @option opts [String] :email
799
+ # @option opts [String] :first_name First name, if the user is an individual. Leave blank if this user is a company.
800
+ # @option opts [String] :last_name Last name, if the user is an individual. Leave blank if this user is a company.
801
+ # @option opts [String] :business_name Business name. Only use this field if this user is a business entity.
802
+ # @option opts [String] :contractor_type (default to INDIVIDUAL)
803
+ # @option opts [String] :personal_information
804
+ # @option opts [String] :default_account Default account to use for payment of unpaid income.
805
+ # @return [ContractorSerializer]
806
+ def platform_contractor_partial_update(platform_pk, pk, opts = {})
807
+ data, _status_code, _headers = platform_contractor_partial_update_with_http_info(platform_pk, pk, opts)
808
+ return data
809
+ end
810
+
811
+ # The set of users on a specific Platform
812
+ # The set of users on a specific Platform.&lt;br/&gt;Any users created through this ViewSet will have a profile created with the Platform set to the resource specified in the URL, e.g. POST /platforms/3/contractors/ will create a user with User.Profile.platform &#x3D; &#39;/platforms/3/&#39;.
813
+ # @param platform_pk
814
+ # @param pk
815
+ # @param [Hash] opts the optional parameters
816
+ # @option opts [String] :email
817
+ # @option opts [String] :first_name First name, if the user is an individual. Leave blank if this user is a company.
818
+ # @option opts [String] :last_name Last name, if the user is an individual. Leave blank if this user is a company.
819
+ # @option opts [String] :business_name Business name. Only use this field if this user is a business entity.
820
+ # @option opts [String] :contractor_type
821
+ # @option opts [String] :personal_information
822
+ # @option opts [String] :default_account Default account to use for payment of unpaid income.
823
+ # @return [Array<(ContractorSerializer, Fixnum, Hash)>] ContractorSerializer data, response status code and response headers
824
+ def platform_contractor_partial_update_with_http_info(platform_pk, pk, opts = {})
825
+ if @api_client.config.debugging
826
+ @api_client.config.logger.debug "Calling API: PlatformsApi.platform_contractor_partial_update ..."
827
+ end
828
+ # verify the required parameter 'platform_pk' is set
829
+ fail ArgumentError, "Missing the required parameter 'platform_pk' when calling PlatformsApi.platform_contractor_partial_update" if platform_pk.nil?
830
+ # verify the required parameter 'pk' is set
831
+ fail ArgumentError, "Missing the required parameter 'pk' when calling PlatformsApi.platform_contractor_partial_update" if pk.nil?
832
+ if opts[:'contractor_type'] && !['INDIVIDUAL', 'BUSINESS'].include?(opts[:'contractor_type'])
833
+ fail ArgumentError, 'invalid value for "contractor_type", must be one of INDIVIDUAL, BUSINESS'
834
+ end
835
+ # resource path
836
+ local_var_path = "/platforms/{platform_pk}/contractors/{pk}/".sub('{format}','json').sub('{' + 'platform_pk' + '}', platform_pk.to_s).sub('{' + 'pk' + '}', pk.to_s)
837
+
838
+ # query parameters
839
+ query_params = {}
840
+
841
+ # header parameters
842
+ header_params = {}
843
+
844
+ # HTTP header 'Accept' (if needed)
845
+ local_header_accept = []
846
+ local_header_accept_result = @api_client.select_header_accept(local_header_accept) and header_params['Accept'] = local_header_accept_result
847
+
848
+ # HTTP header 'Content-Type'
849
+ local_header_content_type = []
850
+ header_params['Content-Type'] = @api_client.select_header_content_type(local_header_content_type)
851
+
852
+ # form parameters
853
+ form_params = {}
854
+ form_params["email"] = opts[:'email'] if !opts[:'email'].nil?
855
+ form_params["first_name"] = opts[:'first_name'] if !opts[:'first_name'].nil?
856
+ form_params["last_name"] = opts[:'last_name'] if !opts[:'last_name'].nil?
857
+ form_params["business_name"] = opts[:'business_name'] if !opts[:'business_name'].nil?
858
+ form_params["contractor_type"] = opts[:'contractor_type'] if !opts[:'contractor_type'].nil?
859
+ form_params["personal_information"] = opts[:'personal_information'] if !opts[:'personal_information'].nil?
860
+ form_params["default_account"] = opts[:'default_account'] if !opts[:'default_account'].nil?
861
+
862
+ # http body (model)
863
+ post_body = nil
864
+ auth_names = []
865
+ data, status_code, headers = @api_client.call_api(:PATCH, local_var_path,
866
+ :header_params => header_params,
867
+ :query_params => query_params,
868
+ :form_params => form_params,
869
+ :body => post_body,
870
+ :auth_names => auth_names,
871
+ :return_type => 'ContractorSerializer')
872
+ if @api_client.config.debugging
873
+ @api_client.config.logger.debug "API called: PlatformsApi#platform_contractor_partial_update\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
874
+ end
875
+ return data, status_code, headers
876
+ end
877
+
878
+ # The set of users on a specific Platform
879
+ # The set of users on a specific Platform.<br/>Any users created through this ViewSet will have a profile created with the Platform set to the resource specified in the URL, e.g. POST /platforms/3/contractors/ will create a user with User.Profile.platform = '/platforms/3/'.
880
+ # @param platform_pk
881
+ # @param pk
882
+ # @param [Hash] opts the optional parameters
883
+ # @return [ContractorSerializer]
884
+ def platform_contractor_retrieve(platform_pk, pk, opts = {})
885
+ data, _status_code, _headers = platform_contractor_retrieve_with_http_info(platform_pk, pk, opts)
886
+ return data
887
+ end
888
+
889
+ # The set of users on a specific Platform
890
+ # The set of users on a specific Platform.&lt;br/&gt;Any users created through this ViewSet will have a profile created with the Platform set to the resource specified in the URL, e.g. POST /platforms/3/contractors/ will create a user with User.Profile.platform &#x3D; &#39;/platforms/3/&#39;.
891
+ # @param platform_pk
892
+ # @param pk
893
+ # @param [Hash] opts the optional parameters
894
+ # @return [Array<(ContractorSerializer, Fixnum, Hash)>] ContractorSerializer data, response status code and response headers
895
+ def platform_contractor_retrieve_with_http_info(platform_pk, pk, opts = {})
896
+ if @api_client.config.debugging
897
+ @api_client.config.logger.debug "Calling API: PlatformsApi.platform_contractor_retrieve ..."
898
+ end
899
+ # verify the required parameter 'platform_pk' is set
900
+ fail ArgumentError, "Missing the required parameter 'platform_pk' when calling PlatformsApi.platform_contractor_retrieve" if platform_pk.nil?
901
+ # verify the required parameter 'pk' is set
902
+ fail ArgumentError, "Missing the required parameter 'pk' when calling PlatformsApi.platform_contractor_retrieve" if pk.nil?
903
+ # resource path
904
+ local_var_path = "/platforms/{platform_pk}/contractors/{pk}/".sub('{format}','json').sub('{' + 'platform_pk' + '}', platform_pk.to_s).sub('{' + 'pk' + '}', pk.to_s)
905
+
906
+ # query parameters
907
+ query_params = {}
908
+
909
+ # header parameters
910
+ header_params = {}
911
+
912
+ # HTTP header 'Accept' (if needed)
913
+ local_header_accept = []
914
+ local_header_accept_result = @api_client.select_header_accept(local_header_accept) and header_params['Accept'] = local_header_accept_result
915
+
916
+ # HTTP header 'Content-Type'
917
+ local_header_content_type = []
918
+ header_params['Content-Type'] = @api_client.select_header_content_type(local_header_content_type)
919
+
920
+ # form parameters
921
+ form_params = {}
922
+
923
+ # http body (model)
924
+ post_body = nil
925
+ auth_names = []
926
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
927
+ :header_params => header_params,
928
+ :query_params => query_params,
929
+ :form_params => form_params,
930
+ :body => post_body,
931
+ :auth_names => auth_names,
932
+ :return_type => 'ContractorSerializer')
933
+ if @api_client.config.debugging
934
+ @api_client.config.logger.debug "API called: PlatformsApi#platform_contractor_retrieve\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
935
+ end
936
+ return data, status_code, headers
937
+ end
938
+
939
+ # The set of users on a specific Platform
940
+ # The set of users on a specific Platform.<br/>Any users created through this ViewSet will have a profile created with the Platform set to the resource specified in the URL, e.g. POST /platforms/3/contractors/ will create a user with User.Profile.platform = '/platforms/3/'.
941
+ # @param platform_pk
942
+ # @param pk
943
+ # @param email
944
+ # @param [Hash] opts the optional parameters
945
+ # @option opts [String] :first_name First name, if the user is an individual. Leave blank if this user is a company.
946
+ # @option opts [String] :last_name Last name, if the user is an individual. Leave blank if this user is a company.
947
+ # @option opts [String] :business_name Business name. Only use this field if this user is a business entity.
948
+ # @option opts [String] :contractor_type (default to INDIVIDUAL)
949
+ # @option opts [String] :personal_information
950
+ # @option opts [String] :default_account Default account to use for payment of unpaid income.
951
+ # @return [ContractorSerializer]
952
+ def platform_contractor_update(platform_pk, pk, email, opts = {})
953
+ data, _status_code, _headers = platform_contractor_update_with_http_info(platform_pk, pk, email, opts)
954
+ return data
955
+ end
956
+
957
+ # The set of users on a specific Platform
958
+ # The set of users on a specific Platform.&lt;br/&gt;Any users created through this ViewSet will have a profile created with the Platform set to the resource specified in the URL, e.g. POST /platforms/3/contractors/ will create a user with User.Profile.platform &#x3D; &#39;/platforms/3/&#39;.
959
+ # @param platform_pk
960
+ # @param pk
961
+ # @param email
962
+ # @param [Hash] opts the optional parameters
963
+ # @option opts [String] :first_name First name, if the user is an individual. Leave blank if this user is a company.
964
+ # @option opts [String] :last_name Last name, if the user is an individual. Leave blank if this user is a company.
965
+ # @option opts [String] :business_name Business name. Only use this field if this user is a business entity.
966
+ # @option opts [String] :contractor_type
967
+ # @option opts [String] :personal_information
968
+ # @option opts [String] :default_account Default account to use for payment of unpaid income.
969
+ # @return [Array<(ContractorSerializer, Fixnum, Hash)>] ContractorSerializer data, response status code and response headers
970
+ def platform_contractor_update_with_http_info(platform_pk, pk, email, opts = {})
971
+ if @api_client.config.debugging
972
+ @api_client.config.logger.debug "Calling API: PlatformsApi.platform_contractor_update ..."
973
+ end
974
+ # verify the required parameter 'platform_pk' is set
975
+ fail ArgumentError, "Missing the required parameter 'platform_pk' when calling PlatformsApi.platform_contractor_update" if platform_pk.nil?
976
+ # verify the required parameter 'pk' is set
977
+ fail ArgumentError, "Missing the required parameter 'pk' when calling PlatformsApi.platform_contractor_update" if pk.nil?
978
+ # verify the required parameter 'email' is set
979
+ fail ArgumentError, "Missing the required parameter 'email' when calling PlatformsApi.platform_contractor_update" if email.nil?
980
+ if opts[:'contractor_type'] && !['INDIVIDUAL', 'BUSINESS'].include?(opts[:'contractor_type'])
981
+ fail ArgumentError, 'invalid value for "contractor_type", must be one of INDIVIDUAL, BUSINESS'
982
+ end
983
+ # resource path
984
+ local_var_path = "/platforms/{platform_pk}/contractors/{pk}/".sub('{format}','json').sub('{' + 'platform_pk' + '}', platform_pk.to_s).sub('{' + 'pk' + '}', pk.to_s)
985
+
986
+ # query parameters
987
+ query_params = {}
988
+
989
+ # header parameters
990
+ header_params = {}
991
+
992
+ # HTTP header 'Accept' (if needed)
993
+ local_header_accept = []
994
+ local_header_accept_result = @api_client.select_header_accept(local_header_accept) and header_params['Accept'] = local_header_accept_result
995
+
996
+ # HTTP header 'Content-Type'
997
+ local_header_content_type = []
998
+ header_params['Content-Type'] = @api_client.select_header_content_type(local_header_content_type)
999
+
1000
+ # form parameters
1001
+ form_params = {}
1002
+ form_params["email"] = email
1003
+ form_params["first_name"] = opts[:'first_name'] if !opts[:'first_name'].nil?
1004
+ form_params["last_name"] = opts[:'last_name'] if !opts[:'last_name'].nil?
1005
+ form_params["business_name"] = opts[:'business_name'] if !opts[:'business_name'].nil?
1006
+ form_params["contractor_type"] = opts[:'contractor_type'] if !opts[:'contractor_type'].nil?
1007
+ form_params["personal_information"] = opts[:'personal_information'] if !opts[:'personal_information'].nil?
1008
+ form_params["default_account"] = opts[:'default_account'] if !opts[:'default_account'].nil?
1009
+
1010
+ # http body (model)
1011
+ post_body = nil
1012
+ auth_names = []
1013
+ data, status_code, headers = @api_client.call_api(:PUT, local_var_path,
1014
+ :header_params => header_params,
1015
+ :query_params => query_params,
1016
+ :form_params => form_params,
1017
+ :body => post_body,
1018
+ :auth_names => auth_names,
1019
+ :return_type => 'ContractorSerializer')
1020
+ if @api_client.config.debugging
1021
+ @api_client.config.logger.debug "API called: PlatformsApi#platform_contractor_update\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1022
+ end
1023
+ return data, status_code, headers
1024
+ end
1025
+
1026
+ # Viewset for uploading CSV files containing Income config
1027
+ # Viewset for uploading CSV files containing Income config.<br/>The POST must use Content-Type: multipart/form-data<br/>The field name for the form-data must be \"income-data\".<br/>The first line specifies the field names, and each subsequent line will specify an Income object.
1028
+ # @param platform_pk
1029
+ # @param [Hash] opts the optional parameters
1030
+ # @return [Object]
1031
+ def platform_csv_upload_income_file_post(platform_pk, opts = {})
1032
+ data, _status_code, _headers = platform_csv_upload_income_file_post_with_http_info(platform_pk, opts)
1033
+ return data
1034
+ end
1035
+
1036
+ # Viewset for uploading CSV files containing Income config
1037
+ # Viewset for uploading CSV files containing Income config.&lt;br/&gt;The POST must use Content-Type: multipart/form-data&lt;br/&gt;The field name for the form-data must be \&quot;income-data\&quot;.&lt;br/&gt;The first line specifies the field names, and each subsequent line will specify an Income object.
1038
+ # @param platform_pk
1039
+ # @param [Hash] opts the optional parameters
1040
+ # @return [Array<(Object, Fixnum, Hash)>] Object data, response status code and response headers
1041
+ def platform_csv_upload_income_file_post_with_http_info(platform_pk, opts = {})
1042
+ if @api_client.config.debugging
1043
+ @api_client.config.logger.debug "Calling API: PlatformsApi.platform_csv_upload_income_file_post ..."
1044
+ end
1045
+ # verify the required parameter 'platform_pk' is set
1046
+ fail ArgumentError, "Missing the required parameter 'platform_pk' when calling PlatformsApi.platform_csv_upload_income_file_post" if platform_pk.nil?
1047
+ # resource path
1048
+ local_var_path = "/platforms/{platform_pk}/csv-upload/income".sub('{format}','json').sub('{' + 'platform_pk' + '}', platform_pk.to_s)
1049
+
1050
+ # query parameters
1051
+ query_params = {}
1052
+
1053
+ # header parameters
1054
+ header_params = {}
1055
+
1056
+ # HTTP header 'Accept' (if needed)
1057
+ local_header_accept = []
1058
+ local_header_accept_result = @api_client.select_header_accept(local_header_accept) and header_params['Accept'] = local_header_accept_result
1059
+
1060
+ # HTTP header 'Content-Type'
1061
+ local_header_content_type = []
1062
+ header_params['Content-Type'] = @api_client.select_header_content_type(local_header_content_type)
1063
+
1064
+ # form parameters
1065
+ form_params = {}
1066
+
1067
+ # http body (model)
1068
+ post_body = nil
1069
+ auth_names = []
1070
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path,
1071
+ :header_params => header_params,
1072
+ :query_params => query_params,
1073
+ :form_params => form_params,
1074
+ :body => post_body,
1075
+ :auth_names => auth_names,
1076
+ :return_type => 'Object')
1077
+ if @api_client.config.debugging
1078
+ @api_client.config.logger.debug "API called: PlatformsApi#platform_csv_upload_income_file_post\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1079
+ end
1080
+ return data, status_code, headers
1081
+ end
1082
+
1083
+ # Viewset for uploading CSV files containing User config
1084
+ # Viewset for uploading CSV files containing User config.<br/>The POST must use Content-Type: multipart/form-data<br/>The field name for the form-data must be \"user-data\".<br/>The first line specifies the field names, and each subsequent line will specify a User object.<br/>Note that the fields in User.PersonalInformation can also be specified,<br/>e.g. first_name,last_name,email,tax_id_number
1085
+ # @param platform_pk
1086
+ # @param [Hash] opts the optional parameters
1087
+ # @return [Object]
1088
+ def platform_csv_upload_user_file_post(platform_pk, opts = {})
1089
+ data, _status_code, _headers = platform_csv_upload_user_file_post_with_http_info(platform_pk, opts)
1090
+ return data
1091
+ end
1092
+
1093
+ # Viewset for uploading CSV files containing User config
1094
+ # Viewset for uploading CSV files containing User config.&lt;br/&gt;The POST must use Content-Type: multipart/form-data&lt;br/&gt;The field name for the form-data must be \&quot;user-data\&quot;.&lt;br/&gt;The first line specifies the field names, and each subsequent line will specify a User object.&lt;br/&gt;Note that the fields in User.PersonalInformation can also be specified,&lt;br/&gt;e.g. first_name,last_name,email,tax_id_number
1095
+ # @param platform_pk
1096
+ # @param [Hash] opts the optional parameters
1097
+ # @return [Array<(Object, Fixnum, Hash)>] Object data, response status code and response headers
1098
+ def platform_csv_upload_user_file_post_with_http_info(platform_pk, opts = {})
1099
+ if @api_client.config.debugging
1100
+ @api_client.config.logger.debug "Calling API: PlatformsApi.platform_csv_upload_user_file_post ..."
1101
+ end
1102
+ # verify the required parameter 'platform_pk' is set
1103
+ fail ArgumentError, "Missing the required parameter 'platform_pk' when calling PlatformsApi.platform_csv_upload_user_file_post" if platform_pk.nil?
1104
+ # resource path
1105
+ local_var_path = "/platforms/{platform_pk}/csv-upload/user".sub('{format}','json').sub('{' + 'platform_pk' + '}', platform_pk.to_s)
1106
+
1107
+ # query parameters
1108
+ query_params = {}
1109
+
1110
+ # header parameters
1111
+ header_params = {}
1112
+
1113
+ # HTTP header 'Accept' (if needed)
1114
+ local_header_accept = []
1115
+ local_header_accept_result = @api_client.select_header_accept(local_header_accept) and header_params['Accept'] = local_header_accept_result
1116
+
1117
+ # HTTP header 'Content-Type'
1118
+ local_header_content_type = []
1119
+ header_params['Content-Type'] = @api_client.select_header_content_type(local_header_content_type)
1120
+
1121
+ # form parameters
1122
+ form_params = {}
1123
+
1124
+ # http body (model)
1125
+ post_body = nil
1126
+ auth_names = []
1127
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path,
1128
+ :header_params => header_params,
1129
+ :query_params => query_params,
1130
+ :form_params => form_params,
1131
+ :body => post_body,
1132
+ :auth_names => auth_names,
1133
+ :return_type => 'Object')
1134
+ if @api_client.config.debugging
1135
+ @api_client.config.logger.debug "API called: PlatformsApi#platform_csv_upload_user_file_post\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1136
+ end
1137
+ return data, status_code, headers
1138
+ end
1139
+
1140
+ #
1141
+ #
1142
+ # @param platform_pk
1143
+ # @param [Hash] opts the optional parameters
1144
+ # @return [Array<PlatformIncomeRequestSerializer>]
1145
+ def platform_income_request_list(platform_pk, opts = {})
1146
+ data, _status_code, _headers = platform_income_request_list_with_http_info(platform_pk, opts)
1147
+ return data
1148
+ end
1149
+
1150
+ #
1151
+ #
1152
+ # @param platform_pk
1153
+ # @param [Hash] opts the optional parameters
1154
+ # @return [Array<(Array<PlatformIncomeRequestSerializer>, Fixnum, Hash)>] Array<PlatformIncomeRequestSerializer> data, response status code and response headers
1155
+ def platform_income_request_list_with_http_info(platform_pk, opts = {})
1156
+ if @api_client.config.debugging
1157
+ @api_client.config.logger.debug "Calling API: PlatformsApi.platform_income_request_list ..."
1158
+ end
1159
+ # verify the required parameter 'platform_pk' is set
1160
+ fail ArgumentError, "Missing the required parameter 'platform_pk' when calling PlatformsApi.platform_income_request_list" if platform_pk.nil?
1161
+ # resource path
1162
+ local_var_path = "/platforms/{platform_pk}/income_requests/".sub('{format}','json').sub('{' + 'platform_pk' + '}', platform_pk.to_s)
1163
+
1164
+ # query parameters
1165
+ query_params = {}
1166
+
1167
+ # header parameters
1168
+ header_params = {}
1169
+
1170
+ # HTTP header 'Accept' (if needed)
1171
+ local_header_accept = []
1172
+ local_header_accept_result = @api_client.select_header_accept(local_header_accept) and header_params['Accept'] = local_header_accept_result
1173
+
1174
+ # HTTP header 'Content-Type'
1175
+ local_header_content_type = []
1176
+ header_params['Content-Type'] = @api_client.select_header_content_type(local_header_content_type)
1177
+
1178
+ # form parameters
1179
+ form_params = {}
1180
+
1181
+ # http body (model)
1182
+ post_body = nil
1183
+ auth_names = []
1184
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
1185
+ :header_params => header_params,
1186
+ :query_params => query_params,
1187
+ :form_params => form_params,
1188
+ :body => post_body,
1189
+ :auth_names => auth_names,
1190
+ :return_type => 'Array<PlatformIncomeRequestSerializer>')
1191
+ if @api_client.config.debugging
1192
+ @api_client.config.logger.debug "API called: PlatformsApi#platform_income_request_list\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1193
+ end
1194
+ return data, status_code, headers
1195
+ end
1196
+
1197
+ #
1198
+ #
1199
+ # @param platform_pk
1200
+ # @param pk
1201
+ # @param [Hash] opts the optional parameters
1202
+ # @return [PlatformIncomeRequestSerializer]
1203
+ def platform_income_request_retrieve(platform_pk, pk, opts = {})
1204
+ data, _status_code, _headers = platform_income_request_retrieve_with_http_info(platform_pk, pk, opts)
1205
+ return data
1206
+ end
1207
+
1208
+ #
1209
+ #
1210
+ # @param platform_pk
1211
+ # @param pk
1212
+ # @param [Hash] opts the optional parameters
1213
+ # @return [Array<(PlatformIncomeRequestSerializer, Fixnum, Hash)>] PlatformIncomeRequestSerializer data, response status code and response headers
1214
+ def platform_income_request_retrieve_with_http_info(platform_pk, pk, opts = {})
1215
+ if @api_client.config.debugging
1216
+ @api_client.config.logger.debug "Calling API: PlatformsApi.platform_income_request_retrieve ..."
1217
+ end
1218
+ # verify the required parameter 'platform_pk' is set
1219
+ fail ArgumentError, "Missing the required parameter 'platform_pk' when calling PlatformsApi.platform_income_request_retrieve" if platform_pk.nil?
1220
+ # verify the required parameter 'pk' is set
1221
+ fail ArgumentError, "Missing the required parameter 'pk' when calling PlatformsApi.platform_income_request_retrieve" if pk.nil?
1222
+ # resource path
1223
+ local_var_path = "/platforms/{platform_pk}/income_requests/{pk}/".sub('{format}','json').sub('{' + 'platform_pk' + '}', platform_pk.to_s).sub('{' + 'pk' + '}', pk.to_s)
1224
+
1225
+ # query parameters
1226
+ query_params = {}
1227
+
1228
+ # header parameters
1229
+ header_params = {}
1230
+
1231
+ # HTTP header 'Accept' (if needed)
1232
+ local_header_accept = []
1233
+ local_header_accept_result = @api_client.select_header_accept(local_header_accept) and header_params['Accept'] = local_header_accept_result
1234
+
1235
+ # HTTP header 'Content-Type'
1236
+ local_header_content_type = []
1237
+ header_params['Content-Type'] = @api_client.select_header_content_type(local_header_content_type)
1238
+
1239
+ # form parameters
1240
+ form_params = {}
1241
+
1242
+ # http body (model)
1243
+ post_body = nil
1244
+ auth_names = []
1245
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
1246
+ :header_params => header_params,
1247
+ :query_params => query_params,
1248
+ :form_params => form_params,
1249
+ :body => post_body,
1250
+ :auth_names => auth_names,
1251
+ :return_type => 'PlatformIncomeRequestSerializer')
1252
+ if @api_client.config.debugging
1253
+ @api_client.config.logger.debug "API called: PlatformsApi#platform_income_request_retrieve\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1254
+ end
1255
+ return data, status_code, headers
1256
+ end
1257
+
1258
+ #
1259
+ #
1260
+ # @param platform_pk
1261
+ # @param income
1262
+ # @param [Hash] opts the optional parameters
1263
+ # @option opts [String] :external_id Optional unique ID to correlate this Invoice to a record in another system. If specified, this will prevent duplicate Invoices being created with the same external_id. This field is unique per Platform. If this field is omitted, no uniqueness check is performed.
1264
+ # @return [InvoiceSerializerFixedSourceCreate]
1265
+ def platform_invoice_create_create(platform_pk, income, opts = {})
1266
+ data, _status_code, _headers = platform_invoice_create_create_with_http_info(platform_pk, income, opts)
1267
+ return data
1268
+ end
1269
+
1270
+ #
1271
+ #
1272
+ # @param platform_pk
1273
+ # @param income
1274
+ # @param [Hash] opts the optional parameters
1275
+ # @option opts [String] :external_id Optional unique ID to correlate this Invoice to a record in another system. If specified, this will prevent duplicate Invoices being created with the same external_id. This field is unique per Platform. If this field is omitted, no uniqueness check is performed.
1276
+ # @return [Array<(InvoiceSerializerFixedSourceCreate, Fixnum, Hash)>] InvoiceSerializerFixedSourceCreate data, response status code and response headers
1277
+ def platform_invoice_create_create_with_http_info(platform_pk, income, opts = {})
1278
+ if @api_client.config.debugging
1279
+ @api_client.config.logger.debug "Calling API: PlatformsApi.platform_invoice_create_create ..."
1280
+ end
1281
+ # verify the required parameter 'platform_pk' is set
1282
+ fail ArgumentError, "Missing the required parameter 'platform_pk' when calling PlatformsApi.platform_invoice_create_create" if platform_pk.nil?
1283
+ # verify the required parameter 'income' is set
1284
+ fail ArgumentError, "Missing the required parameter 'income' when calling PlatformsApi.platform_invoice_create_create" if income.nil?
1285
+ # resource path
1286
+ local_var_path = "/platforms/{platform_pk}/create_invoice/".sub('{format}','json').sub('{' + 'platform_pk' + '}', platform_pk.to_s)
1287
+
1288
+ # query parameters
1289
+ query_params = {}
1290
+
1291
+ # header parameters
1292
+ header_params = {}
1293
+
1294
+ # HTTP header 'Accept' (if needed)
1295
+ local_header_accept = []
1296
+ local_header_accept_result = @api_client.select_header_accept(local_header_accept) and header_params['Accept'] = local_header_accept_result
1297
+
1298
+ # HTTP header 'Content-Type'
1299
+ local_header_content_type = []
1300
+ header_params['Content-Type'] = @api_client.select_header_content_type(local_header_content_type)
1301
+
1302
+ # form parameters
1303
+ form_params = {}
1304
+ form_params["income"] = income
1305
+ form_params["external_id"] = opts[:'external_id'] if !opts[:'external_id'].nil?
1306
+
1307
+ # http body (model)
1308
+ post_body = nil
1309
+ auth_names = []
1310
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path,
1311
+ :header_params => header_params,
1312
+ :query_params => query_params,
1313
+ :form_params => form_params,
1314
+ :body => post_body,
1315
+ :auth_names => auth_names,
1316
+ :return_type => 'InvoiceSerializerFixedSourceCreate')
1317
+ if @api_client.config.debugging
1318
+ @api_client.config.logger.debug "API called: PlatformsApi#platform_invoice_create_create\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1319
+ end
1320
+ return data, status_code, headers
1321
+ end
1322
+
1323
+ #
1324
+ #
1325
+ # @param platform_pk
1326
+ # @param [Hash] opts the optional parameters
1327
+ # @return [Array<InvoiceSerializer>]
1328
+ def platform_invoice_list(platform_pk, opts = {})
1329
+ data, _status_code, _headers = platform_invoice_list_with_http_info(platform_pk, opts)
1330
+ return data
1331
+ end
1332
+
1333
+ #
1334
+ #
1335
+ # @param platform_pk
1336
+ # @param [Hash] opts the optional parameters
1337
+ # @return [Array<(Array<InvoiceSerializer>, Fixnum, Hash)>] Array<InvoiceSerializer> data, response status code and response headers
1338
+ def platform_invoice_list_with_http_info(platform_pk, opts = {})
1339
+ if @api_client.config.debugging
1340
+ @api_client.config.logger.debug "Calling API: PlatformsApi.platform_invoice_list ..."
1341
+ end
1342
+ # verify the required parameter 'platform_pk' is set
1343
+ fail ArgumentError, "Missing the required parameter 'platform_pk' when calling PlatformsApi.platform_invoice_list" if platform_pk.nil?
1344
+ # resource path
1345
+ local_var_path = "/platforms/{platform_pk}/invoices/".sub('{format}','json').sub('{' + 'platform_pk' + '}', platform_pk.to_s)
1346
+
1347
+ # query parameters
1348
+ query_params = {}
1349
+
1350
+ # header parameters
1351
+ header_params = {}
1352
+
1353
+ # HTTP header 'Accept' (if needed)
1354
+ local_header_accept = []
1355
+ local_header_accept_result = @api_client.select_header_accept(local_header_accept) and header_params['Accept'] = local_header_accept_result
1356
+
1357
+ # HTTP header 'Content-Type'
1358
+ local_header_content_type = []
1359
+ header_params['Content-Type'] = @api_client.select_header_content_type(local_header_content_type)
1360
+
1361
+ # form parameters
1362
+ form_params = {}
1363
+
1364
+ # http body (model)
1365
+ post_body = nil
1366
+ auth_names = []
1367
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
1368
+ :header_params => header_params,
1369
+ :query_params => query_params,
1370
+ :form_params => form_params,
1371
+ :body => post_body,
1372
+ :auth_names => auth_names,
1373
+ :return_type => 'Array<InvoiceSerializer>')
1374
+ if @api_client.config.debugging
1375
+ @api_client.config.logger.debug "API called: PlatformsApi#platform_invoice_list\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1376
+ end
1377
+ return data, status_code, headers
1378
+ end
1379
+
1380
+ #
1381
+ #
1382
+ # @param platform_pk
1383
+ # @param user
1384
+ # @param [Hash] opts the optional parameters
1385
+ # @return [MembershipSerializer]
1386
+ def platform_membership_create(platform_pk, user, opts = {})
1387
+ data, _status_code, _headers = platform_membership_create_with_http_info(platform_pk, user, opts)
1388
+ return data
1389
+ end
1390
+
1391
+ #
1392
+ #
1393
+ # @param platform_pk
1394
+ # @param user
1395
+ # @param [Hash] opts the optional parameters
1396
+ # @return [Array<(MembershipSerializer, Fixnum, Hash)>] MembershipSerializer data, response status code and response headers
1397
+ def platform_membership_create_with_http_info(platform_pk, user, opts = {})
1398
+ if @api_client.config.debugging
1399
+ @api_client.config.logger.debug "Calling API: PlatformsApi.platform_membership_create ..."
1400
+ end
1401
+ # verify the required parameter 'platform_pk' is set
1402
+ fail ArgumentError, "Missing the required parameter 'platform_pk' when calling PlatformsApi.platform_membership_create" if platform_pk.nil?
1403
+ # verify the required parameter 'user' is set
1404
+ fail ArgumentError, "Missing the required parameter 'user' when calling PlatformsApi.platform_membership_create" if user.nil?
1405
+ # resource path
1406
+ local_var_path = "/platforms/{platform_pk}/memberships/".sub('{format}','json').sub('{' + 'platform_pk' + '}', platform_pk.to_s)
1407
+
1408
+ # query parameters
1409
+ query_params = {}
1410
+
1411
+ # header parameters
1412
+ header_params = {}
1413
+
1414
+ # HTTP header 'Accept' (if needed)
1415
+ local_header_accept = []
1416
+ local_header_accept_result = @api_client.select_header_accept(local_header_accept) and header_params['Accept'] = local_header_accept_result
1417
+
1418
+ # HTTP header 'Content-Type'
1419
+ local_header_content_type = []
1420
+ header_params['Content-Type'] = @api_client.select_header_content_type(local_header_content_type)
1421
+
1422
+ # form parameters
1423
+ form_params = {}
1424
+ form_params["user"] = user
1425
+
1426
+ # http body (model)
1427
+ post_body = nil
1428
+ auth_names = []
1429
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path,
1430
+ :header_params => header_params,
1431
+ :query_params => query_params,
1432
+ :form_params => form_params,
1433
+ :body => post_body,
1434
+ :auth_names => auth_names,
1435
+ :return_type => 'MembershipSerializer')
1436
+ if @api_client.config.debugging
1437
+ @api_client.config.logger.debug "API called: PlatformsApi#platform_membership_create\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1438
+ end
1439
+ return data, status_code, headers
1440
+ end
1441
+
1442
+ # Temporary special-case logic to map old Platform memberships onto the new API
1443
+ # Temporary special-case logic to map old Platform memberships onto the new API.<br/>Generate a faux Membership for each User.profile.platform FKey ref.
1444
+ # @param platform_pk
1445
+ # @param [Hash] opts the optional parameters
1446
+ # @return [Array<MembershipSerializer>]
1447
+ def platform_membership_list(platform_pk, opts = {})
1448
+ data, _status_code, _headers = platform_membership_list_with_http_info(platform_pk, opts)
1449
+ return data
1450
+ end
1451
+
1452
+ # Temporary special-case logic to map old Platform memberships onto the new API
1453
+ # Temporary special-case logic to map old Platform memberships onto the new API.&lt;br/&gt;Generate a faux Membership for each User.profile.platform FKey ref.
1454
+ # @param platform_pk
1455
+ # @param [Hash] opts the optional parameters
1456
+ # @return [Array<(Array<MembershipSerializer>, Fixnum, Hash)>] Array<MembershipSerializer> data, response status code and response headers
1457
+ def platform_membership_list_with_http_info(platform_pk, opts = {})
1458
+ if @api_client.config.debugging
1459
+ @api_client.config.logger.debug "Calling API: PlatformsApi.platform_membership_list ..."
1460
+ end
1461
+ # verify the required parameter 'platform_pk' is set
1462
+ fail ArgumentError, "Missing the required parameter 'platform_pk' when calling PlatformsApi.platform_membership_list" if platform_pk.nil?
1463
+ # resource path
1464
+ local_var_path = "/platforms/{platform_pk}/memberships/".sub('{format}','json').sub('{' + 'platform_pk' + '}', platform_pk.to_s)
1465
+
1466
+ # query parameters
1467
+ query_params = {}
1468
+
1469
+ # header parameters
1470
+ header_params = {}
1471
+
1472
+ # HTTP header 'Accept' (if needed)
1473
+ local_header_accept = []
1474
+ local_header_accept_result = @api_client.select_header_accept(local_header_accept) and header_params['Accept'] = local_header_accept_result
1475
+
1476
+ # HTTP header 'Content-Type'
1477
+ local_header_content_type = []
1478
+ header_params['Content-Type'] = @api_client.select_header_content_type(local_header_content_type)
1479
+
1480
+ # form parameters
1481
+ form_params = {}
1482
+
1483
+ # http body (model)
1484
+ post_body = nil
1485
+ auth_names = []
1486
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
1487
+ :header_params => header_params,
1488
+ :query_params => query_params,
1489
+ :form_params => form_params,
1490
+ :body => post_body,
1491
+ :auth_names => auth_names,
1492
+ :return_type => 'Array<MembershipSerializer>')
1493
+ if @api_client.config.debugging
1494
+ @api_client.config.logger.debug "API called: PlatformsApi#platform_membership_list\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1495
+ end
1496
+ return data, status_code, headers
1497
+ end
1498
+
1499
+ #
1500
+ #
1501
+ # @param platform_pk
1502
+ # @param [Hash] opts the optional parameters
1503
+ # @return [Array<PlatformMembershipRequestSerializer>]
1504
+ def platform_membership_request_list(platform_pk, opts = {})
1505
+ data, _status_code, _headers = platform_membership_request_list_with_http_info(platform_pk, opts)
1506
+ return data
1507
+ end
1508
+
1509
+ #
1510
+ #
1511
+ # @param platform_pk
1512
+ # @param [Hash] opts the optional parameters
1513
+ # @return [Array<(Array<PlatformMembershipRequestSerializer>, Fixnum, Hash)>] Array<PlatformMembershipRequestSerializer> data, response status code and response headers
1514
+ def platform_membership_request_list_with_http_info(platform_pk, opts = {})
1515
+ if @api_client.config.debugging
1516
+ @api_client.config.logger.debug "Calling API: PlatformsApi.platform_membership_request_list ..."
1517
+ end
1518
+ # verify the required parameter 'platform_pk' is set
1519
+ fail ArgumentError, "Missing the required parameter 'platform_pk' when calling PlatformsApi.platform_membership_request_list" if platform_pk.nil?
1520
+ # resource path
1521
+ local_var_path = "/platforms/{platform_pk}/membership_requests/".sub('{format}','json').sub('{' + 'platform_pk' + '}', platform_pk.to_s)
1522
+
1523
+ # query parameters
1524
+ query_params = {}
1525
+
1526
+ # header parameters
1527
+ header_params = {}
1528
+
1529
+ # HTTP header 'Accept' (if needed)
1530
+ local_header_accept = []
1531
+ local_header_accept_result = @api_client.select_header_accept(local_header_accept) and header_params['Accept'] = local_header_accept_result
1532
+
1533
+ # HTTP header 'Content-Type'
1534
+ local_header_content_type = []
1535
+ header_params['Content-Type'] = @api_client.select_header_content_type(local_header_content_type)
1536
+
1537
+ # form parameters
1538
+ form_params = {}
1539
+
1540
+ # http body (model)
1541
+ post_body = nil
1542
+ auth_names = []
1543
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
1544
+ :header_params => header_params,
1545
+ :query_params => query_params,
1546
+ :form_params => form_params,
1547
+ :body => post_body,
1548
+ :auth_names => auth_names,
1549
+ :return_type => 'Array<PlatformMembershipRequestSerializer>')
1550
+ if @api_client.config.debugging
1551
+ @api_client.config.logger.debug "API called: PlatformsApi#platform_membership_request_list\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1552
+ end
1553
+ return data, status_code, headers
1554
+ end
1555
+
1556
+ #
1557
+ #
1558
+ # @param platform_pk
1559
+ # @param pk
1560
+ # @param [Hash] opts the optional parameters
1561
+ # @return [PlatformMembershipRequestSerializer]
1562
+ def platform_membership_request_retrieve(platform_pk, pk, opts = {})
1563
+ data, _status_code, _headers = platform_membership_request_retrieve_with_http_info(platform_pk, pk, opts)
1564
+ return data
1565
+ end
1566
+
1567
+ #
1568
+ #
1569
+ # @param platform_pk
1570
+ # @param pk
1571
+ # @param [Hash] opts the optional parameters
1572
+ # @return [Array<(PlatformMembershipRequestSerializer, Fixnum, Hash)>] PlatformMembershipRequestSerializer data, response status code and response headers
1573
+ def platform_membership_request_retrieve_with_http_info(platform_pk, pk, opts = {})
1574
+ if @api_client.config.debugging
1575
+ @api_client.config.logger.debug "Calling API: PlatformsApi.platform_membership_request_retrieve ..."
1576
+ end
1577
+ # verify the required parameter 'platform_pk' is set
1578
+ fail ArgumentError, "Missing the required parameter 'platform_pk' when calling PlatformsApi.platform_membership_request_retrieve" if platform_pk.nil?
1579
+ # verify the required parameter 'pk' is set
1580
+ fail ArgumentError, "Missing the required parameter 'pk' when calling PlatformsApi.platform_membership_request_retrieve" if pk.nil?
1581
+ # resource path
1582
+ local_var_path = "/platforms/{platform_pk}/membership_requests/{pk}/".sub('{format}','json').sub('{' + 'platform_pk' + '}', platform_pk.to_s).sub('{' + 'pk' + '}', pk.to_s)
1583
+
1584
+ # query parameters
1585
+ query_params = {}
1586
+
1587
+ # header parameters
1588
+ header_params = {}
1589
+
1590
+ # HTTP header 'Accept' (if needed)
1591
+ local_header_accept = []
1592
+ local_header_accept_result = @api_client.select_header_accept(local_header_accept) and header_params['Accept'] = local_header_accept_result
1593
+
1594
+ # HTTP header 'Content-Type'
1595
+ local_header_content_type = []
1596
+ header_params['Content-Type'] = @api_client.select_header_content_type(local_header_content_type)
1597
+
1598
+ # form parameters
1599
+ form_params = {}
1600
+
1601
+ # http body (model)
1602
+ post_body = nil
1603
+ auth_names = []
1604
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
1605
+ :header_params => header_params,
1606
+ :query_params => query_params,
1607
+ :form_params => form_params,
1608
+ :body => post_body,
1609
+ :auth_names => auth_names,
1610
+ :return_type => 'PlatformMembershipRequestSerializer')
1611
+ if @api_client.config.debugging
1612
+ @api_client.config.logger.debug "API called: PlatformsApi#platform_membership_request_retrieve\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1613
+ end
1614
+ return data, status_code, headers
1615
+ end
1616
+
1617
+ #
1618
+ #
1619
+ # @param pk
1620
+ # @param [Hash] opts the optional parameters
1621
+ # @return [PlatformSerializer]
1622
+ def platform_retrieve(pk, opts = {})
1623
+ data, _status_code, _headers = platform_retrieve_with_http_info(pk, opts)
1624
+ return data
1625
+ end
1626
+
1627
+ #
1628
+ #
1629
+ # @param pk
1630
+ # @param [Hash] opts the optional parameters
1631
+ # @return [Array<(PlatformSerializer, Fixnum, Hash)>] PlatformSerializer data, response status code and response headers
1632
+ def platform_retrieve_with_http_info(pk, opts = {})
1633
+ if @api_client.config.debugging
1634
+ @api_client.config.logger.debug "Calling API: PlatformsApi.platform_retrieve ..."
1635
+ end
1636
+ # verify the required parameter 'pk' is set
1637
+ fail ArgumentError, "Missing the required parameter 'pk' when calling PlatformsApi.platform_retrieve" if pk.nil?
1638
+ # resource path
1639
+ local_var_path = "/platforms/{pk}/".sub('{format}','json').sub('{' + 'pk' + '}', pk.to_s)
1640
+
1641
+ # query parameters
1642
+ query_params = {}
1643
+
1644
+ # header parameters
1645
+ header_params = {}
1646
+
1647
+ # HTTP header 'Accept' (if needed)
1648
+ local_header_accept = []
1649
+ local_header_accept_result = @api_client.select_header_accept(local_header_accept) and header_params['Accept'] = local_header_accept_result
1650
+
1651
+ # HTTP header 'Content-Type'
1652
+ local_header_content_type = []
1653
+ header_params['Content-Type'] = @api_client.select_header_content_type(local_header_content_type)
1654
+
1655
+ # form parameters
1656
+ form_params = {}
1657
+
1658
+ # http body (model)
1659
+ post_body = nil
1660
+ auth_names = []
1661
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
1662
+ :header_params => header_params,
1663
+ :query_params => query_params,
1664
+ :form_params => form_params,
1665
+ :body => post_body,
1666
+ :auth_names => auth_names,
1667
+ :return_type => 'PlatformSerializer')
1668
+ if @api_client.config.debugging
1669
+ @api_client.config.logger.debug "API called: PlatformsApi#platform_retrieve\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1670
+ end
1671
+ return data, status_code, headers
1672
+ end
1673
+ end
1674
+ end