Class: VoucherifySdk::PromotionsApi
- Inherits:
-
Object
- Object
- VoucherifySdk::PromotionsApi
- Defined in:
- lib/VoucherifySdk/api/promotions_api.rb
Instance Attribute Summary collapse
-
#api_client ⇒ Object
Returns the value of attribute api_client.
Instance Method Summary collapse
-
#add_promotion_tier_to_campaign(campaign_id, opts = {}) ⇒ PromotionsTiersCreateResponseBody
Add Promotion Tier to Campaign This method allows you to add a new promotion tier to an existing campaign.
-
#create_promotion_stack(campaign_id, opts = {}) ⇒ PromotionsStacksCreateResponseBody
Create Promotion Stack This method creates one promotion stack.
-
#delete_promotion_stack(campaign_id, stack_id, opts = {}) ⇒ nil
Delete Promotion Stack This method deletes a promotion stack.
-
#delete_promotion_tier(promotion_tier_id, opts = {}) ⇒ nil
Delete Promotion Tier This method deletes a promotion tier.
-
#disable_promotion_tier(promotion_tier_id, opts = {}) ⇒ PromotionsTiersDisableResponseBody
Disable Promotion Tier This method disables a promotion tier, i.e.
-
#enable_promotion_tier(promotion_tier_id, opts = {}) ⇒ PromotionsTiersEnableResponseBody
Enable Promotion Tier This method enables a promotion tier, i.e.
-
#get_promotion_stack(campaign_id, stack_id, opts = {}) ⇒ PromotionsStacksGetResponseBody
Get Promotion Stack This method returns the details of a promotion stack, including the promotion tiers grouped within the stack.
-
#get_promotion_tier(promotion_tier_id, opts = {}) ⇒ PromotionsTiersGetResponseBody
Get Promotion Tier This method enables you to retrieve a specific promotion tier.
-
#initialize(api_client = ApiClient.default) ⇒ PromotionsApi
constructor
A new instance of PromotionsApi.
-
#list_all_promotion_stacks(opts = {}) ⇒ PromotionsStacksListResponseBody
List Promotion Stacks This method enables you to list promotion stacks irrespective of the campaign they are associated with.
-
#list_promotion_stacks_in_campaign(campaign_id, opts = {}) ⇒ PromotionsStacksListResponseBody
List Promotion Stacks in Campaign This method enables you to list promotion stacks from a specified campaign.
-
#list_promotion_tiers(opts = {}) ⇒ PromotionsTiersListResponseBody
List Promotion Tiers This method enables you to list promotion tiers.
-
#list_promotion_tiers_from_campaign(campaign_id, opts = {}) ⇒ PromotionsTiersListResponseBody
List Promotion Tiers from Campaign This method enables you to list promotion tiers from a specified campaign.
-
#update_promotion_stack(campaign_id, stack_id, opts = {}) ⇒ PromotionsStacksUpdateResponseBody
Update Promotion Stack This methods allows for editing an existing stack.
-
#update_promotion_tier(promotion_tier_id, opts = {}) ⇒ PromotionsTiersUpdateResponseBody
Update Promotion Tier This method updates a promotion tier.
Constructor Details
#initialize(api_client = ApiClient.default) ⇒ PromotionsApi
Returns a new instance of PromotionsApi.
19 20 21 |
# File 'lib/VoucherifySdk/api/promotions_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/VoucherifySdk/api/promotions_api.rb', line 17 def api_client @api_client end |
Instance Method Details
#add_promotion_tier_to_campaign(campaign_id, opts = {}) ⇒ PromotionsTiersCreateResponseBody
Add Promotion Tier to Campaign This method allows you to add a new promotion tier to an existing campaign. The tier hierarchy will be set as the next consequtive integer following the lowest ranking tier.
28 29 30 31 |
# File 'lib/VoucherifySdk/api/promotions_api.rb', line 28 def add_promotion_tier_to_campaign(campaign_id, opts = {}) data, _status_code, _headers = add_promotion_tier_to_campaign_with_http_info(campaign_id, opts) data end |
#create_promotion_stack(campaign_id, opts = {}) ⇒ PromotionsStacksCreateResponseBody
Create Promotion Stack This method creates one promotion stack. The sequence of promotion tier IDs will determine the promotion stacking order.
94 95 96 97 |
# File 'lib/VoucherifySdk/api/promotions_api.rb', line 94 def create_promotion_stack(campaign_id, opts = {}) data, _status_code, _headers = create_promotion_stack_with_http_info(campaign_id, opts) data end |
#delete_promotion_stack(campaign_id, stack_id, opts = {}) ⇒ nil
Delete Promotion Stack This method deletes a promotion stack.
160 161 162 163 |
# File 'lib/VoucherifySdk/api/promotions_api.rb', line 160 def delete_promotion_stack(campaign_id, stack_id, opts = {}) delete_promotion_stack_with_http_info(campaign_id, stack_id, opts) nil end |
#delete_promotion_tier(promotion_tier_id, opts = {}) ⇒ nil
Delete Promotion Tier This method deletes a promotion tier.
218 219 220 221 |
# File 'lib/VoucherifySdk/api/promotions_api.rb', line 218 def delete_promotion_tier(promotion_tier_id, opts = {}) delete_promotion_tier_with_http_info(promotion_tier_id, opts) nil end |
#disable_promotion_tier(promotion_tier_id, opts = {}) ⇒ PromotionsTiersDisableResponseBody
Disable Promotion Tier This method disables a promotion tier, i.e. makes the active parameter false.
275 276 277 278 |
# File 'lib/VoucherifySdk/api/promotions_api.rb', line 275 def disable_promotion_tier(promotion_tier_id, opts = {}) data, _status_code, _headers = disable_promotion_tier_with_http_info(promotion_tier_id, opts) data end |
#enable_promotion_tier(promotion_tier_id, opts = {}) ⇒ PromotionsTiersEnableResponseBody
Enable Promotion Tier This method enables a promotion tier, i.e. makes the active parameter true.
334 335 336 337 |
# File 'lib/VoucherifySdk/api/promotions_api.rb', line 334 def enable_promotion_tier(promotion_tier_id, opts = {}) data, _status_code, _headers = enable_promotion_tier_with_http_info(promotion_tier_id, opts) data end |
#get_promotion_stack(campaign_id, stack_id, opts = {}) ⇒ PromotionsStacksGetResponseBody
Get Promotion Stack This method returns the details of a promotion stack, including the promotion tiers grouped within the stack.
394 395 396 397 |
# File 'lib/VoucherifySdk/api/promotions_api.rb', line 394 def get_promotion_stack(campaign_id, stack_id, opts = {}) data, _status_code, _headers = get_promotion_stack_with_http_info(campaign_id, stack_id, opts) data end |
#get_promotion_tier(promotion_tier_id, opts = {}) ⇒ PromotionsTiersGetResponseBody
Get Promotion Tier This method enables you to retrieve a specific promotion tier.
454 455 456 457 |
# File 'lib/VoucherifySdk/api/promotions_api.rb', line 454 def get_promotion_tier(promotion_tier_id, opts = {}) data, _status_code, _headers = get_promotion_tier_with_http_info(promotion_tier_id, opts) data end |
#list_all_promotion_stacks(opts = {}) ⇒ PromotionsStacksListResponseBody
List Promotion Stacks This method enables you to list promotion stacks irrespective of the campaign they are associated with. You can use filters in the query parameters to specify the stacks to be returned in the response. # Advanced filters for fetching promotion stacks
517 518 519 520 |
# File 'lib/VoucherifySdk/api/promotions_api.rb', line 517 def list_all_promotion_stacks(opts = {}) data, _status_code, _headers = list_all_promotion_stacks_with_http_info(opts) data end |
#list_promotion_stacks_in_campaign(campaign_id, opts = {}) ⇒ PromotionsStacksListResponseBody
List Promotion Stacks in Campaign This method enables you to list promotion stacks from a specified campaign.
585 586 587 588 |
# File 'lib/VoucherifySdk/api/promotions_api.rb', line 585 def list_promotion_stacks_in_campaign(campaign_id, opts = {}) data, _status_code, _headers = list_promotion_stacks_in_campaign_with_http_info(campaign_id, opts) data end |
#list_promotion_tiers(opts = {}) ⇒ PromotionsTiersListResponseBody
List Promotion Tiers This method enables you to list promotion tiers.
647 648 649 650 |
# File 'lib/VoucherifySdk/api/promotions_api.rb', line 647 def list_promotion_tiers(opts = {}) data, _status_code, _headers = list_promotion_tiers_with_http_info(opts) data end |
#list_promotion_tiers_from_campaign(campaign_id, opts = {}) ⇒ PromotionsTiersListResponseBody
List Promotion Tiers from Campaign This method enables you to list promotion tiers from a specified campaign.
713 714 715 716 |
# File 'lib/VoucherifySdk/api/promotions_api.rb', line 713 def list_promotion_tiers_from_campaign(campaign_id, opts = {}) data, _status_code, _headers = list_promotion_tiers_from_campaign_with_http_info(campaign_id, opts) data end |
#update_promotion_stack(campaign_id, stack_id, opts = {}) ⇒ PromotionsStacksUpdateResponseBody
Update Promotion Stack This methods allows for editing an existing stack.
774 775 776 777 |
# File 'lib/VoucherifySdk/api/promotions_api.rb', line 774 def update_promotion_stack(campaign_id, stack_id, opts = {}) data, _status_code, _headers = update_promotion_stack_with_http_info(campaign_id, stack_id, opts) data end |
#update_promotion_tier(promotion_tier_id, opts = {}) ⇒ PromotionsTiersUpdateResponseBody
Update Promotion Tier This method updates a promotion tier.
841 842 843 844 |
# File 'lib/VoucherifySdk/api/promotions_api.rb', line 841 def update_promotion_tier(promotion_tier_id, opts = {}) data, _status_code, _headers = update_promotion_tier_with_http_info(promotion_tier_id, opts) data end |