talon_one_sdk 26.12.0 → 26.13.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.
- checksums.yaml +4 -4
- data/README.md +17 -3
- data/docs/BaseBlock.md +22 -0
- data/docs/BestPriorPrice.md +1 -1
- data/docs/BestPriorPriceRequest.md +1 -1
- data/docs/CustomerAchievement.md +38 -0
- data/docs/IntegrationApi.md +85 -8
- data/docs/IntegrationCampaign.md +5 -1
- data/docs/IntegrationEventV2Response.md +2 -0
- data/docs/IntegrationEventV3Response.md +2 -0
- data/docs/IntegrationHubEventPayloadLoyaltyProfileBasedPointsChangedNotification.md +2 -0
- data/docs/IntegrationResponse.md +3 -1
- data/docs/IntegrationStateV2.md +2 -0
- data/docs/ManagementApi.md +84 -2
- data/docs/PassthroughBlock.md +22 -0
- data/docs/PriceHistoryRequest.md +1 -1
- data/docs/PriceHistoryResponse.md +1 -1
- data/docs/PromotionGroupBlock.md +30 -0
- data/docs/PromotionRuleV2.md +26 -0
- data/docs/Reward.md +2 -2
- data/docs/Risk.md +46 -0
- data/docs/RiskAffectedEntityItem.md +26 -0
- data/docs/RiskDetail.md +48 -0
- data/docs/RuleV2.md +24 -0
- data/docs/RulesetV2.md +38 -0
- data/docs/StrikethroughGroupBlock.md +30 -0
- data/docs/StrikethroughRuleV2.md +26 -0
- data/docs/UpdateReward.md +2 -2
- data/lib/talon_one_sdk/api/integration_api.rb +81 -6
- data/lib/talon_one_sdk/api/management_api.rb +84 -0
- data/lib/talon_one_sdk/models/base_block.rb +205 -0
- data/lib/talon_one_sdk/models/customer_achievement.rb +439 -0
- data/lib/talon_one_sdk/models/integration_campaign.rb +28 -4
- data/lib/talon_one_sdk/models/integration_event_v2_response.rb +13 -1
- data/lib/talon_one_sdk/models/integration_event_v3_response.rb +13 -1
- data/lib/talon_one_sdk/models/integration_hub_event_payload_loyalty_profile_based_points_changed_notification.rb +11 -1
- data/lib/talon_one_sdk/models/integration_response.rb +16 -4
- data/lib/talon_one_sdk/models/integration_state_v2.rb +13 -1
- data/lib/talon_one_sdk/models/passthrough_block.rb +246 -0
- data/lib/talon_one_sdk/models/promotion_group_block.rb +315 -0
- data/lib/talon_one_sdk/models/promotion_rule_v2.rb +231 -0
- data/lib/talon_one_sdk/models/reward.rb +7 -7
- data/lib/talon_one_sdk/models/risk.rb +549 -0
- data/lib/talon_one_sdk/models/risk_affected_entity_item.rb +298 -0
- data/lib/talon_one_sdk/models/risk_detail.rb +578 -0
- data/lib/talon_one_sdk/models/rule_v2.rb +196 -0
- data/lib/talon_one_sdk/models/ruleset_v2.rb +344 -0
- data/lib/talon_one_sdk/models/strikethrough_group_block.rb +315 -0
- data/lib/talon_one_sdk/models/strikethrough_rule_v2.rb +231 -0
- data/lib/talon_one_sdk/models/update_reward.rb +7 -7
- data/lib/talon_one_sdk/version.rb +1 -1
- data/lib/talon_one_sdk.rb +12 -0
- data/spec/api/integration_api_spec.rb +18 -3
- data/spec/api/management_api_spec.rb +17 -0
- data/spec/models/base_block_spec.rb +48 -0
- data/spec/models/customer_achievement_spec.rb +104 -0
- data/spec/models/customer_profile_integration_request_v2_spec.rb +1 -1
- data/spec/models/integration_campaign_spec.rb +12 -0
- data/spec/models/integration_event_v2_request_spec.rb +1 -1
- data/spec/models/integration_event_v2_response_spec.rb +6 -0
- data/spec/models/integration_event_v3_response_spec.rb +6 -0
- data/spec/models/integration_hub_event_payload_loyalty_profile_based_points_changed_notification_spec.rb +6 -0
- data/spec/models/integration_request_spec.rb +1 -1
- data/spec/models/integration_response_spec.rb +6 -0
- data/spec/models/integration_state_v2_spec.rb +6 -0
- data/spec/models/passthrough_block_spec.rb +52 -0
- data/spec/models/promotion_group_block_spec.rb +76 -0
- data/spec/models/promotion_rule_v2_spec.rb +60 -0
- data/spec/models/response_content_object_spec.rb +1 -1
- data/spec/models/reward_spec.rb +1 -1
- data/spec/models/risk_affected_entity_item_spec.rb +64 -0
- data/spec/models/risk_detail_spec.rb +146 -0
- data/spec/models/risk_spec.rb +140 -0
- data/spec/models/rule_v2_spec.rb +54 -0
- data/spec/models/ruleset_v2_spec.rb +96 -0
- data/spec/models/strikethrough_group_block_spec.rb +76 -0
- data/spec/models/strikethrough_rule_v2_spec.rb +60 -0
- data/spec/models/update_reward_spec.rb +1 -1
- metadata +49 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 7fad47556b4439eabc099ba7420990dbad99b8e80d14fe0fe04afb4656f096b3
|
|
4
|
+
data.tar.gz: 0b9d93b7eaac5ff520130dbfa8a0aa87099fad11e391d7446731ba28d2d6b347
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 55dcc9708589a1fce5b9120422b6b175e55eaaae69b95e3731938caa598c8cb400e18cae7a6d63d01b8f8a328a175b2c82cc56a6e1bed1d485d7be4f469332eb
|
|
7
|
+
data.tar.gz: 16abbda3f6e4fcb33848e12ee77af5d44e3175de40f30e2e80bf909764656e2f428d08b469a3b503a750d25012be4784a5c85f63e2669d87248e4f777505bcba
|
data/README.md
CHANGED
|
@@ -16,7 +16,7 @@ See our [migration guide](MIGRATION.md).
|
|
|
16
16
|
Add this to the Gemfile:
|
|
17
17
|
|
|
18
18
|
```shell
|
|
19
|
-
gem 'talon_one_sdk', '~> 26.
|
|
19
|
+
gem 'talon_one_sdk', '~> 26.13.0'
|
|
20
20
|
```
|
|
21
21
|
|
|
22
22
|
### Build a gem
|
|
@@ -32,10 +32,10 @@ gem build talon_one_sdk.gemspec
|
|
|
32
32
|
To install the gem locally:
|
|
33
33
|
|
|
34
34
|
```shell
|
|
35
|
-
gem install ./talon_one_sdk-26.
|
|
35
|
+
gem install ./talon_one_sdk-26.13.0.gem
|
|
36
36
|
```
|
|
37
37
|
|
|
38
|
-
For development, run `gem install --dev ./talon_one_sdk-26.
|
|
38
|
+
For development, run `gem install --dev ./talon_one_sdk-26.13.0.gem` to install the development dependencies.
|
|
39
39
|
|
|
40
40
|
### RubyGems
|
|
41
41
|
|
|
@@ -205,6 +205,7 @@ Class | Method | HTTP request | Description
|
|
|
205
205
|
*TalonOne::IntegrationApi* | [**get_loyalty_program_profile_transactions**](docs/IntegrationApi.md#get_loyalty_program_profile_transactions) | **GET** /v1/loyalty_programs/{loyaltyProgramId}/profile/{integrationId}/transactions | List customer's loyalty transactions
|
|
206
206
|
*TalonOne::IntegrationApi* | [**get_reserved_customers**](docs/IntegrationApi.md#get_reserved_customers) | **GET** /v1/coupon_reservations/customerprofiles/{couponValue} | List customers that have this coupon reserved
|
|
207
207
|
*TalonOne::IntegrationApi* | [**integration_get_all_campaigns**](docs/IntegrationApi.md#integration_get_all_campaigns) | **GET** /v1/integration/campaigns | List all running campaigns
|
|
208
|
+
*TalonOne::IntegrationApi* | [**join_loyalty_program**](docs/IntegrationApi.md#join_loyalty_program) | **POST** /v1/loyalty_programs/{loyaltyProgramId}/profile/{integrationId}/join | Join customer profile to loyalty program
|
|
208
209
|
*TalonOne::IntegrationApi* | [**link_loyalty_card_to_profile**](docs/IntegrationApi.md#link_loyalty_card_to_profile) | **POST** /v2/loyalty_programs/{loyaltyProgramId}/cards/{loyaltyCardId}/link_profile | Link customer profile to card
|
|
209
210
|
*TalonOne::IntegrationApi* | [**reopen_customer_session**](docs/IntegrationApi.md#reopen_customer_session) | **PUT** /v2/customer_sessions/{customerSessionId}/reopen | Reopen customer session
|
|
210
211
|
*TalonOne::IntegrationApi* | [**return_cart_items**](docs/IntegrationApi.md#return_cart_items) | **POST** /v2/customer_sessions/{customerSessionId}/returns | Return cart items
|
|
@@ -337,6 +338,7 @@ Class | Method | HTTP request | Description
|
|
|
337
338
|
*TalonOne::ManagementApi* | [**get_referrals_without_total_count**](docs/ManagementApi.md#get_referrals_without_total_count) | **GET** /v1/applications/{applicationId}/campaigns/{campaignId}/referrals/no_total | List referrals
|
|
338
339
|
*TalonOne::ManagementApi* | [**get_role_v2**](docs/ManagementApi.md#get_role_v2) | **GET** /v2/roles/{roleId} | Get role
|
|
339
340
|
*TalonOne::ManagementApi* | [**get_ruleset**](docs/ManagementApi.md#get_ruleset) | **GET** /v1/applications/{applicationId}/campaigns/{campaignId}/rulesets/{rulesetId} | Get ruleset
|
|
341
|
+
*TalonOne::ManagementApi* | [**get_ruleset_v2**](docs/ManagementApi.md#get_ruleset_v2) | **GET** /v2/applications/{applicationId}/campaigns/{campaignId}/rulesets/{rulesetId} | Get ruleset (V2)
|
|
340
342
|
*TalonOne::ManagementApi* | [**get_rulesets**](docs/ManagementApi.md#get_rulesets) | **GET** /v1/applications/{applicationId}/campaigns/{campaignId}/rulesets | List campaign rulesets
|
|
341
343
|
*TalonOne::ManagementApi* | [**get_store**](docs/ManagementApi.md#get_store) | **GET** /v1/applications/{applicationId}/stores/{storeId} | Get store
|
|
342
344
|
*TalonOne::ManagementApi* | [**get_user**](docs/ManagementApi.md#get_user) | **GET** /v1/users/{userId} | Get user
|
|
@@ -485,6 +487,7 @@ Class | Method | HTTP request | Description
|
|
|
485
487
|
- [TalonOne::AudienceMembership](docs/AudienceMembership.md)
|
|
486
488
|
- [TalonOne::AudienceReference](docs/AudienceReference.md)
|
|
487
489
|
- [TalonOne::AwardGiveawayEffectProps](docs/AwardGiveawayEffectProps.md)
|
|
490
|
+
- [TalonOne::BaseBlock](docs/BaseBlock.md)
|
|
488
491
|
- [TalonOne::BaseCampaign](docs/BaseCampaign.md)
|
|
489
492
|
- [TalonOne::BaseLoyaltyProgram](docs/BaseLoyaltyProgram.md)
|
|
490
493
|
- [TalonOne::BaseNotification](docs/BaseNotification.md)
|
|
@@ -602,6 +605,7 @@ Class | Method | HTTP request | Description
|
|
|
602
605
|
- [TalonOne::CreateTemplateCampaignResponse](docs/CreateTemplateCampaignResponse.md)
|
|
603
606
|
- [TalonOne::CustomEffect](docs/CustomEffect.md)
|
|
604
607
|
- [TalonOne::CustomEffectProps](docs/CustomEffectProps.md)
|
|
608
|
+
- [TalonOne::CustomerAchievement](docs/CustomerAchievement.md)
|
|
605
609
|
- [TalonOne::CustomerActivityReport](docs/CustomerActivityReport.md)
|
|
606
610
|
- [TalonOne::CustomerAnalytics](docs/CustomerAnalytics.md)
|
|
607
611
|
- [TalonOne::CustomerInventory](docs/CustomerInventory.md)
|
|
@@ -940,6 +944,7 @@ Class | Method | HTTP request | Description
|
|
|
940
944
|
- [TalonOne::OutgoingIntegrationTemplates](docs/OutgoingIntegrationTemplates.md)
|
|
941
945
|
- [TalonOne::OutgoingIntegrationType](docs/OutgoingIntegrationType.md)
|
|
942
946
|
- [TalonOne::OutgoingIntegrationTypes](docs/OutgoingIntegrationTypes.md)
|
|
947
|
+
- [TalonOne::PassthroughBlock](docs/PassthroughBlock.md)
|
|
943
948
|
- [TalonOne::PatchItemCatalogAction](docs/PatchItemCatalogAction.md)
|
|
944
949
|
- [TalonOne::PatchManyItemsCatalogAction](docs/PatchManyItemsCatalogAction.md)
|
|
945
950
|
- [TalonOne::PendingActivePointsData](docs/PendingActivePointsData.md)
|
|
@@ -961,6 +966,8 @@ Class | Method | HTTP request | Description
|
|
|
961
966
|
- [TalonOne::ProfileAudiencesChanges](docs/ProfileAudiencesChanges.md)
|
|
962
967
|
- [TalonOne::ProjectedTier](docs/ProjectedTier.md)
|
|
963
968
|
- [TalonOne::PromoteExperiment](docs/PromoteExperiment.md)
|
|
969
|
+
- [TalonOne::PromotionGroupBlock](docs/PromotionGroupBlock.md)
|
|
970
|
+
- [TalonOne::PromotionRuleV2](docs/PromotionRuleV2.md)
|
|
964
971
|
- [TalonOne::RedeemReferralEffectProps](docs/RedeemReferralEffectProps.md)
|
|
965
972
|
- [TalonOne::Referral](docs/Referral.md)
|
|
966
973
|
- [TalonOne::ReferralConstraints](docs/ReferralConstraints.md)
|
|
@@ -982,6 +989,9 @@ Class | Method | HTTP request | Description
|
|
|
982
989
|
- [TalonOne::RevisionVersion](docs/RevisionVersion.md)
|
|
983
990
|
- [TalonOne::Reward](docs/Reward.md)
|
|
984
991
|
- [TalonOne::RewardPointsRequired](docs/RewardPointsRequired.md)
|
|
992
|
+
- [TalonOne::Risk](docs/Risk.md)
|
|
993
|
+
- [TalonOne::RiskAffectedEntityItem](docs/RiskAffectedEntityItem.md)
|
|
994
|
+
- [TalonOne::RiskDetail](docs/RiskDetail.md)
|
|
985
995
|
- [TalonOne::RiskNotification](docs/RiskNotification.md)
|
|
986
996
|
- [TalonOne::Role](docs/Role.md)
|
|
987
997
|
- [TalonOne::RoleAssign](docs/RoleAssign.md)
|
|
@@ -1006,7 +1016,9 @@ Class | Method | HTTP request | Description
|
|
|
1006
1016
|
- [TalonOne::RuleFailureReason](docs/RuleFailureReason.md)
|
|
1007
1017
|
- [TalonOne::RuleMetadata](docs/RuleMetadata.md)
|
|
1008
1018
|
- [TalonOne::RuleMetadataEligibility](docs/RuleMetadataEligibility.md)
|
|
1019
|
+
- [TalonOne::RuleV2](docs/RuleV2.md)
|
|
1009
1020
|
- [TalonOne::Ruleset](docs/Ruleset.md)
|
|
1021
|
+
- [TalonOne::RulesetV2](docs/RulesetV2.md)
|
|
1010
1022
|
- [TalonOne::SSOConfig](docs/SSOConfig.md)
|
|
1011
1023
|
- [TalonOne::SamlConnection](docs/SamlConnection.md)
|
|
1012
1024
|
- [TalonOne::SamlConnectionInternal](docs/SamlConnectionInternal.md)
|
|
@@ -1048,7 +1060,9 @@ Class | Method | HTTP request | Description
|
|
|
1048
1060
|
- [TalonOne::StrikethroughCustomEffectPerItemProps](docs/StrikethroughCustomEffectPerItemProps.md)
|
|
1049
1061
|
- [TalonOne::StrikethroughDebugResponse](docs/StrikethroughDebugResponse.md)
|
|
1050
1062
|
- [TalonOne::StrikethroughEffect](docs/StrikethroughEffect.md)
|
|
1063
|
+
- [TalonOne::StrikethroughGroupBlock](docs/StrikethroughGroupBlock.md)
|
|
1051
1064
|
- [TalonOne::StrikethroughLabelingNotification](docs/StrikethroughLabelingNotification.md)
|
|
1065
|
+
- [TalonOne::StrikethroughRuleV2](docs/StrikethroughRuleV2.md)
|
|
1052
1066
|
- [TalonOne::StrikethroughSetDiscountPerItemEffectProps](docs/StrikethroughSetDiscountPerItemEffectProps.md)
|
|
1053
1067
|
- [TalonOne::StrikethroughSetDiscountPerItemMemberEffectProps](docs/StrikethroughSetDiscountPerItemMemberEffectProps.md)
|
|
1054
1068
|
- [TalonOne::StrikethroughTrigger](docs/StrikethroughTrigger.md)
|
data/docs/BaseBlock.md
ADDED
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
# TalonOne::BaseBlock
|
|
2
|
+
|
|
3
|
+
## Properties
|
|
4
|
+
|
|
5
|
+
| Name | Type | Description | Notes |
|
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
|
7
|
+
| **id** | **String** | Unique identifier for this block. | |
|
|
8
|
+
| **type** | **String** | Identifies the block variant and determines which additional properties are present in it. | |
|
|
9
|
+
| **tags** | **Array<String>** | Semantic labels attached to this block. | [optional] |
|
|
10
|
+
|
|
11
|
+
## Example
|
|
12
|
+
|
|
13
|
+
```ruby
|
|
14
|
+
require 'talon_one_sdk'
|
|
15
|
+
|
|
16
|
+
instance = TalonOne::BaseBlock.new(
|
|
17
|
+
id: a1b2c3d4-e5f6-7890-abcd-ef1234567890,
|
|
18
|
+
type: null,
|
|
19
|
+
tags: null
|
|
20
|
+
)
|
|
21
|
+
```
|
|
22
|
+
|
data/docs/BestPriorPrice.md
CHANGED
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
# TalonOne::CustomerAchievement
|
|
2
|
+
|
|
3
|
+
## Properties
|
|
4
|
+
|
|
5
|
+
| Name | Type | Description | Notes |
|
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
|
7
|
+
| **id** | **Integer** | The internal ID of the achievement. | |
|
|
8
|
+
| **name** | **String** | The internal name of the achievement used in API requests. | |
|
|
9
|
+
| **title** | **String** | The display name of the achievement in the Campaign Manager. | |
|
|
10
|
+
| **description** | **String** | The description of the achievement in the Campaign Manager. | |
|
|
11
|
+
| **target** | **Float** | The required number of actions or the transactional milestone to complete the achievement. | |
|
|
12
|
+
| **recurrence_policy** | **String** | The policy that determines if and how the achievement recurs. - `no_recurrence`: The achievement can be completed only once. - `on_expiration`: The achievement resets after it expires and becomes available again. - `on_completion`: When the customer progress status reaches `completed`, the achievement resets and becomes available again. | |
|
|
13
|
+
| **activation_policy** | **String** | The policy that determines how the achievement starts, ends, or resets. - `user_action`: The achievement ends or resets relative to when the customer started the achievement. - `fixed_schedule`: The achievement starts, ends, or resets for all customers following a fixed schedule. | |
|
|
14
|
+
| **fixed_start_date** | **Time** | The achievement's start date when `activationPolicy` is equal to `fixed_schedule`. **Note:** It is an RFC3339 timestamp string. | [optional] |
|
|
15
|
+
| **end_date** | **Time** | The achievement's end date. If defined, customers cannot participate in the achievement after this date. **Note:** It is an RFC3339 timestamp string. | [optional] |
|
|
16
|
+
| **allow_rollback_after_completion** | **Boolean** | When `true`, customer progress can be rolled back in completed achievements. | |
|
|
17
|
+
| **current_progress** | [**AchievementProgress**](AchievementProgress.md) | | [optional] |
|
|
18
|
+
|
|
19
|
+
## Example
|
|
20
|
+
|
|
21
|
+
```ruby
|
|
22
|
+
require 'talon_one_sdk'
|
|
23
|
+
|
|
24
|
+
instance = TalonOne::CustomerAchievement.new(
|
|
25
|
+
id: 3,
|
|
26
|
+
name: FreeCoffee10Orders,
|
|
27
|
+
title: 50% off on 50th purchase.,
|
|
28
|
+
description: 50% off for every 50th purchase in a year.,
|
|
29
|
+
target: 10,
|
|
30
|
+
recurrence_policy: no_recurrence,
|
|
31
|
+
activation_policy: fixed_schedule,
|
|
32
|
+
fixed_start_date: 2024-01-15T15:04:05Z07:00,
|
|
33
|
+
end_date: 2024-02-15T15:04:05Z07:00,
|
|
34
|
+
allow_rollback_after_completion: false,
|
|
35
|
+
current_progress: null
|
|
36
|
+
)
|
|
37
|
+
```
|
|
38
|
+
|
data/docs/IntegrationApi.md
CHANGED
|
@@ -29,6 +29,7 @@ All URIs are relative to *https://yourbaseurl.talon.one*
|
|
|
29
29
|
| [**get_loyalty_program_profile_transactions**](IntegrationApi.md#get_loyalty_program_profile_transactions) | **GET** /v1/loyalty_programs/{loyaltyProgramId}/profile/{integrationId}/transactions | List customer's loyalty transactions |
|
|
30
30
|
| [**get_reserved_customers**](IntegrationApi.md#get_reserved_customers) | **GET** /v1/coupon_reservations/customerprofiles/{couponValue} | List customers that have this coupon reserved |
|
|
31
31
|
| [**integration_get_all_campaigns**](IntegrationApi.md#integration_get_all_campaigns) | **GET** /v1/integration/campaigns | List all running campaigns |
|
|
32
|
+
| [**join_loyalty_program**](IntegrationApi.md#join_loyalty_program) | **POST** /v1/loyalty_programs/{loyaltyProgramId}/profile/{integrationId}/join | Join customer profile to loyalty program |
|
|
32
33
|
| [**link_loyalty_card_to_profile**](IntegrationApi.md#link_loyalty_card_to_profile) | **POST** /v2/loyalty_programs/{loyaltyProgramId}/cards/{loyaltyCardId}/link_profile | Link customer profile to card |
|
|
33
34
|
| [**reopen_customer_session**](IntegrationApi.md#reopen_customer_session) | **PUT** /v2/customer_sessions/{customerSessionId}/reopen | Reopen customer session |
|
|
34
35
|
| [**return_cart_items**](IntegrationApi.md#return_cart_items) | **POST** /v2/customer_sessions/{customerSessionId}/returns | Return cart items |
|
|
@@ -139,7 +140,7 @@ TalonOne.configure do |config|
|
|
|
139
140
|
end
|
|
140
141
|
|
|
141
142
|
api_instance = TalonOne::IntegrationApi.new
|
|
142
|
-
best_prior_price_request = TalonOne::BestPriorPriceRequest.new({skus: [
|
|
143
|
+
best_prior_price_request = TalonOne::BestPriorPriceRequest.new({skus: [SKU1241028, SKU7345278], timeframe_end_date: Time.parse('2020-11-10T23:00:00Z'), timeframe: '30', timeframe_end_date_type: 'strict'}) # BestPriorPriceRequest | body
|
|
143
144
|
|
|
144
145
|
begin
|
|
145
146
|
# Fetch best prior price
|
|
@@ -1184,7 +1185,7 @@ TalonOne.configure do |config|
|
|
|
1184
1185
|
end
|
|
1185
1186
|
|
|
1186
1187
|
api_instance = TalonOne::IntegrationApi.new
|
|
1187
|
-
customer_session_id = 'customer_session_id_example' # String | The `integration ID` of the customer session. You set this ID when you create a customer session. You can see existing customer session integration IDs in the Campaign Manager's **Sessions** menu, or via the [List Application session](https://docs.talon.one/management-api#tag/Customer-data/operation/getApplicationSessions) endpoint.
|
|
1188
|
+
customer_session_id = 'customer_session_id_example' # String | The `integration ID` of the customer session. You set this ID when you create a customer session. You can see existing customer session integration IDs in the Campaign Manager's **Sessions** menu, or via the [List Application session](https://docs.talon.one/management-api#tag/Customer-data/operation/getApplicationSessions) endpoint. **Notes**: - There is no length limit for this ID. - It must be URL-encoded. For example, replace spaces with `%20`. [Learn more](https://www.w3schools.com/tags/ref_urlencode.asp).
|
|
1188
1189
|
|
|
1189
1190
|
begin
|
|
1190
1191
|
# Get customer session
|
|
@@ -1217,7 +1218,7 @@ end
|
|
|
1217
1218
|
|
|
1218
1219
|
| Name | Type | Description | Notes |
|
|
1219
1220
|
| ---- | ---- | ----------- | ----- |
|
|
1220
|
-
| **customer_session_id** | **String** | The `integration ID` of the customer session. You set this ID when you create a customer session. You can see existing customer session integration IDs in the Campaign Manager's **Sessions** menu, or via the [List Application session](https://docs.talon.one/management-api#tag/Customer-data/operation/getApplicationSessions) endpoint. | |
|
|
1221
|
+
| **customer_session_id** | **String** | The `integration ID` of the customer session. You set this ID when you create a customer session. You can see existing customer session integration IDs in the Campaign Manager's **Sessions** menu, or via the [List Application session](https://docs.talon.one/management-api#tag/Customer-data/operation/getApplicationSessions) endpoint. **Notes**: - There is no length limit for this ID. - It must be URL-encoded. For example, replace spaces with `%20`. [Learn more](https://www.w3schools.com/tags/ref_urlencode.asp). | |
|
|
1221
1222
|
|
|
1222
1223
|
### Return type
|
|
1223
1224
|
|
|
@@ -1930,7 +1931,9 @@ opts = {
|
|
|
1930
1931
|
start_after: Time.parse('2013-10-20T19:20:30+01:00'), # Time | Filter results to only include campaigns that start on or after the specified timestamp. **Note:** - It must be an RFC3339 timestamp string. - You can include a time component in your string, for example, `T23:59:59` to specify the end of the day. The time zone setting considered is `UTC`. If you do not include a time component, a default time value of `T00:00:00` (midnight) in `UTC` is considered.
|
|
1931
1932
|
start_before: Time.parse('2013-10-20T19:20:30+01:00'), # Time | Filter results to only include campaigns that start on or before the specified timestamp. **Note:** - It must be an RFC3339 timestamp string. - You can include a time component in your string, for example, `T23:59:59` to specify the end of the day. The time zone setting considered is `UTC`. If you do not include a time component, a default time value of `T00:00:00` (midnight) in `UTC` is considered.
|
|
1932
1933
|
end_after: Time.parse('2013-10-20T19:20:30+01:00'), # Time | Filter results to only include campaigns that end on or after the specified timestamp. **Note:** - It must be an RFC3339 timestamp string. - You can include a time component in your string, for example, `T23:59:59` to specify the end of the day. The time zone setting considered is `UTC`. If you do not include a time component, a default time value of `T00:00:00` (midnight) in `UTC` is considered.
|
|
1933
|
-
end_before: Time.parse('2013-10-20T19:20:30+01:00') # Time | Filter results to only include campaigns that end on or before the specified timestamp. **Note:** - It must be an RFC3339 timestamp string. - You can include a time component in your string, for example, `T23:59:59` to specify the end of the day. The time zone setting considered is `UTC`. If you do not include a time component, a default time value of `T00:00:00` (midnight) in `UTC` is considered.
|
|
1934
|
+
end_before: Time.parse('2013-10-20T19:20:30+01:00'), # Time | Filter results to only include campaigns that end on or before the specified timestamp. **Note:** - It must be an RFC3339 timestamp string. - You can include a time component in your string, for example, `T23:59:59` to specify the end of the day. The time zone setting considered is `UTC`. If you do not include a time component, a default time value of `T00:00:00` (midnight) in `UTC` is considered.
|
|
1935
|
+
store_id: 789, # Integer | Filter results to campaigns linked to the specified store ID.
|
|
1936
|
+
audience_id: 789 # Integer | Filter results to campaigns linked to the specified audience ID.
|
|
1934
1937
|
}
|
|
1935
1938
|
|
|
1936
1939
|
begin
|
|
@@ -1971,6 +1974,8 @@ end
|
|
|
1971
1974
|
| **start_before** | **Time** | Filter results to only include campaigns that start on or before the specified timestamp. **Note:** - It must be an RFC3339 timestamp string. - You can include a time component in your string, for example, `T23:59:59` to specify the end of the day. The time zone setting considered is `UTC`. If you do not include a time component, a default time value of `T00:00:00` (midnight) in `UTC` is considered. | [optional] |
|
|
1972
1975
|
| **end_after** | **Time** | Filter results to only include campaigns that end on or after the specified timestamp. **Note:** - It must be an RFC3339 timestamp string. - You can include a time component in your string, for example, `T23:59:59` to specify the end of the day. The time zone setting considered is `UTC`. If you do not include a time component, a default time value of `T00:00:00` (midnight) in `UTC` is considered. | [optional] |
|
|
1973
1976
|
| **end_before** | **Time** | Filter results to only include campaigns that end on or before the specified timestamp. **Note:** - It must be an RFC3339 timestamp string. - You can include a time component in your string, for example, `T23:59:59` to specify the end of the day. The time zone setting considered is `UTC`. If you do not include a time component, a default time value of `T00:00:00` (midnight) in `UTC` is considered. | [optional] |
|
|
1977
|
+
| **store_id** | **Integer** | Filter results to campaigns linked to the specified store ID. | [optional] |
|
|
1978
|
+
| **audience_id** | **Integer** | Filter results to campaigns linked to the specified audience ID. | [optional] |
|
|
1974
1979
|
|
|
1975
1980
|
### Return type
|
|
1976
1981
|
|
|
@@ -1986,6 +1991,78 @@ end
|
|
|
1986
1991
|
- **Accept**: application/json
|
|
1987
1992
|
|
|
1988
1993
|
|
|
1994
|
+
## join_loyalty_program
|
|
1995
|
+
|
|
1996
|
+
> join_loyalty_program(loyalty_program_id, integration_id)
|
|
1997
|
+
|
|
1998
|
+
Join customer profile to loyalty program
|
|
1999
|
+
|
|
2000
|
+
Join a customer profile to the specified loyalty program. If the customer profile does not exist, it will be created first using the provided `integrationId`, then joined to the loyalty program. > [!note] This endpoint only works with profile-based loyalty programs. **Behavior**: - If the loyalty program does not exist, the request fails. - If the customer profile is already joined to the loyalty program, the request fails. - If the customer profile does not exist, it is created and then joined to the loyalty program.
|
|
2001
|
+
|
|
2002
|
+
### Examples
|
|
2003
|
+
|
|
2004
|
+
```ruby
|
|
2005
|
+
require 'time'
|
|
2006
|
+
require 'talon_one_sdk'
|
|
2007
|
+
# setup authorization
|
|
2008
|
+
TalonOne.configure do |config|
|
|
2009
|
+
# Configure API key authorization: api_key_v1
|
|
2010
|
+
config.api_key['Authorization'] = 'YOUR API KEY'
|
|
2011
|
+
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
|
|
2012
|
+
# config.api_key_prefix['Authorization'] = 'Bearer'
|
|
2013
|
+
end
|
|
2014
|
+
|
|
2015
|
+
api_instance = TalonOne::IntegrationApi.new
|
|
2016
|
+
loyalty_program_id = 789 # Integer | Identifier of the profile-based loyalty program. You can get the ID with the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) endpoint.
|
|
2017
|
+
integration_id = 'integration_id_example' # String | The integration ID of the customer profile. You can get the `integrationId` of a profile using: - A customer session integration ID with the [Update customer session](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint. - The Management API with the [List application's customers](https://docs.talon.one/management-api#tag/Customer-data/operation/getApplicationCustomers) endpoint.
|
|
2018
|
+
|
|
2019
|
+
begin
|
|
2020
|
+
# Join customer profile to loyalty program
|
|
2021
|
+
api_instance.join_loyalty_program(loyalty_program_id, integration_id)
|
|
2022
|
+
rescue TalonOne::ApiError => e
|
|
2023
|
+
puts "Error when calling IntegrationApi->join_loyalty_program: #{e}"
|
|
2024
|
+
end
|
|
2025
|
+
```
|
|
2026
|
+
|
|
2027
|
+
#### Using the join_loyalty_program_with_http_info variant
|
|
2028
|
+
|
|
2029
|
+
This returns an Array which contains the response data (`nil` in this case), status code and headers.
|
|
2030
|
+
|
|
2031
|
+
> <Array(nil, Integer, Hash)> join_loyalty_program_with_http_info(loyalty_program_id, integration_id)
|
|
2032
|
+
|
|
2033
|
+
```ruby
|
|
2034
|
+
begin
|
|
2035
|
+
# Join customer profile to loyalty program
|
|
2036
|
+
data, status_code, headers = api_instance.join_loyalty_program_with_http_info(loyalty_program_id, integration_id)
|
|
2037
|
+
p status_code # => 2xx
|
|
2038
|
+
p headers # => { ... }
|
|
2039
|
+
p data # => nil
|
|
2040
|
+
rescue TalonOne::ApiError => e
|
|
2041
|
+
puts "Error when calling IntegrationApi->join_loyalty_program_with_http_info: #{e}"
|
|
2042
|
+
end
|
|
2043
|
+
```
|
|
2044
|
+
|
|
2045
|
+
### Parameters
|
|
2046
|
+
|
|
2047
|
+
| Name | Type | Description | Notes |
|
|
2048
|
+
| ---- | ---- | ----------- | ----- |
|
|
2049
|
+
| **loyalty_program_id** | **Integer** | Identifier of the profile-based loyalty program. You can get the ID with the [List loyalty programs](https://docs.talon.one/management-api#tag/Loyalty/operation/getLoyaltyPrograms) endpoint. | |
|
|
2050
|
+
| **integration_id** | **String** | The integration ID of the customer profile. You can get the `integrationId` of a profile using: - A customer session integration ID with the [Update customer session](https://docs.talon.one/integration-api#tag/Customer-sessions/operation/updateCustomerSessionV2) endpoint. - The Management API with the [List application's customers](https://docs.talon.one/management-api#tag/Customer-data/operation/getApplicationCustomers) endpoint. | |
|
|
2051
|
+
|
|
2052
|
+
### Return type
|
|
2053
|
+
|
|
2054
|
+
nil (empty response body)
|
|
2055
|
+
|
|
2056
|
+
### Authorization
|
|
2057
|
+
|
|
2058
|
+
[api_key_v1](../README.md#api_key_v1)
|
|
2059
|
+
|
|
2060
|
+
### HTTP request headers
|
|
2061
|
+
|
|
2062
|
+
- **Content-Type**: Not defined
|
|
2063
|
+
- **Accept**: application/json
|
|
2064
|
+
|
|
2065
|
+
|
|
1989
2066
|
## link_loyalty_card_to_profile
|
|
1990
2067
|
|
|
1991
2068
|
> <LoyaltyCard> link_loyalty_card_to_profile(loyalty_program_id, loyalty_card_id, loyalty_card_registration)
|
|
@@ -2754,7 +2831,7 @@ TalonOne.configure do |config|
|
|
|
2754
2831
|
end
|
|
2755
2832
|
|
|
2756
2833
|
api_instance = TalonOne::IntegrationApi.new
|
|
2757
|
-
integration_id = 'integration_id_example' # String | The integration identifier for this customer profile. Must be: - Unique within the deployment. - Stable for the customer. Do not use an ID that the customer can update themselves. For example, you can use a database ID. Once set, you cannot update this identifier.
|
|
2834
|
+
integration_id = 'integration_id_example' # String | The integration identifier for this customer profile. Must be: - Unique within the deployment. - Stable for the customer. Do not use an ID that the customer can update themselves. For example, you can use a database ID. Once set, you cannot update this identifier. **Note**: It must be URL-encoded. For example, replace spaces with `%20`. [Learn more](https://www.w3schools.com/tags/ref_urlencode.asp).
|
|
2758
2835
|
customer_profile_integration_request_v2 = TalonOne::CustomerProfileIntegrationRequestV2.new # CustomerProfileIntegrationRequestV2 | body
|
|
2759
2836
|
opts = {
|
|
2760
2837
|
run_rule_engine: true, # Boolean | Indicates whether to run the Rule Engine. If `true`, the response includes: - The effects generated by the triggered campaigns are returned in the `effects` property. - The created coupons and referral objects. If `false`: - The rules are not executed and the `effects` property is always empty. - The response time improves. - You cannot use `responseContent` in the body.
|
|
@@ -2792,7 +2869,7 @@ end
|
|
|
2792
2869
|
|
|
2793
2870
|
| Name | Type | Description | Notes |
|
|
2794
2871
|
| ---- | ---- | ----------- | ----- |
|
|
2795
|
-
| **integration_id** | **String** | The integration identifier for this customer profile. Must be: - Unique within the deployment. - Stable for the customer. Do not use an ID that the customer can update themselves. For example, you can use a database ID. Once set, you cannot update this identifier. | |
|
|
2872
|
+
| **integration_id** | **String** | The integration identifier for this customer profile. Must be: - Unique within the deployment. - Stable for the customer. Do not use an ID that the customer can update themselves. For example, you can use a database ID. Once set, you cannot update this identifier. **Note**: It must be URL-encoded. For example, replace spaces with `%20`. [Learn more](https://www.w3schools.com/tags/ref_urlencode.asp). | |
|
|
2796
2873
|
| **customer_profile_integration_request_v2** | [**CustomerProfileIntegrationRequestV2**](CustomerProfileIntegrationRequestV2.md) | body | |
|
|
2797
2874
|
| **run_rule_engine** | **Boolean** | Indicates whether to run the Rule Engine. If `true`, the response includes: - The effects generated by the triggered campaigns are returned in the `effects` property. - The created coupons and referral objects. If `false`: - The rules are not executed and the `effects` property is always empty. - The response time improves. - You cannot use `responseContent` in the body. | [optional][default to false] |
|
|
2798
2875
|
| **dry** | **Boolean** | (Only works when `runRuleEngine=true`) Indicates whether to persist the changes. Changes are ignored when `dry=true`. When set to `true`, you can use the `evaluableCampaignIds` body property to select specific campaigns to run. | [optional] |
|
|
@@ -2908,7 +2985,7 @@ TalonOne.configure do |config|
|
|
|
2908
2985
|
end
|
|
2909
2986
|
|
|
2910
2987
|
api_instance = TalonOne::IntegrationApi.new
|
|
2911
|
-
customer_session_id = 'customer_session_id_example' # String | The `integration ID` of the customer session. You set this ID when you create a customer session. You can see existing customer session integration IDs in the Campaign Manager's **Sessions** menu, or via the [List Application session](https://docs.talon.one/management-api#tag/Customer-data/operation/getApplicationSessions) endpoint.
|
|
2988
|
+
customer_session_id = 'customer_session_id_example' # String | The `integration ID` of the customer session. You set this ID when you create a customer session. You can see existing customer session integration IDs in the Campaign Manager's **Sessions** menu, or via the [List Application session](https://docs.talon.one/management-api#tag/Customer-data/operation/getApplicationSessions) endpoint. **Notes**: - There is no length limit for this ID. - It must be URL-encoded. For example, replace spaces with `%20`. [Learn more](https://www.w3schools.com/tags/ref_urlencode.asp).
|
|
2912
2989
|
integration_request = TalonOne::IntegrationRequest.new({customer_session: TalonOne::NewCustomerSessionV2.new}) # IntegrationRequest | body
|
|
2913
2990
|
opts = {
|
|
2914
2991
|
dry: true, # Boolean | Indicates whether to persist the changes. Changes are ignored when `dry=true`. When set to `true`: - The endpoint considers **only** the payload that you pass when **closing** the session. When you do not use the `dry` parameter, the endpoint behaves as a typical PUT endpoint. Each update builds upon the previous ones. - You can use the `evaluableCampaignIds` body property to select specific campaigns to run. [See the docs](https://docs.talon.one/docs/dev/integration-api/dry-requests).
|
|
@@ -2946,7 +3023,7 @@ end
|
|
|
2946
3023
|
|
|
2947
3024
|
| Name | Type | Description | Notes |
|
|
2948
3025
|
| ---- | ---- | ----------- | ----- |
|
|
2949
|
-
| **customer_session_id** | **String** | The `integration ID` of the customer session. You set this ID when you create a customer session. You can see existing customer session integration IDs in the Campaign Manager's **Sessions** menu, or via the [List Application session](https://docs.talon.one/management-api#tag/Customer-data/operation/getApplicationSessions) endpoint. | |
|
|
3026
|
+
| **customer_session_id** | **String** | The `integration ID` of the customer session. You set this ID when you create a customer session. You can see existing customer session integration IDs in the Campaign Manager's **Sessions** menu, or via the [List Application session](https://docs.talon.one/management-api#tag/Customer-data/operation/getApplicationSessions) endpoint. **Notes**: - There is no length limit for this ID. - It must be URL-encoded. For example, replace spaces with `%20`. [Learn more](https://www.w3schools.com/tags/ref_urlencode.asp). | |
|
|
2950
3027
|
| **integration_request** | [**IntegrationRequest**](IntegrationRequest.md) | body | |
|
|
2951
3028
|
| **dry** | **Boolean** | Indicates whether to persist the changes. Changes are ignored when `dry=true`. When set to `true`: - The endpoint considers **only** the payload that you pass when **closing** the session. When you do not use the `dry` parameter, the endpoint behaves as a typical PUT endpoint. Each update builds upon the previous ones. - You can use the `evaluableCampaignIds` body property to select specific campaigns to run. [See the docs](https://docs.talon.one/docs/dev/integration-api/dry-requests). | [optional] |
|
|
2952
3029
|
| **now** | **Time** | A timestamp value of a future date that acts as a current date when included in the query. Use this parameter, for example, to test campaigns that would be evaluated for this customer session in the future (say, [scheduled campaigns](https://docs.talon.one/docs/product/campaigns/settings/managing-campaign-schedule)). > [!note] **Note** > - It must be an RFC3339 timestamp string. > - It can **only** be a date in the future. > - It can **only** be used if the `dry` parameter in the query is set to `true`. | [optional] |
|
data/docs/IntegrationCampaign.md
CHANGED
|
@@ -15,6 +15,8 @@
|
|
|
15
15
|
| **tags** | **Array<String>** | A list of tags for the campaign. | |
|
|
16
16
|
| **features** | **Array<String>** | The features enabled in this campaign. | |
|
|
17
17
|
| **rules** | [**Array<RuleMetadata>**](RuleMetadata.md) | A list of rules containing customer-facing details of the rewards defined in the campaign. | |
|
|
18
|
+
| **linked_store_ids** | **Array<Integer>** | A list of store IDs linked to this campaign. | [optional] |
|
|
19
|
+
| **linked_audience_ids** | **Array<Integer>** | A list of audience IDs linked to this campaign. | [optional] |
|
|
18
20
|
|
|
19
21
|
## Example
|
|
20
22
|
|
|
@@ -32,7 +34,9 @@ instance = TalonOne::IntegrationCampaign.new(
|
|
|
32
34
|
state: enabled,
|
|
33
35
|
tags: [summer],
|
|
34
36
|
features: [coupons, referrals],
|
|
35
|
-
rules: null
|
|
37
|
+
rules: null,
|
|
38
|
+
linked_store_ids: [1, 2],
|
|
39
|
+
linked_audience_ids: [3, 4]
|
|
36
40
|
)
|
|
37
41
|
```
|
|
38
42
|
|
|
@@ -13,6 +13,7 @@
|
|
|
13
13
|
| **created_coupons** | [**Array<Coupon>**](Coupon.md) | The coupons that were created during the event processing. | |
|
|
14
14
|
| **created_referrals** | [**Array<Referral>**](Referral.md) | The referrals that were created during the event processing. | |
|
|
15
15
|
| **awarded_giveaways** | [**Array<Giveaway>**](Giveaway.md) | The giveaways that were awarded during the event processing. | [optional] |
|
|
16
|
+
| **achievements** | [**Array<CustomerAchievement>**](CustomerAchievement.md) | The achievements progress of the customer. | [optional] |
|
|
16
17
|
| **event** | [**Event**](Event.md) | The event that was processed. | [optional] |
|
|
17
18
|
|
|
18
19
|
## Example
|
|
@@ -30,6 +31,7 @@ instance = TalonOne::IntegrationEventV2Response.new(
|
|
|
30
31
|
created_coupons: null,
|
|
31
32
|
created_referrals: null,
|
|
32
33
|
awarded_giveaways: null,
|
|
34
|
+
achievements: null,
|
|
33
35
|
event: null
|
|
34
36
|
)
|
|
35
37
|
```
|
|
@@ -13,6 +13,7 @@
|
|
|
13
13
|
| **created_coupons** | [**Array<Coupon>**](Coupon.md) | The coupons that were created during the event processing. | |
|
|
14
14
|
| **created_referrals** | [**Array<Referral>**](Referral.md) | The referrals that were created during the event processing. | |
|
|
15
15
|
| **awarded_giveaways** | [**Array<Giveaway>**](Giveaway.md) | The giveaways that were awarded during the event processing. | [optional] |
|
|
16
|
+
| **achievements** | [**Array<CustomerAchievement>**](CustomerAchievement.md) | The achievements progress of the customer. | [optional] |
|
|
16
17
|
| **advanced_event** | [**EventV3**](EventV3.md) | The advanced event that was processed. | [optional] |
|
|
17
18
|
|
|
18
19
|
## Example
|
|
@@ -30,6 +31,7 @@ instance = TalonOne::IntegrationEventV3Response.new(
|
|
|
30
31
|
created_coupons: null,
|
|
31
32
|
created_referrals: null,
|
|
32
33
|
awarded_giveaways: null,
|
|
34
|
+
achievements: null,
|
|
33
35
|
advanced_event: null
|
|
34
36
|
)
|
|
35
37
|
```
|
|
@@ -10,6 +10,7 @@
|
|
|
10
10
|
| **subledger_id** | **String** | | |
|
|
11
11
|
| **source_of_event** | **String** | | |
|
|
12
12
|
| **current_tier** | **String** | The name of the customer's current tier. | |
|
|
13
|
+
| **session_integration_id** | **String** | The integration ID of the session through which the points were earned or lost. Only set when the change results from a rule engine execution; empty otherwise. | [optional] |
|
|
13
14
|
| **employee_name** | **String** | | [optional] |
|
|
14
15
|
| **user_id** | **Integer** | | [optional] |
|
|
15
16
|
| **current_points** | **Float** | | |
|
|
@@ -28,6 +29,7 @@ instance = TalonOne::IntegrationHubEventPayloadLoyaltyProfileBasedPointsChangedN
|
|
|
28
29
|
subledger_id: null,
|
|
29
30
|
source_of_event: null,
|
|
30
31
|
current_tier: null,
|
|
32
|
+
session_integration_id: null,
|
|
31
33
|
employee_name: null,
|
|
32
34
|
user_id: null,
|
|
33
35
|
current_points: null,
|
data/docs/IntegrationResponse.md
CHANGED
|
@@ -13,6 +13,7 @@
|
|
|
13
13
|
| **created_coupons** | [**Array<Coupon>**](Coupon.md) | The coupons that were created during the event processing. | |
|
|
14
14
|
| **created_referrals** | [**Array<Referral>**](Referral.md) | The referrals that were created during the event processing. | |
|
|
15
15
|
| **awarded_giveaways** | [**Array<Giveaway>**](Giveaway.md) | The giveaways that were awarded during the event processing. | [optional] |
|
|
16
|
+
| **achievements** | [**Array<CustomerAchievement>**](CustomerAchievement.md) | The achievements progress of the customer. | [optional] |
|
|
16
17
|
|
|
17
18
|
## Example
|
|
18
19
|
|
|
@@ -28,7 +29,8 @@ instance = TalonOne::IntegrationResponse.new(
|
|
|
28
29
|
rule_failure_reasons: null,
|
|
29
30
|
created_coupons: null,
|
|
30
31
|
created_referrals: null,
|
|
31
|
-
awarded_giveaways: null
|
|
32
|
+
awarded_giveaways: null,
|
|
33
|
+
achievements: null
|
|
32
34
|
)
|
|
33
35
|
```
|
|
34
36
|
|
data/docs/IntegrationStateV2.md
CHANGED
|
@@ -13,6 +13,7 @@
|
|
|
13
13
|
| **created_coupons** | [**Array<Coupon>**](Coupon.md) | The coupons that were created during the event processing. | |
|
|
14
14
|
| **created_referrals** | [**Array<Referral>**](Referral.md) | The referrals that were created during the event processing. | |
|
|
15
15
|
| **awarded_giveaways** | [**Array<Giveaway>**](Giveaway.md) | The giveaways that were awarded during the event processing. | [optional] |
|
|
16
|
+
| **achievements** | [**Array<CustomerAchievement>**](CustomerAchievement.md) | The achievements progress of the customer. | [optional] |
|
|
16
17
|
| **referral** | [**InventoryReferral**](InventoryReferral.md) | The referral that was processed. | [optional] |
|
|
17
18
|
| **coupons** | [**Array<IntegrationCoupon>**](IntegrationCoupon.md) | The coupons that were processed. | [optional] |
|
|
18
19
|
| **event** | [**Event**](Event.md) | The event that was processed. | [optional] |
|
|
@@ -36,6 +37,7 @@ instance = TalonOne::IntegrationStateV2.new(
|
|
|
36
37
|
created_coupons: null,
|
|
37
38
|
created_referrals: null,
|
|
38
39
|
awarded_giveaways: null,
|
|
40
|
+
achievements: null,
|
|
39
41
|
referral: null,
|
|
40
42
|
coupons: null,
|
|
41
43
|
event: null,
|
data/docs/ManagementApi.md
CHANGED
|
@@ -123,6 +123,7 @@ All URIs are relative to *https://yourbaseurl.talon.one*
|
|
|
123
123
|
| [**get_referrals_without_total_count**](ManagementApi.md#get_referrals_without_total_count) | **GET** /v1/applications/{applicationId}/campaigns/{campaignId}/referrals/no_total | List referrals |
|
|
124
124
|
| [**get_role_v2**](ManagementApi.md#get_role_v2) | **GET** /v2/roles/{roleId} | Get role |
|
|
125
125
|
| [**get_ruleset**](ManagementApi.md#get_ruleset) | **GET** /v1/applications/{applicationId}/campaigns/{campaignId}/rulesets/{rulesetId} | Get ruleset |
|
|
126
|
+
| [**get_ruleset_v2**](ManagementApi.md#get_ruleset_v2) | **GET** /v2/applications/{applicationId}/campaigns/{campaignId}/rulesets/{rulesetId} | Get ruleset (V2) |
|
|
126
127
|
| [**get_rulesets**](ManagementApi.md#get_rulesets) | **GET** /v1/applications/{applicationId}/campaigns/{campaignId}/rulesets | List campaign rulesets |
|
|
127
128
|
| [**get_store**](ManagementApi.md#get_store) | **GET** /v1/applications/{applicationId}/stores/{storeId} | Get store |
|
|
128
129
|
| [**get_user**](ManagementApi.md#get_user) | **GET** /v1/users/{userId} | Get user |
|
|
@@ -3550,7 +3551,9 @@ opts = {
|
|
|
3550
3551
|
exact_match: true, # Boolean | Filter results to an exact case-insensitive matching against the coupon code.
|
|
3551
3552
|
date_format: 'excel', # String | Determines the format of dates in the export document.
|
|
3552
3553
|
campaign_state: 'enabled', # String | Filter results by the state of the campaign. - `enabled`: Campaigns that are scheduled, running (activated), or expired. - `running`: Campaigns that are running (activated). - `disabled`: Campaigns that are disabled. - `expired`: Campaigns that are expired. - `archived`: Campaigns that are archived.
|
|
3553
|
-
values_only: true # Boolean | Filter results to only return the coupon codes (`value` column) without the associated coupon data.
|
|
3554
|
+
values_only: true, # Boolean | Filter results to only return the coupon codes (`value` column) without the associated coupon data.
|
|
3555
|
+
deleted_before: Time.parse('2013-10-20T19:20:30+01:00'), # Time | Timestamp that filters the results to only contain coupons deleted before this date. Must be an RFC3339 timestamp string. You can use any time zone setting. Talon.One will convert to UTC internally. **Note:** Only coupons deleted in the last 7 days will appear in the results.
|
|
3556
|
+
deleted_after: Time.parse('2013-10-20T19:20:30+01:00') # Time | Timestamp that filters the results to only contain coupons deleted after this date. Must be an RFC3339 timestamp string. You can use any time zone setting. Talon.One will convert to UTC internally. **Note:** Only coupons deleted in the last 7 days will appear in the results.
|
|
3554
3557
|
}
|
|
3555
3558
|
|
|
3556
3559
|
begin
|
|
@@ -3599,6 +3602,8 @@ end
|
|
|
3599
3602
|
| **date_format** | **String** | Determines the format of dates in the export document. | [optional] |
|
|
3600
3603
|
| **campaign_state** | **String** | Filter results by the state of the campaign. - `enabled`: Campaigns that are scheduled, running (activated), or expired. - `running`: Campaigns that are running (activated). - `disabled`: Campaigns that are disabled. - `expired`: Campaigns that are expired. - `archived`: Campaigns that are archived. | [optional] |
|
|
3601
3604
|
| **values_only** | **Boolean** | Filter results to only return the coupon codes (`value` column) without the associated coupon data. | [optional][default to false] |
|
|
3605
|
+
| **deleted_before** | **Time** | Timestamp that filters the results to only contain coupons deleted before this date. Must be an RFC3339 timestamp string. You can use any time zone setting. Talon.One will convert to UTC internally. **Note:** Only coupons deleted in the last 7 days will appear in the results. | [optional] |
|
|
3606
|
+
| **deleted_after** | **Time** | Timestamp that filters the results to only contain coupons deleted after this date. Must be an RFC3339 timestamp string. You can use any time zone setting. Talon.One will convert to UTC internally. **Note:** Only coupons deleted in the last 7 days will appear in the results. | [optional] |
|
|
3602
3607
|
|
|
3603
3608
|
### Return type
|
|
3604
3609
|
|
|
@@ -6235,6 +6240,7 @@ opts = {
|
|
|
6235
6240
|
sort: 'sort_example', # String | The field by which results should be sorted. By default, results are sorted in ascending order. To sort them in descending order, prefix the field name with `-`. **Note:** You may not be able to use all fields for sorting. This is due to performance limitations.
|
|
6236
6241
|
entity: 'entity_example', # String | Returned attributes will be filtered by supplied entity.
|
|
6237
6242
|
application_ids: 'application_ids_example', # String | Returned attributes will be filtered by supplied application ids
|
|
6243
|
+
loyalty_program_ids: 'loyalty_program_ids_example', # String | Returned attributes will be filtered by the specified loyalty program ids, separated by commas. You can only use this parameter when `entity` is `LoyaltyCard`.
|
|
6238
6244
|
type: 'type_example', # String | Returned attributes will be filtered by supplied type
|
|
6239
6245
|
kind: 'builtin', # String | Returned attributes will be filtered by supplied kind (builtin or custom)
|
|
6240
6246
|
search: 'search_example' # String | Returned attributes will be filtered by searching case insensitive through Attribute name, description and type
|
|
@@ -6276,6 +6282,7 @@ end
|
|
|
6276
6282
|
| **sort** | **String** | The field by which results should be sorted. By default, results are sorted in ascending order. To sort them in descending order, prefix the field name with `-`. **Note:** You may not be able to use all fields for sorting. This is due to performance limitations. | [optional] |
|
|
6277
6283
|
| **entity** | **String** | Returned attributes will be filtered by supplied entity. | [optional] |
|
|
6278
6284
|
| **application_ids** | **String** | Returned attributes will be filtered by supplied application ids | [optional] |
|
|
6285
|
+
| **loyalty_program_ids** | **String** | Returned attributes will be filtered by the specified loyalty program ids, separated by commas. You can only use this parameter when `entity` is `LoyaltyCard`. | [optional] |
|
|
6279
6286
|
| **type** | **String** | Returned attributes will be filtered by supplied type | [optional] |
|
|
6280
6287
|
| **kind** | **String** | Returned attributes will be filtered by supplied kind (builtin or custom) | [optional] |
|
|
6281
6288
|
| **search** | **String** | Returned attributes will be filtered by searching case insensitive through Attribute name, description and type | [optional] |
|
|
@@ -9472,6 +9479,81 @@ end
|
|
|
9472
9479
|
- **Accept**: application/json
|
|
9473
9480
|
|
|
9474
9481
|
|
|
9482
|
+
## get_ruleset_v2
|
|
9483
|
+
|
|
9484
|
+
> <RulesetV2> get_ruleset_v2(application_id, campaign_id, ruleset_id)
|
|
9485
|
+
|
|
9486
|
+
Get ruleset (V2)
|
|
9487
|
+
|
|
9488
|
+
Retrieve the specified ruleset as a JSON object.
|
|
9489
|
+
|
|
9490
|
+
### Examples
|
|
9491
|
+
|
|
9492
|
+
```ruby
|
|
9493
|
+
require 'time'
|
|
9494
|
+
require 'talon_one_sdk'
|
|
9495
|
+
# setup authorization
|
|
9496
|
+
TalonOne.configure do |config|
|
|
9497
|
+
# Configure API key authorization: api_key_v1
|
|
9498
|
+
config.api_key['Authorization'] = 'YOUR API KEY'
|
|
9499
|
+
# Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
|
|
9500
|
+
# config.api_key_prefix['Authorization'] = 'Bearer'
|
|
9501
|
+
end
|
|
9502
|
+
|
|
9503
|
+
api_instance = TalonOne::ManagementApi.new
|
|
9504
|
+
application_id = 789 # Integer | The ID of the Application. It is displayed in your Talon.One deployment URL.
|
|
9505
|
+
campaign_id = 789 # Integer | The ID of the campaign. It is displayed in your Talon.One deployment URL.
|
|
9506
|
+
ruleset_id = 789 # Integer | The ID of the ruleset.
|
|
9507
|
+
|
|
9508
|
+
begin
|
|
9509
|
+
# Get ruleset (V2)
|
|
9510
|
+
result = api_instance.get_ruleset_v2(application_id, campaign_id, ruleset_id)
|
|
9511
|
+
p result
|
|
9512
|
+
rescue TalonOne::ApiError => e
|
|
9513
|
+
puts "Error when calling ManagementApi->get_ruleset_v2: #{e}"
|
|
9514
|
+
end
|
|
9515
|
+
```
|
|
9516
|
+
|
|
9517
|
+
#### Using the get_ruleset_v2_with_http_info variant
|
|
9518
|
+
|
|
9519
|
+
This returns an Array which contains the response data, status code and headers.
|
|
9520
|
+
|
|
9521
|
+
> <Array(<RulesetV2>, Integer, Hash)> get_ruleset_v2_with_http_info(application_id, campaign_id, ruleset_id)
|
|
9522
|
+
|
|
9523
|
+
```ruby
|
|
9524
|
+
begin
|
|
9525
|
+
# Get ruleset (V2)
|
|
9526
|
+
data, status_code, headers = api_instance.get_ruleset_v2_with_http_info(application_id, campaign_id, ruleset_id)
|
|
9527
|
+
p status_code # => 2xx
|
|
9528
|
+
p headers # => { ... }
|
|
9529
|
+
p data # => <RulesetV2>
|
|
9530
|
+
rescue TalonOne::ApiError => e
|
|
9531
|
+
puts "Error when calling ManagementApi->get_ruleset_v2_with_http_info: #{e}"
|
|
9532
|
+
end
|
|
9533
|
+
```
|
|
9534
|
+
|
|
9535
|
+
### Parameters
|
|
9536
|
+
|
|
9537
|
+
| Name | Type | Description | Notes |
|
|
9538
|
+
| ---- | ---- | ----------- | ----- |
|
|
9539
|
+
| **application_id** | **Integer** | The ID of the Application. It is displayed in your Talon.One deployment URL. | |
|
|
9540
|
+
| **campaign_id** | **Integer** | The ID of the campaign. It is displayed in your Talon.One deployment URL. | |
|
|
9541
|
+
| **ruleset_id** | **Integer** | The ID of the ruleset. | |
|
|
9542
|
+
|
|
9543
|
+
### Return type
|
|
9544
|
+
|
|
9545
|
+
[**RulesetV2**](RulesetV2.md)
|
|
9546
|
+
|
|
9547
|
+
### Authorization
|
|
9548
|
+
|
|
9549
|
+
[api_key_v1](../README.md#api_key_v1)
|
|
9550
|
+
|
|
9551
|
+
### HTTP request headers
|
|
9552
|
+
|
|
9553
|
+
- **Content-Type**: Not defined
|
|
9554
|
+
- **Accept**: application/json
|
|
9555
|
+
|
|
9556
|
+
|
|
9475
9557
|
## get_rulesets
|
|
9476
9558
|
|
|
9477
9559
|
> <GetRulesets200Response> get_rulesets(application_id, campaign_id, opts)
|
|
@@ -11894,7 +11976,7 @@ end
|
|
|
11894
11976
|
|
|
11895
11977
|
api_instance = TalonOne::ManagementApi.new
|
|
11896
11978
|
application_id = 789 # Integer | The ID of the Application. It is displayed in your Talon.One deployment URL.
|
|
11897
|
-
price_history_request = TalonOne::PriceHistoryRequest.new({sku: '
|
|
11979
|
+
price_history_request = TalonOne::PriceHistoryRequest.new({sku: 'SKU1241028', start_date: Time.parse('2020-11-10T23:00:00Z'), end_date: Time.parse('2020-12-10T23:00:00Z')}) # PriceHistoryRequest | body
|
|
11898
11980
|
|
|
11899
11981
|
begin
|
|
11900
11982
|
# Get summary of price history
|