Class: TogaiClient::PricePlanV2Api
- Inherits:
-
Object
- Object
- TogaiClient::PricePlanV2Api
- Defined in:
- lib/togai_client/api/price_plan_v2_api.rb
Instance Attribute Summary collapse
-
#api_client ⇒ Object
Returns the value of attribute api_client.
Instance Method Summary collapse
-
#bulk_price_plan_rate_card_operations(price_plan_id, bulk_rate_card_operations_request, opts = {}) ⇒ BulkRateCardOperationsResponse
Bulk rate card operations of a price plan Bulk rate card operations of a price plan.
-
#bulk_price_plan_rate_card_operations_with_http_info(price_plan_id, bulk_rate_card_operations_request, opts = {}) ⇒ Array<(BulkRateCardOperationsResponse, Integer, Hash)>
Bulk rate card operations of a price plan Bulk rate card operations of a price plan.
-
#create_price_plan_v2(create_price_plan_v2_request, opts = {}) ⇒ PricePlanV2
Create a price plan Create a price plan.
-
#create_price_plan_v2_with_http_info(create_price_plan_v2_request, opts = {}) ⇒ Array<(PricePlanV2, Integer, Hash)>
Create a price plan Create a price plan.
-
#discard_price_plan(price_plan_id, opts = {}) ⇒ BaseSuccessResponse
Discard a price plan Discard a price plan.
-
#discard_price_plan_with_http_info(price_plan_id, opts = {}) ⇒ Array<(BaseSuccessResponse, Integer, Hash)>
Discard a price plan Discard a price plan.
-
#finalize_price_plan(price_plan_id, finalize_price_plan_request, opts = {}) ⇒ BaseSuccessResponse
Finalize a price plan Finalize a price plan.
-
#finalize_price_plan_with_http_info(price_plan_id, finalize_price_plan_request, opts = {}) ⇒ Array<(BaseSuccessResponse, Integer, Hash)>
Finalize a price plan Finalize a price plan.
-
#get_price_plan_v2(price_plan_id, opts = {}) ⇒ PricePlanV2
Get a price plan Get a price plan.
-
#get_price_plan_v2_with_http_info(price_plan_id, opts = {}) ⇒ Array<(PricePlanV2, Integer, Hash)>
Get a price plan Get a price plan.
-
#initialize(api_client = ApiClient.default) ⇒ PricePlanV2Api
constructor
A new instance of PricePlanV2Api.
-
#list_price_plan_errors(price_plan_id, opts = {}) ⇒ ValidatedEntityErrorsPaginatedResponse
Get list of errors of a price plan Get list of errors of a price plan.
-
#list_price_plan_errors_with_http_info(price_plan_id, opts = {}) ⇒ Array<(ValidatedEntityErrorsPaginatedResponse, Integer, Hash)>
Get list of errors of a price plan Get list of errors of a price plan.
-
#list_price_plan_pricing_rules(price_plan_id, opts = {}) ⇒ PricingRulesPaginatedResponse
List pricing rules of a price plan List pricing rules of a price plan.
-
#list_price_plan_pricing_rules_with_http_info(price_plan_id, opts = {}) ⇒ Array<(PricingRulesPaginatedResponse, Integer, Hash)>
List pricing rules of a price plan List pricing rules of a price plan.
-
#list_price_plan_rate_cards(price_plan_id, opts = {}) ⇒ RateCardPaginatedResponse
List rate cards of a price plan List rate cards of a price plan.
-
#list_price_plan_rate_cards_with_http_info(price_plan_id, opts = {}) ⇒ Array<(RateCardPaginatedResponse, Integer, Hash)>
List rate cards of a price plan List rate cards of a price plan.
-
#list_price_plan_versions(price_plan_id, opts = {}) ⇒ PricePlanV2PaginatedResponse
List price plan versions List price plan versions.
-
#list_price_plan_versions_with_http_info(price_plan_id, opts = {}) ⇒ Array<(PricePlanV2PaginatedResponse, Integer, Hash)>
List price plan versions List price plan versions.
-
#list_price_plans_v2(opts = {}) ⇒ PricePlanV2PaginatedResponse
List price plans List price plans.
-
#list_price_plans_v2_with_http_info(opts = {}) ⇒ Array<(PricePlanV2PaginatedResponse, Integer, Hash)>
List price plans List price plans.
-
#price_plan_migration_v2(create_price_plan_migration_request, opts = {}) ⇒ BaseSuccessResponse
Create a price plan v2 migration Migrates accounts across price plans.
-
#price_plan_migration_v2_with_http_info(create_price_plan_migration_request, opts = {}) ⇒ Array<(BaseSuccessResponse, Integer, Hash)>
Create a price plan v2 migration Migrates accounts across price plans.
-
#update_price_plan_pricing_rules(price_plan_id, update_pricing_rules_request, opts = {}) ⇒ PricingRulesPaginatedResponse
Update pricing rules of a price plan Update pricing rules of a price plan.
-
#update_price_plan_pricing_rules_with_http_info(price_plan_id, update_pricing_rules_request, opts = {}) ⇒ Array<(PricingRulesPaginatedResponse, Integer, Hash)>
Update pricing rules of a price plan Update pricing rules of a price plan.
-
#update_price_plan_v2(price_plan_id, update_price_plan_v2_request, opts = {}) ⇒ PricePlanV2
Update a price plan Update a price plan.
-
#update_price_plan_v2_with_http_info(price_plan_id, update_price_plan_v2_request, opts = {}) ⇒ Array<(PricePlanV2, Integer, Hash)>
Update a price plan Update a price plan.
Constructor Details
#initialize(api_client = ApiClient.default) ⇒ PricePlanV2Api
Returns a new instance of PricePlanV2Api.
19 20 21 |
# File 'lib/togai_client/api/price_plan_v2_api.rb', line 19 def initialize(api_client = ApiClient.default) @api_client = api_client end |
Instance Attribute Details
#api_client ⇒ Object
Returns the value of attribute api_client.
17 18 19 |
# File 'lib/togai_client/api/price_plan_v2_api.rb', line 17 def api_client @api_client end |
Instance Method Details
#bulk_price_plan_rate_card_operations(price_plan_id, bulk_rate_card_operations_request, opts = {}) ⇒ BulkRateCardOperationsResponse
Bulk rate card operations of a price plan Bulk rate card operations of a price plan
28 29 30 31 |
# File 'lib/togai_client/api/price_plan_v2_api.rb', line 28 def bulk_price_plan_rate_card_operations(price_plan_id, bulk_rate_card_operations_request, opts = {}) data, _status_code, _headers = bulk_price_plan_rate_card_operations_with_http_info(price_plan_id, bulk_rate_card_operations_request, opts) data end |
#bulk_price_plan_rate_card_operations_with_http_info(price_plan_id, bulk_rate_card_operations_request, opts = {}) ⇒ Array<(BulkRateCardOperationsResponse, Integer, Hash)>
Bulk rate card operations of a price plan Bulk rate card operations of a price plan
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 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 |
# File 'lib/togai_client/api/price_plan_v2_api.rb', line 39 def bulk_price_plan_rate_card_operations_with_http_info(price_plan_id, bulk_rate_card_operations_request, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: PricePlanV2Api.bulk_price_plan_rate_card_operations ...' end # verify the required parameter 'price_plan_id' is set if @api_client.config.client_side_validation && price_plan_id.nil? fail ArgumentError, "Missing the required parameter 'price_plan_id' when calling PricePlanV2Api.bulk_price_plan_rate_card_operations" end if @api_client.config.client_side_validation && price_plan_id.to_s.length > 50 fail ArgumentError, 'invalid value for "price_plan_id" when calling PricePlanV2Api.bulk_price_plan_rate_card_operations, the character length must be smaller than or equal to 50.' end # verify the required parameter 'bulk_rate_card_operations_request' is set if @api_client.config.client_side_validation && bulk_rate_card_operations_request.nil? fail ArgumentError, "Missing the required parameter 'bulk_rate_card_operations_request' when calling PricePlanV2Api.bulk_price_plan_rate_card_operations" end # resource path local_var_path = '/v2/price_plans/{price_plan_id}/rate_cards'.sub('{' + 'price_plan_id' + '}', CGI.escape(price_plan_id.to_s)) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept'] # HTTP header 'Content-Type' content_type = @api_client.select_header_content_type(['application/json']) if !content_type.nil? header_params['Content-Type'] = content_type end # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] || @api_client.object_to_http_body(bulk_rate_card_operations_request) # return_type return_type = opts[:debug_return_type] || 'BulkRateCardOperationsResponse' # auth_names auth_names = opts[:debug_auth_names] || ['bearerAuth'] = opts.merge( :operation => :"PricePlanV2Api.bulk_price_plan_rate_card_operations", :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:POST, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: PricePlanV2Api#bulk_price_plan_rate_card_operations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#create_price_plan_v2(create_price_plan_v2_request, opts = {}) ⇒ PricePlanV2
Create a price plan Create a price plan
106 107 108 109 |
# File 'lib/togai_client/api/price_plan_v2_api.rb', line 106 def create_price_plan_v2(create_price_plan_v2_request, opts = {}) data, _status_code, _headers = create_price_plan_v2_with_http_info(create_price_plan_v2_request, opts) data end |
#create_price_plan_v2_with_http_info(create_price_plan_v2_request, opts = {}) ⇒ Array<(PricePlanV2, Integer, Hash)>
Create a price plan Create a price plan
117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 |
# File 'lib/togai_client/api/price_plan_v2_api.rb', line 117 def create_price_plan_v2_with_http_info(create_price_plan_v2_request, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: PricePlanV2Api.create_price_plan_v2 ...' end # verify the required parameter 'create_price_plan_v2_request' is set if @api_client.config.client_side_validation && create_price_plan_v2_request.nil? fail ArgumentError, "Missing the required parameter 'create_price_plan_v2_request' when calling PricePlanV2Api.create_price_plan_v2" end if @api_client.config.client_side_validation && !opts[:'source_price_plan_id'].nil? && opts[:'source_price_plan_id'].to_s.length > 50 fail ArgumentError, 'invalid value for "opts[:"source_price_plan_id"]" when calling PricePlanV2Api.create_price_plan_v2, the character length must be smaller than or equal to 50.' end # resource path local_var_path = '/v2/price_plans' # query parameters query_params = opts[:query_params] || {} query_params[:'source_price_plan_id'] = opts[:'source_price_plan_id'] if !opts[:'source_price_plan_id'].nil? # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept'] # HTTP header 'Content-Type' content_type = @api_client.select_header_content_type(['application/json']) if !content_type.nil? header_params['Content-Type'] = content_type end # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] || @api_client.object_to_http_body(create_price_plan_v2_request) # return_type return_type = opts[:debug_return_type] || 'PricePlanV2' # auth_names auth_names = opts[:debug_auth_names] || ['bearerAuth'] = opts.merge( :operation => :"PricePlanV2Api.create_price_plan_v2", :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:POST, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: PricePlanV2Api#create_price_plan_v2\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#discard_price_plan(price_plan_id, opts = {}) ⇒ BaseSuccessResponse
Discard a price plan Discard a price plan
180 181 182 183 |
# File 'lib/togai_client/api/price_plan_v2_api.rb', line 180 def discard_price_plan(price_plan_id, opts = {}) data, _status_code, _headers = discard_price_plan_with_http_info(price_plan_id, opts) data end |
#discard_price_plan_with_http_info(price_plan_id, opts = {}) ⇒ Array<(BaseSuccessResponse, Integer, Hash)>
Discard a price plan Discard a price plan
190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 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 |
# File 'lib/togai_client/api/price_plan_v2_api.rb', line 190 def discard_price_plan_with_http_info(price_plan_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: PricePlanV2Api.discard_price_plan ...' end # verify the required parameter 'price_plan_id' is set if @api_client.config.client_side_validation && price_plan_id.nil? fail ArgumentError, "Missing the required parameter 'price_plan_id' when calling PricePlanV2Api.discard_price_plan" end if @api_client.config.client_side_validation && price_plan_id.to_s.length > 50 fail ArgumentError, 'invalid value for "price_plan_id" when calling PricePlanV2Api.discard_price_plan, the character length must be smaller than or equal to 50.' end # resource path local_var_path = '/v2/price_plans/{price_plan_id}/discard'.sub('{' + 'price_plan_id' + '}', CGI.escape(price_plan_id.to_s)) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept'] # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] || 'BaseSuccessResponse' # auth_names auth_names = opts[:debug_auth_names] || ['bearerAuth'] = opts.merge( :operation => :"PricePlanV2Api.discard_price_plan", :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: PricePlanV2Api#discard_price_plan\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#finalize_price_plan(price_plan_id, finalize_price_plan_request, opts = {}) ⇒ BaseSuccessResponse
Finalize a price plan Finalize a price plan
248 249 250 251 |
# File 'lib/togai_client/api/price_plan_v2_api.rb', line 248 def finalize_price_plan(price_plan_id, finalize_price_plan_request, opts = {}) data, _status_code, _headers = finalize_price_plan_with_http_info(price_plan_id, finalize_price_plan_request, opts) data end |
#finalize_price_plan_with_http_info(price_plan_id, finalize_price_plan_request, opts = {}) ⇒ Array<(BaseSuccessResponse, Integer, Hash)>
Finalize a price plan Finalize a price plan
259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 |
# File 'lib/togai_client/api/price_plan_v2_api.rb', line 259 def finalize_price_plan_with_http_info(price_plan_id, finalize_price_plan_request, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: PricePlanV2Api.finalize_price_plan ...' end # verify the required parameter 'price_plan_id' is set if @api_client.config.client_side_validation && price_plan_id.nil? fail ArgumentError, "Missing the required parameter 'price_plan_id' when calling PricePlanV2Api.finalize_price_plan" end if @api_client.config.client_side_validation && price_plan_id.to_s.length > 50 fail ArgumentError, 'invalid value for "price_plan_id" when calling PricePlanV2Api.finalize_price_plan, the character length must be smaller than or equal to 50.' end # verify the required parameter 'finalize_price_plan_request' is set if @api_client.config.client_side_validation && finalize_price_plan_request.nil? fail ArgumentError, "Missing the required parameter 'finalize_price_plan_request' when calling PricePlanV2Api.finalize_price_plan" end # resource path local_var_path = '/v2/price_plans/{price_plan_id}/finalize'.sub('{' + 'price_plan_id' + '}', CGI.escape(price_plan_id.to_s)) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept'] # HTTP header 'Content-Type' content_type = @api_client.select_header_content_type(['application/json']) if !content_type.nil? header_params['Content-Type'] = content_type end # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] || @api_client.object_to_http_body(finalize_price_plan_request) # return_type return_type = opts[:debug_return_type] || 'BaseSuccessResponse' # auth_names auth_names = opts[:debug_auth_names] || ['bearerAuth'] = opts.merge( :operation => :"PricePlanV2Api.finalize_price_plan", :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:POST, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: PricePlanV2Api#finalize_price_plan\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#get_price_plan_v2(price_plan_id, opts = {}) ⇒ PricePlanV2
Get a price plan Get a price plan
326 327 328 329 |
# File 'lib/togai_client/api/price_plan_v2_api.rb', line 326 def get_price_plan_v2(price_plan_id, opts = {}) data, _status_code, _headers = get_price_plan_v2_with_http_info(price_plan_id, opts) data end |
#get_price_plan_v2_with_http_info(price_plan_id, opts = {}) ⇒ Array<(PricePlanV2, Integer, Hash)>
Get a price plan Get a price plan
337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 |
# File 'lib/togai_client/api/price_plan_v2_api.rb', line 337 def get_price_plan_v2_with_http_info(price_plan_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: PricePlanV2Api.get_price_plan_v2 ...' end # verify the required parameter 'price_plan_id' is set if @api_client.config.client_side_validation && price_plan_id.nil? fail ArgumentError, "Missing the required parameter 'price_plan_id' when calling PricePlanV2Api.get_price_plan_v2" end if @api_client.config.client_side_validation && price_plan_id.to_s.length > 50 fail ArgumentError, 'invalid value for "price_plan_id" when calling PricePlanV2Api.get_price_plan_v2, the character length must be smaller than or equal to 50.' end # resource path local_var_path = '/v2/price_plans/{price_plan_id}'.sub('{' + 'price_plan_id' + '}', CGI.escape(price_plan_id.to_s)) # query parameters query_params = opts[:query_params] || {} query_params[:'version'] = opts[:'version'] if !opts[:'version'].nil? # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept'] # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] || 'PricePlanV2' # auth_names auth_names = opts[:debug_auth_names] || ['bearerAuth'] = opts.merge( :operation => :"PricePlanV2Api.get_price_plan_v2", :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:GET, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: PricePlanV2Api#get_price_plan_v2\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#list_price_plan_errors(price_plan_id, opts = {}) ⇒ ValidatedEntityErrorsPaginatedResponse
Get list of errors of a price plan Get list of errors of a price plan
395 396 397 398 |
# File 'lib/togai_client/api/price_plan_v2_api.rb', line 395 def list_price_plan_errors(price_plan_id, opts = {}) data, _status_code, _headers = list_price_plan_errors_with_http_info(price_plan_id, opts) data end |
#list_price_plan_errors_with_http_info(price_plan_id, opts = {}) ⇒ Array<(ValidatedEntityErrorsPaginatedResponse, Integer, Hash)>
Get list of errors of a price plan Get list of errors of a price plan
405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 |
# File 'lib/togai_client/api/price_plan_v2_api.rb', line 405 def list_price_plan_errors_with_http_info(price_plan_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: PricePlanV2Api.list_price_plan_errors ...' end # verify the required parameter 'price_plan_id' is set if @api_client.config.client_side_validation && price_plan_id.nil? fail ArgumentError, "Missing the required parameter 'price_plan_id' when calling PricePlanV2Api.list_price_plan_errors" end if @api_client.config.client_side_validation && price_plan_id.to_s.length > 50 fail ArgumentError, 'invalid value for "price_plan_id" when calling PricePlanV2Api.list_price_plan_errors, the character length must be smaller than or equal to 50.' end # resource path local_var_path = '/v2/price_plans/{price_plan_id}/errors'.sub('{' + 'price_plan_id' + '}', CGI.escape(price_plan_id.to_s)) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept'] # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] || 'ValidatedEntityErrorsPaginatedResponse' # auth_names auth_names = opts[:debug_auth_names] || ['bearerAuth'] = opts.merge( :operation => :"PricePlanV2Api.list_price_plan_errors", :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:GET, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: PricePlanV2Api#list_price_plan_errors\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#list_price_plan_pricing_rules(price_plan_id, opts = {}) ⇒ PricingRulesPaginatedResponse
List pricing rules of a price plan List pricing rules of a price plan
463 464 465 466 |
# File 'lib/togai_client/api/price_plan_v2_api.rb', line 463 def list_price_plan_pricing_rules(price_plan_id, opts = {}) data, _status_code, _headers = list_price_plan_pricing_rules_with_http_info(price_plan_id, opts) data end |
#list_price_plan_pricing_rules_with_http_info(price_plan_id, opts = {}) ⇒ Array<(PricingRulesPaginatedResponse, Integer, Hash)>
List pricing rules of a price plan List pricing rules of a price plan
474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 |
# File 'lib/togai_client/api/price_plan_v2_api.rb', line 474 def list_price_plan_pricing_rules_with_http_info(price_plan_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: PricePlanV2Api.list_price_plan_pricing_rules ...' end # verify the required parameter 'price_plan_id' is set if @api_client.config.client_side_validation && price_plan_id.nil? fail ArgumentError, "Missing the required parameter 'price_plan_id' when calling PricePlanV2Api.list_price_plan_pricing_rules" end if @api_client.config.client_side_validation && price_plan_id.to_s.length > 50 fail ArgumentError, 'invalid value for "price_plan_id" when calling PricePlanV2Api.list_price_plan_pricing_rules, the character length must be smaller than or equal to 50.' end # resource path local_var_path = '/v2/price_plans/{price_plan_id}/pricing_rules'.sub('{' + 'price_plan_id' + '}', CGI.escape(price_plan_id.to_s)) # query parameters query_params = opts[:query_params] || {} query_params[:'version'] = opts[:'version'] if !opts[:'version'].nil? # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept'] # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] || 'PricingRulesPaginatedResponse' # auth_names auth_names = opts[:debug_auth_names] || ['bearerAuth'] = opts.merge( :operation => :"PricePlanV2Api.list_price_plan_pricing_rules", :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:GET, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: PricePlanV2Api#list_price_plan_pricing_rules\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#list_price_plan_rate_cards(price_plan_id, opts = {}) ⇒ RateCardPaginatedResponse
List rate cards of a price plan List rate cards of a price plan
534 535 536 537 |
# File 'lib/togai_client/api/price_plan_v2_api.rb', line 534 def list_price_plan_rate_cards(price_plan_id, opts = {}) data, _status_code, _headers = list_price_plan_rate_cards_with_http_info(price_plan_id, opts) data end |
#list_price_plan_rate_cards_with_http_info(price_plan_id, opts = {}) ⇒ Array<(RateCardPaginatedResponse, Integer, Hash)>
List rate cards of a price plan List rate cards of a price plan
546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 |
# File 'lib/togai_client/api/price_plan_v2_api.rb', line 546 def list_price_plan_rate_cards_with_http_info(price_plan_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: PricePlanV2Api.list_price_plan_rate_cards ...' end # verify the required parameter 'price_plan_id' is set if @api_client.config.client_side_validation && price_plan_id.nil? fail ArgumentError, "Missing the required parameter 'price_plan_id' when calling PricePlanV2Api.list_price_plan_rate_cards" end if @api_client.config.client_side_validation && price_plan_id.to_s.length > 50 fail ArgumentError, 'invalid value for "price_plan_id" when calling PricePlanV2Api.list_price_plan_rate_cards, the character length must be smaller than or equal to 50.' end # resource path local_var_path = '/v2/price_plans/{price_plan_id}/rate_cards'.sub('{' + 'price_plan_id' + '}', CGI.escape(price_plan_id.to_s)) # query parameters query_params = opts[:query_params] || {} query_params[:'nextToken'] = opts[:'next_token'] if !opts[:'next_token'].nil? query_params[:'pageSize'] = opts[:'page_size'] if !opts[:'page_size'].nil? # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept'] # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] || 'RateCardPaginatedResponse' # auth_names auth_names = opts[:debug_auth_names] || ['bearerAuth'] = opts.merge( :operation => :"PricePlanV2Api.list_price_plan_rate_cards", :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:GET, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: PricePlanV2Api#list_price_plan_rate_cards\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#list_price_plan_versions(price_plan_id, opts = {}) ⇒ PricePlanV2PaginatedResponse
List price plan versions List price plan versions
607 608 609 610 |
# File 'lib/togai_client/api/price_plan_v2_api.rb', line 607 def list_price_plan_versions(price_plan_id, opts = {}) data, _status_code, _headers = list_price_plan_versions_with_http_info(price_plan_id, opts) data end |
#list_price_plan_versions_with_http_info(price_plan_id, opts = {}) ⇒ Array<(PricePlanV2PaginatedResponse, Integer, Hash)>
List price plan versions List price plan versions
619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 |
# File 'lib/togai_client/api/price_plan_v2_api.rb', line 619 def list_price_plan_versions_with_http_info(price_plan_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: PricePlanV2Api.list_price_plan_versions ...' end # verify the required parameter 'price_plan_id' is set if @api_client.config.client_side_validation && price_plan_id.nil? fail ArgumentError, "Missing the required parameter 'price_plan_id' when calling PricePlanV2Api.list_price_plan_versions" end if @api_client.config.client_side_validation && price_plan_id.to_s.length > 50 fail ArgumentError, 'invalid value for "price_plan_id" when calling PricePlanV2Api.list_price_plan_versions, the character length must be smaller than or equal to 50.' end # resource path local_var_path = '/v2/price_plans/{price_plan_id}/versions'.sub('{' + 'price_plan_id' + '}', CGI.escape(price_plan_id.to_s)) # query parameters query_params = opts[:query_params] || {} query_params[:'nextToken'] = opts[:'next_token'] if !opts[:'next_token'].nil? query_params[:'pageSize'] = opts[:'page_size'] if !opts[:'page_size'].nil? # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept'] # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] || 'PricePlanV2PaginatedResponse' # auth_names auth_names = opts[:debug_auth_names] || ['bearerAuth'] = opts.merge( :operation => :"PricePlanV2Api.list_price_plan_versions", :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:GET, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: PricePlanV2Api#list_price_plan_versions\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#list_price_plans_v2(opts = {}) ⇒ PricePlanV2PaginatedResponse
List price plans List price plans
679 680 681 682 |
# File 'lib/togai_client/api/price_plan_v2_api.rb', line 679 def list_price_plans_v2(opts = {}) data, _status_code, _headers = list_price_plans_v2_with_http_info(opts) data end |
#list_price_plans_v2_with_http_info(opts = {}) ⇒ Array<(PricePlanV2PaginatedResponse, Integer, Hash)>
List price plans List price plans
690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 |
# File 'lib/togai_client/api/price_plan_v2_api.rb', line 690 def list_price_plans_v2_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: PricePlanV2Api.list_price_plans_v2 ...' end # resource path local_var_path = '/v2/price_plans' # query parameters query_params = opts[:query_params] || {} query_params[:'nextToken'] = opts[:'next_token'] if !opts[:'next_token'].nil? query_params[:'pageSize'] = opts[:'page_size'] if !opts[:'page_size'].nil? # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept'] # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] || 'PricePlanV2PaginatedResponse' # auth_names auth_names = opts[:debug_auth_names] || ['bearerAuth'] = opts.merge( :operation => :"PricePlanV2Api.list_price_plans_v2", :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:GET, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: PricePlanV2Api#list_price_plans_v2\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#price_plan_migration_v2(create_price_plan_migration_request, opts = {}) ⇒ BaseSuccessResponse
Create a price plan v2 migration Migrates accounts across price plans. This is an asynchronous process functioning on top of Togai’s Jobs framework. Status of the created migrations can be obtained using the [Jobs APIs](docs.togai.com/api-reference/jobs/get-the-status-of-a-job)
741 742 743 744 |
# File 'lib/togai_client/api/price_plan_v2_api.rb', line 741 def price_plan_migration_v2(create_price_plan_migration_request, opts = {}) data, _status_code, _headers = price_plan_migration_v2_with_http_info(create_price_plan_migration_request, opts) data end |
#price_plan_migration_v2_with_http_info(create_price_plan_migration_request, opts = {}) ⇒ Array<(BaseSuccessResponse, Integer, Hash)>
Create a price plan v2 migration Migrates accounts across price plans. This is an asynchronous process functioning on top of Togai's Jobs framework. Status of the created migrations can be obtained using the [Jobs APIs](docs.togai.com/api-reference/jobs/get-the-status-of-a-job)
751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 798 799 800 801 802 |
# File 'lib/togai_client/api/price_plan_v2_api.rb', line 751 def price_plan_migration_v2_with_http_info(create_price_plan_migration_request, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: PricePlanV2Api.price_plan_migration_v2 ...' end # verify the required parameter 'create_price_plan_migration_request' is set if @api_client.config.client_side_validation && create_price_plan_migration_request.nil? fail ArgumentError, "Missing the required parameter 'create_price_plan_migration_request' when calling PricePlanV2Api.price_plan_migration_v2" end # resource path local_var_path = '/v2/price_plans/migration' # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept'] # HTTP header 'Content-Type' content_type = @api_client.select_header_content_type(['application/json']) if !content_type.nil? header_params['Content-Type'] = content_type end # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] || @api_client.object_to_http_body(create_price_plan_migration_request) # return_type return_type = opts[:debug_return_type] || 'BaseSuccessResponse' # auth_names auth_names = opts[:debug_auth_names] || ['bearerAuth'] = opts.merge( :operation => :"PricePlanV2Api.price_plan_migration_v2", :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:POST, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: PricePlanV2Api#price_plan_migration_v2\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#update_price_plan_pricing_rules(price_plan_id, update_pricing_rules_request, opts = {}) ⇒ PricingRulesPaginatedResponse
Update pricing rules of a price plan Update pricing rules of a price plan
810 811 812 813 |
# File 'lib/togai_client/api/price_plan_v2_api.rb', line 810 def update_price_plan_pricing_rules(price_plan_id, update_pricing_rules_request, opts = {}) data, _status_code, _headers = update_price_plan_pricing_rules_with_http_info(price_plan_id, update_pricing_rules_request, opts) data end |
#update_price_plan_pricing_rules_with_http_info(price_plan_id, update_pricing_rules_request, opts = {}) ⇒ Array<(PricingRulesPaginatedResponse, Integer, Hash)>
Update pricing rules of a price plan Update pricing rules of a price plan
821 822 823 824 825 826 827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 |
# File 'lib/togai_client/api/price_plan_v2_api.rb', line 821 def update_price_plan_pricing_rules_with_http_info(price_plan_id, update_pricing_rules_request, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: PricePlanV2Api.update_price_plan_pricing_rules ...' end # verify the required parameter 'price_plan_id' is set if @api_client.config.client_side_validation && price_plan_id.nil? fail ArgumentError, "Missing the required parameter 'price_plan_id' when calling PricePlanV2Api.update_price_plan_pricing_rules" end if @api_client.config.client_side_validation && price_plan_id.to_s.length > 50 fail ArgumentError, 'invalid value for "price_plan_id" when calling PricePlanV2Api.update_price_plan_pricing_rules, the character length must be smaller than or equal to 50.' end # verify the required parameter 'update_pricing_rules_request' is set if @api_client.config.client_side_validation && update_pricing_rules_request.nil? fail ArgumentError, "Missing the required parameter 'update_pricing_rules_request' when calling PricePlanV2Api.update_price_plan_pricing_rules" end # resource path local_var_path = '/v2/price_plans/{price_plan_id}/pricing_rules'.sub('{' + 'price_plan_id' + '}', CGI.escape(price_plan_id.to_s)) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept'] # HTTP header 'Content-Type' content_type = @api_client.select_header_content_type(['application/json']) if !content_type.nil? header_params['Content-Type'] = content_type end # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] || @api_client.object_to_http_body(update_pricing_rules_request) # return_type return_type = opts[:debug_return_type] || 'PricingRulesPaginatedResponse' # auth_names auth_names = opts[:debug_auth_names] || ['bearerAuth'] = opts.merge( :operation => :"PricePlanV2Api.update_price_plan_pricing_rules", :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:PUT, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: PricePlanV2Api#update_price_plan_pricing_rules\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#update_price_plan_v2(price_plan_id, update_price_plan_v2_request, opts = {}) ⇒ PricePlanV2
Update a price plan Update a price plan
888 889 890 891 |
# File 'lib/togai_client/api/price_plan_v2_api.rb', line 888 def update_price_plan_v2(price_plan_id, update_price_plan_v2_request, opts = {}) data, _status_code, _headers = update_price_plan_v2_with_http_info(price_plan_id, update_price_plan_v2_request, opts) data end |
#update_price_plan_v2_with_http_info(price_plan_id, update_price_plan_v2_request, opts = {}) ⇒ Array<(PricePlanV2, Integer, Hash)>
Update a price plan Update a price plan
899 900 901 902 903 904 905 906 907 908 909 910 911 912 913 914 915 916 917 918 919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941 942 943 944 945 946 947 948 949 950 951 952 953 954 955 956 957 958 |
# File 'lib/togai_client/api/price_plan_v2_api.rb', line 899 def update_price_plan_v2_with_http_info(price_plan_id, update_price_plan_v2_request, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: PricePlanV2Api.update_price_plan_v2 ...' end # verify the required parameter 'price_plan_id' is set if @api_client.config.client_side_validation && price_plan_id.nil? fail ArgumentError, "Missing the required parameter 'price_plan_id' when calling PricePlanV2Api.update_price_plan_v2" end if @api_client.config.client_side_validation && price_plan_id.to_s.length > 50 fail ArgumentError, 'invalid value for "price_plan_id" when calling PricePlanV2Api.update_price_plan_v2, the character length must be smaller than or equal to 50.' end # verify the required parameter 'update_price_plan_v2_request' is set if @api_client.config.client_side_validation && update_price_plan_v2_request.nil? fail ArgumentError, "Missing the required parameter 'update_price_plan_v2_request' when calling PricePlanV2Api.update_price_plan_v2" end # resource path local_var_path = '/v2/price_plans/{price_plan_id}'.sub('{' + 'price_plan_id' + '}', CGI.escape(price_plan_id.to_s)) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept'] # HTTP header 'Content-Type' content_type = @api_client.select_header_content_type(['application/json']) if !content_type.nil? header_params['Content-Type'] = content_type end # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] || @api_client.object_to_http_body(update_price_plan_v2_request) # return_type return_type = opts[:debug_return_type] || 'PricePlanV2' # auth_names auth_names = opts[:debug_auth_names] || ['bearerAuth'] = opts.merge( :operation => :"PricePlanV2Api.update_price_plan_v2", :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:PATCH, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: PricePlanV2Api#update_price_plan_v2\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |