Class: AmzSpApi::FinancesApiModel::DefaultApi
- Inherits:
-
Object
- Object
- AmzSpApi::FinancesApiModel::DefaultApi
- Defined in:
- lib/finances-api-model/api/default_api.rb
Instance Attribute Summary collapse
-
#api_client ⇒ Object
Returns the value of attribute api_client.
Instance Method Summary collapse
-
#initialize(api_client = ApiClient.default) ⇒ DefaultApi
constructor
A new instance of DefaultApi.
-
#list_financial_event_groups(opts = {}) ⇒ ListFinancialEventGroupsResponse
Returns financial event groups for a given date range.
-
#list_financial_event_groups_with_http_info(opts = {}) ⇒ Array<(ListFinancialEventGroupsResponse, Integer, Hash)>
Returns financial event groups for a given date range.
-
#list_financial_events(opts = {}) ⇒ ListFinancialEventsResponse
Returns financial events for the specified data range.
-
#list_financial_events_by_group_id(event_group_id, opts = {}) ⇒ ListFinancialEventsResponse
Returns all financial events for the specified financial event group.
-
#list_financial_events_by_group_id_with_http_info(event_group_id, opts = {}) ⇒ Array<(ListFinancialEventsResponse, Integer, Hash)>
Returns all financial events for the specified financial event group.
-
#list_financial_events_by_order_id(order_id, opts = {}) ⇒ ListFinancialEventsResponse
Returns all financial events for the specified order.
-
#list_financial_events_by_order_id_with_http_info(order_id, opts = {}) ⇒ Array<(ListFinancialEventsResponse, Integer, Hash)>
Returns all financial events for the specified order.
-
#list_financial_events_with_http_info(opts = {}) ⇒ Array<(ListFinancialEventsResponse, Integer, Hash)>
Returns financial events for the specified data range.
Constructor Details
#initialize(api_client = ApiClient.default) ⇒ DefaultApi
Returns a new instance of DefaultApi.
16 17 18 |
# File 'lib/finances-api-model/api/default_api.rb', line 16 def initialize(api_client = ApiClient.default) @api_client = api_client end |
Instance Attribute Details
#api_client ⇒ Object
Returns the value of attribute api_client.
14 15 16 |
# File 'lib/finances-api-model/api/default_api.rb', line 14 def api_client @api_client end |
Instance Method Details
#list_financial_event_groups(opts = {}) ⇒ ListFinancialEventGroupsResponse
Returns financial event groups for a given date range. **Usage Plan:** | Rate (requests per second) | Burst | | —- | —- | | 0.5 | 30 | For more information, see "Usage Plans and Rate Limits" in the Selling Partner API documentation.
26 27 28 29 |
# File 'lib/finances-api-model/api/default_api.rb', line 26 def list_financial_event_groups(opts = {}) data, _status_code, _headers = list_financial_event_groups_with_http_info(opts) data end |
#list_financial_event_groups_with_http_info(opts = {}) ⇒ Array<(ListFinancialEventGroupsResponse, Integer, Hash)>
Returns financial event groups for a given date range. **Usage Plan:** | Rate (requests per second) | Burst | | —- | —- | | 0.5 | 30 | For more information, see "Usage Plans and Rate Limits" in the Selling Partner API documentation.
38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 |
# File 'lib/finances-api-model/api/default_api.rb', line 38 def list_financial_event_groups_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: DefaultApi.list_financial_event_groups ...' end # resource path local_var_path = '/finances/v0/financialEventGroups' # query parameters query_params = opts[:query_params] || {} query_params[:'MaxResultsPerPage'] = opts[:'max_results_per_page'] if !opts[:'max_results_per_page'].nil? query_params[:'FinancialEventGroupStartedBefore'] = opts[:'financial_event_group_started_before'] if !opts[:'financial_event_group_started_before'].nil? query_params[:'FinancialEventGroupStartedAfter'] = opts[:'financial_event_group_started_after'] if !opts[:'financial_event_group_started_after'].nil? query_params[:'NextToken'] = opts[:'next_token'] if !opts[:'next_token'].nil? # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] return_type = opts[:return_type] || 'ListFinancialEventGroupsResponse' auth_names = opts[:auth_names] || [] data, status_code, headers = @api_client.call_api(:GET, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type) if @api_client.config.debugging @api_client.config.logger.debug "API called: DefaultApi#list_financial_event_groups\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#list_financial_events(opts = {}) ⇒ ListFinancialEventsResponse
Returns financial events for the specified data range. **Usage Plan:** | Rate (requests per second) | Burst | | —- | —- | | 0.5 | 30 | For more information, see "Usage Plans and Rate Limits" in the Selling Partner API documentation.
86 87 88 89 |
# File 'lib/finances-api-model/api/default_api.rb', line 86 def list_financial_events(opts = {}) data, _status_code, _headers = list_financial_events_with_http_info(opts) data end |
#list_financial_events_by_group_id(event_group_id, opts = {}) ⇒ ListFinancialEventsResponse
Returns all financial events for the specified financial event group. **Usage Plan:** | Rate (requests per second) | Burst | | —- | —- | | 0.5 | 30 | For more information, see "Usage Plans and Rate Limits" in the Selling Partner API documentation.
145 146 147 148 |
# File 'lib/finances-api-model/api/default_api.rb', line 145 def list_financial_events_by_group_id(event_group_id, opts = {}) data, _status_code, _headers = list_financial_events_by_group_id_with_http_info(event_group_id, opts) data end |
#list_financial_events_by_group_id_with_http_info(event_group_id, opts = {}) ⇒ Array<(ListFinancialEventsResponse, Integer, Hash)>
Returns all financial events for the specified financial event group. **Usage Plan:** | Rate (requests per second) | Burst | | —- | —- | | 0.5 | 30 | For more information, see "Usage Plans and Rate Limits" in the Selling Partner API documentation.
156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 |
# File 'lib/finances-api-model/api/default_api.rb', line 156 def list_financial_events_by_group_id_with_http_info(event_group_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: DefaultApi.list_financial_events_by_group_id ...' end # verify the required parameter 'event_group_id' is set if @api_client.config.client_side_validation && event_group_id.nil? fail ArgumentError, "Missing the required parameter 'event_group_id' when calling DefaultApi.list_financial_events_by_group_id" end # resource path local_var_path = '/finances/v0/financialEventGroups/{eventGroupId}/financialEvents'.sub('{' + 'eventGroupId' + '}', event_group_id.to_s) # query parameters query_params = opts[:query_params] || {} query_params[:'MaxResultsPerPage'] = opts[:'max_results_per_page'] if !opts[:'max_results_per_page'].nil? query_params[:'NextToken'] = opts[:'next_token'] if !opts[:'next_token'].nil? # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] return_type = opts[:return_type] || 'ListFinancialEventsResponse' auth_names = opts[:auth_names] || [] data, status_code, headers = @api_client.call_api(:GET, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type) if @api_client.config.debugging @api_client.config.logger.debug "API called: DefaultApi#list_financial_events_by_group_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#list_financial_events_by_order_id(order_id, opts = {}) ⇒ ListFinancialEventsResponse
Returns all financial events for the specified order. **Usage Plan:** | Rate (requests per second) | Burst | | —- | —- | | 0.5 | 30 | For more information, see "Usage Plans and Rate Limits" in the Selling Partner API documentation.
205 206 207 208 |
# File 'lib/finances-api-model/api/default_api.rb', line 205 def list_financial_events_by_order_id(order_id, opts = {}) data, _status_code, _headers = list_financial_events_by_order_id_with_http_info(order_id, opts) data end |
#list_financial_events_by_order_id_with_http_info(order_id, opts = {}) ⇒ Array<(ListFinancialEventsResponse, Integer, Hash)>
Returns all financial events for the specified order. **Usage Plan:** | Rate (requests per second) | Burst | | —- | —- | | 0.5 | 30 | For more information, see "Usage Plans and Rate Limits" in the Selling Partner API documentation.
216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 |
# File 'lib/finances-api-model/api/default_api.rb', line 216 def list_financial_events_by_order_id_with_http_info(order_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: DefaultApi.list_financial_events_by_order_id ...' end # verify the required parameter 'order_id' is set if @api_client.config.client_side_validation && order_id.nil? fail ArgumentError, "Missing the required parameter 'order_id' when calling DefaultApi.list_financial_events_by_order_id" end # resource path local_var_path = '/finances/v0/orders/{orderId}/financialEvents'.sub('{' + 'orderId' + '}', order_id.to_s) # query parameters query_params = opts[:query_params] || {} query_params[:'MaxResultsPerPage'] = opts[:'max_results_per_page'] if !opts[:'max_results_per_page'].nil? query_params[:'NextToken'] = opts[:'next_token'] if !opts[:'next_token'].nil? # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] return_type = opts[:return_type] || 'ListFinancialEventsResponse' auth_names = opts[:auth_names] || [] data, status_code, headers = @api_client.call_api(:GET, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type) if @api_client.config.debugging @api_client.config.logger.debug "API called: DefaultApi#list_financial_events_by_order_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#list_financial_events_with_http_info(opts = {}) ⇒ Array<(ListFinancialEventsResponse, Integer, Hash)>
Returns financial events for the specified data range. **Usage Plan:** | Rate (requests per second) | Burst | | —- | —- | | 0.5 | 30 | For more information, see "Usage Plans and Rate Limits" in the Selling Partner API documentation.
98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 |
# File 'lib/finances-api-model/api/default_api.rb', line 98 def list_financial_events_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: DefaultApi.list_financial_events ...' end # resource path local_var_path = '/finances/v0/financialEvents' # query parameters query_params = opts[:query_params] || {} query_params[:'MaxResultsPerPage'] = opts[:'max_results_per_page'] if !opts[:'max_results_per_page'].nil? query_params[:'PostedAfter'] = opts[:'posted_after'] if !opts[:'posted_after'].nil? query_params[:'PostedBefore'] = opts[:'posted_before'] if !opts[:'posted_before'].nil? query_params[:'NextToken'] = opts[:'next_token'] if !opts[:'next_token'].nil? # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] return_type = opts[:return_type] || 'ListFinancialEventsResponse' auth_names = opts[:auth_names] || [] data, status_code, headers = @api_client.call_api(:GET, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type) if @api_client.config.debugging @api_client.config.logger.debug "API called: DefaultApi#list_financial_events\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |